File manager - Edit - /var/www/html/spdc/api/app/Http/Resources/ScaleResource.php
Back
<?php namespace App\Http\Resources; use App\Models\Scale; use Illuminate\Http\Resources\Json\JsonResource; class ScaleResource extends JsonResource { /** * Transform the resource into an array. * * @param \Illuminate\Http\Request $request * @return array|\Illuminate\Contracts\Support\Arrayable|\JsonSerializable */ public function toArray($request) { return [ 'id' => $this->id, 'warning' => $this->warning, 'finished' => $this->finished, 'month' => $this->month, 'year' => $this->year, 'department' => new DepartmentResource($this->whenLoaded('department')), ]; } }
| ver. 1.4 |
Github
|
.
| PHP 8.3.28 | Generation time: 0.01 |
proxy
|
phpinfo
|
Settings