Files
portal/app/Http/Resources/PackageResource.php
T
omair saleh d8c767c670 Large commit
2021-08-16 08:59:43 +08:00

31 lines
760 B
PHP

<?php
namespace App\Http\Resources;
use Illuminate\Http\Resources\Json\JsonResource;
class PackageResource extends JsonResource
{
/**
* Transform the resource into an array.
*
* @param \Illuminate\Http\Request $request
* @return array
*/
public function toArray($request)
{
return [
'id' => $this->id,
'packing_list_id' => $this->packing_list_id,
'type' => $this->type,
'description' => $this->description,
'width' => $this->width,
'height' => $this->height,
'length' => $this->length,
'weight' => $this->weight,
'quantity' => $this->quantity,
'status' => $this->status,
];
}
}