E-Invoice - Fix minor problems discovered from Shipping Portal

This commit is contained in:
Dillon Ngo
2025-06-20 14:31:31 +08:00
parent fdfcf714e5
commit 51d9a785d7
4 changed files with 71 additions and 64 deletions
@@ -0,0 +1,28 @@
<?php
namespace App\Http\Resources;
use Illuminate\Http\Resources\Json\JsonResource;
class AddressEInvoiceResource extends JsonResource
{
/**
* Transform the resource into an array.
*
* @param \Illuminate\Http\Request $request
* @return array
*/
public function toArray($request)
{
return [
'id' => $this->id,
'street_one' => $this->street_one,
'street_two' => $this->street_two,
'district' => $this->district,
'state' => $this->state,
'post_code' => (int) $this->postcode,
'country' => $this->country,
'billing' => (int) $this->billing
];
}
}