mirror of
https://gitlab.com/CIEFWorldwideSdnBhd/exchange-2.0.git
synced 2026-08-19 04:23:55 +00:00
E-Invoice - Fix a problem reported by Sin Yee msic code input cannot start with 0
This commit is contained in:
@@ -7,7 +7,7 @@ use App\Classes\General\Interfaces\DataTransferObject;
|
||||
class EInvoiceInfoDTO implements DataTransferObject
|
||||
{
|
||||
public string $tin;
|
||||
public int $msicCode;
|
||||
public string $msicCode;
|
||||
public int $districtId;
|
||||
public int $stateId;
|
||||
public int $companyId;
|
||||
@@ -18,7 +18,7 @@ class EInvoiceInfoDTO implements DataTransferObject
|
||||
public function __construct(array $data)
|
||||
{
|
||||
$this->tin = (string) ($data['tin'] ?? '');
|
||||
$this->msicCode = (int) ($data['msic_code'] ?? 0);
|
||||
$this->msicCode = (string) ($data['msic_code'] ?? 0);
|
||||
$this->districtId = (int) ($data['district_id'] ?? 0);
|
||||
$this->stateId = (int) ($data['state_id'] ?? 0);
|
||||
$this->companyId = (int) ($data['company_id'] ?? 0);
|
||||
|
||||
@@ -13,7 +13,7 @@ class UpdateCompanyDetailsDTO implements DataTransferObject
|
||||
public int $type;
|
||||
|
||||
public string $tin;
|
||||
public int $msicCode;
|
||||
public string $msicCode;
|
||||
public int $addressId;
|
||||
public int $districtId;
|
||||
public int $stateId;
|
||||
@@ -31,7 +31,7 @@ class UpdateCompanyDetailsDTO implements DataTransferObject
|
||||
$this->type = (int) ($data['type'] ?? 0);
|
||||
|
||||
$this->tin = (string) ($data['tin'] ?? 0);
|
||||
$this->msicCode = (int) ($data['msic_code'] ?? 0);
|
||||
$this->msicCode = (string) ($data['msic_code'] ?? 0);
|
||||
$this->addressId = (int) ($data['address_id'] ?? 0);
|
||||
$this->districtId = (int) ($data['district_id'] ?? 0);
|
||||
$this->stateId = (int) ($data['state_id'] ?? 0);
|
||||
|
||||
@@ -23,7 +23,7 @@ class EInvoiceInfoResource extends JsonResource
|
||||
'post_code' => (int) $this->postcode,
|
||||
'country' => $this->country,
|
||||
'billing' => (int) $this->billing,
|
||||
'msic_code' => (int) $this->msic_code,
|
||||
'msic_code' => (string) $this->msic_code,
|
||||
'tin' => (string) $this->tin,
|
||||
'e_invoice' => (int) $this->e_invoice,
|
||||
];
|
||||
|
||||
@@ -18,7 +18,7 @@
|
||||
</validation-wrapper-component>
|
||||
</div>
|
||||
<div class="col-6 p-l-5">
|
||||
<validation-wrapper-component :validator="$v.parameters.msic_code" v-money="integer">
|
||||
<validation-wrapper-component :validator="$v.parameters.msic_code">
|
||||
<label>
|
||||
MSIC Code
|
||||
<a href="https://sdk.myinvois.hasil.gov.my/codes/msic-codes/" target="_blank" rel="noopener noreferrer">
|
||||
@@ -233,7 +233,8 @@
|
||||
: {})
|
||||
},
|
||||
msic_code: {
|
||||
notZero, fiveDigits
|
||||
notZero,
|
||||
fiveDigits
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user