26 lines
No EOL
588 B
PHP
26 lines
No EOL
588 B
PHP
<?php
|
|
|
|
namespace App\Http\Resources\API;
|
|
|
|
use Illuminate\Http\Resources\Json\JsonResource;
|
|
|
|
class Mail extends JsonResource
|
|
{
|
|
/**
|
|
* Transform the resource into an array.
|
|
*
|
|
* @param \Illuminate\Http\Request $request
|
|
* @return array
|
|
*/
|
|
public function toArray($request)
|
|
{
|
|
return [
|
|
'id' => (int)$this->id,
|
|
'created_at' => $this->created_at,
|
|
'updated_at' => $this->created_at,
|
|
'status' => $this->status,
|
|
'primary' => $this->primary,
|
|
'mail' => $this->mail
|
|
];
|
|
}
|
|
} |