File manager - Edit - /var/www/html/spdc/api/app/Http/Resources/ShelterMemberFamilyResource.php
Back
<?php namespace App\Http\Resources; use Illuminate\Http\Resources\Json\JsonResource; class ShelterMemberFamilyResource 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 parent::toArray($request); return [ 'id'=> $this->id, 'name'=> $this->name, 'age'=> $this->age, 'document'=> $this->document, 'is_special_need'=> $this->is_special_need, 'special_need'=> $this->special_need, 'is_sheltered'=> $this->is_sheltered, 'shelter_family_id'=> $this->shelter_family_id, 'last_shelter_id'=> $this->last_shelter_id, 'parental_relation' => $this->parental_relation, 'birth_date' => $this->birth_date, 'gender' => $this->genderString(), 'ethnicity' => $this->ethnicity, 'mother_name' => $this->mother_name, 'nis' => $this->nis, 'country' => $this->country, 'city' => $this->city, 'uf' => $this->uf, 'education' => $this->education, 'occupation' => $this->occupation, 'phone' => $this->phone, 'created_at'=> $this->created_at, 'updated_at'=> $this->updated_at, 'income' => $this->income, 'is_dead' => $this->is_dead, 'in_bed_rest' => $this->in_bed_rest, 'from_nursing_home' => $this->from_nursing_home, 'member_health_questionnaire' => MemberHealthQuestionnaireResource::collection($this->healthQuestionnares), 'member_vaccine_questionnaire' => MemberVaccineQuestionnaireResource::collection($this->vaccineQuestionnares) ]; } }
| ver. 1.4 |
Github
|
.
| PHP 8.3.28 | Generation time: 0.02 |
proxy
|
phpinfo
|
Settings