adrema/app/Member/Resources/NationalityResource.php

29 lines
541 B
PHP
Raw Normal View History

<?php
namespace App\Member\Resources;
use App\Nationality;
use Illuminate\Http\Resources\Json\JsonResource;
/**
* @mixin Nationality
*/
class NationalityResource extends JsonResource
{
/**
* Transform the resource into an array.
*
* @param \Illuminate\Http\Request $request
*
2022-11-22 02:01:07 +01:00
* @return array<string, int|string>
*/
public function toArray($request)
{
return [
'name' => $this->name,
'nami_id' => $this->nami_id,
'id' => $this->id,
];
}
}