refactor: assign file arry

This commit is contained in:
Net 2024-08-29 14:54:06 +07:00
parent 5ed0718573
commit 3727627717

View file

@ -253,7 +253,7 @@ export const useCustomerForm = defineStore('form-customer', () => {
: '',
registerCompanyName: '',
contactName: '',
file: undefined,
file: [],
});
state.value.branchIndex =
(currentFormData.value.customerBranch?.length || 0) - 1;
@ -345,7 +345,7 @@ export const useCustomerBranchForm = defineStore('form-customer-branch', () => {
registerCompanyName: '',
statusSave: false,
contactName: '',
file: undefined,
file: [],
};
let resetFormData = structuredClone(defaultFormData);
@ -411,7 +411,7 @@ export const useCustomerBranchForm = defineStore('form-customer-branch', () => {
contactName: _data.contactName,
registerCompanyName: '',
statusSave: false,
file: undefined,
file: [],
};
currentFormData.value = structuredClone(resetFormData);