refactor: delete codeCustomer and statusSave
This commit is contained in:
parent
d15bb7ef6f
commit
3c66ca2a46
1 changed files with 1 additions and 9 deletions
|
|
@ -385,15 +385,7 @@ const useCustomerStore = defineStore('api-customer', () => {
|
||||||
if (!data.birthDate) delete data['birthDate'];
|
if (!data.birthDate) delete data['birthDate'];
|
||||||
if (!data.registerDate) delete data['registerDate'];
|
if (!data.registerDate) delete data['registerDate'];
|
||||||
|
|
||||||
const {
|
const { code, file, birthDate, citizen, ...payload } = data;
|
||||||
codeCustomer,
|
|
||||||
statusSave,
|
|
||||||
code,
|
|
||||||
file,
|
|
||||||
birthDate,
|
|
||||||
citizen,
|
|
||||||
...payload
|
|
||||||
} = data;
|
|
||||||
|
|
||||||
const res = await api.post<CustomerBranch>('/customer-branch', payload);
|
const res = await api.post<CustomerBranch>('/customer-branch', payload);
|
||||||
if (!res) return false;
|
if (!res) return false;
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue