feat: customer form code abbrev
This commit is contained in:
parent
0af5d049c3
commit
560e9dc272
5 changed files with 52 additions and 10 deletions
|
|
@ -182,11 +182,6 @@ const useCustomerStore = defineStore('api-customer', () => {
|
|||
|
||||
const attachment = payload.customerBranch?.map((v) => v.file);
|
||||
|
||||
payload.customerBranch = payload.customerBranch?.map((v) => {
|
||||
delete v['code'];
|
||||
return { ...v };
|
||||
});
|
||||
|
||||
if (payload.customerBranch?.length) {
|
||||
for (let i = 0; i < payload.customerBranch?.length; i++) {
|
||||
delete payload.customerBranch[i].file;
|
||||
|
|
@ -240,7 +235,7 @@ const useCustomerStore = defineStore('api-customer', () => {
|
|||
const attachment = payload.customerBranch?.map((v) => v.file);
|
||||
|
||||
payload.customerBranch = payload.customerBranch?.map((v) => {
|
||||
const { code, ...rest } = v;
|
||||
const { code: _code, ...rest } = v;
|
||||
return { ...rest };
|
||||
});
|
||||
|
||||
|
|
|
|||
|
|
@ -96,6 +96,7 @@ export type CustomerBranchCreate = {
|
|||
};
|
||||
|
||||
export type CustomerCreate = {
|
||||
code: string;
|
||||
customerBranch?: (CustomerBranchCreate & { id?: string })[];
|
||||
taxNo?: string | null;
|
||||
customerNameEN: string;
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue