| 1 | <?php |
||
| 16 | class EmployeesResponse extends AbstractPaginatedModel |
||
| 17 | { |
||
| 18 | /** |
||
| 19 | * @var Employee[] |
||
| 20 | * @Type("array<App\Entity\Employee>") |
||
| 21 | * @Expose |
||
| 22 | */ |
||
| 23 | public $employees; |
||
| 24 | |||
| 25 | /** |
||
| 26 | * @Type("integer") |
||
| 27 | * @Accessor(getter="getCount") |
||
| 28 | * @Expose |
||
| 29 | */ |
||
| 30 | public int $count; |
||
|
|
|||
| 31 | |||
| 32 | /** |
||
| 33 | * @Type("integer") |
||
| 34 | * @Expose |
||
| 35 | */ |
||
| 36 | public int $currentPage; |
||
| 37 | |||
| 38 | /** |
||
| 39 | * @Type("integer") |
||
| 40 | * @Expose |
||
| 41 | */ |
||
| 42 | public int $overAllCount; |
||
| 43 | |||
| 44 | public function getCount(): int |
||
| 45 | { |
||
| 46 | return count($this->employees); |
||
| 47 | } |
||
| 48 | } |
||
| 49 |