
* #23 - wip * #23 - wip * #23 - wip * #23 - wip * #23 - fix * #23 - ecs fix * #23 - fix * #23 - fix * #23 - cr fix
23 lines
456 B
PHP
23 lines
456 B
PHP
<?php
|
|
|
|
declare(strict_types=1);
|
|
|
|
namespace Toby\Http\Resources;
|
|
|
|
use Illuminate\Http\Resources\Json\JsonResource;
|
|
|
|
class VacationLimitResource extends JsonResource
|
|
{
|
|
public static $wrap = null;
|
|
|
|
public function toArray($request): array
|
|
{
|
|
return [
|
|
"id" => $this->id,
|
|
"user" => new UserResource($this->user),
|
|
"hasVacation" => $this->hasVacation(),
|
|
"days" => $this->days,
|
|
];
|
|
}
|
|
}
|