refactor: handle field only lagelPersonNo , registerName

This commit is contained in:
Thanaphon Frappet 2024-10-28 13:04:37 +07:00
parent dac32c8eae
commit 2e941af305

View file

@ -379,12 +379,6 @@ async function fetchListCustomer(fetchStats = false) {
maxPageCustomer.value = Math.ceil(resultList.total / pageSize.value);
listCustomer.value = resultList.result;
}
if (fetchStats) {
statsCustomerType.value = await customerStore
.getStatsCustomer()
.then((value) => (value ? value : { CORP: 0, PERS: 0 }));
}
}
async function fetchListEmployee(fetchStats = false) {
@ -2132,12 +2126,7 @@ const emptyCreateDialog = ref(false);
];
}
if (customerFormData.customerType === 'CORP') {
tabFieldRequired.main = [
'legalPersonNo',
'registerName',
'registerNameEN',
'customerName',
];
tabFieldRequired.main = ['legalPersonNo', 'registerName'];
}
let tapIsUndefined = validateTabField(
customerFormData.customerBranch?.[idx],