fix Warning: Don't save data.
This commit is contained in:
parent
a862406de0
commit
b6fbee826a
2 changed files with 3 additions and 5 deletions
|
|
@ -515,8 +515,8 @@ async function deleteEmployeeById(opts: {
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
const resultList = await employeeStore.fetchList();
|
await fetchListEmployee(true);
|
||||||
if (resultList) listEmployee.value = resultList.result;
|
|
||||||
flowStore.rotate();
|
flowStore.rotate();
|
||||||
},
|
},
|
||||||
cancel: () => {},
|
cancel: () => {},
|
||||||
|
|
|
||||||
|
|
@ -537,7 +537,6 @@ export const useCustomerBranchForm = defineStore('form-customer-branch', () => {
|
||||||
);
|
);
|
||||||
|
|
||||||
async function submitForm() {
|
async function submitForm() {
|
||||||
console.log(currentFormData.value);
|
|
||||||
if (!state.value.currentCustomerId) {
|
if (!state.value.currentCustomerId) {
|
||||||
throw new Error(
|
throw new Error(
|
||||||
'Employer id cannot be found. Did you properly set employer id?',
|
'Employer id cannot be found. Did you properly set employer id?',
|
||||||
|
|
@ -913,7 +912,7 @@ export const useEmployeeForm = defineStore('form-employee', () => {
|
||||||
await assignFormDataEmployee(currentFromDataEmployee.value.id);
|
await assignFormDataEmployee(currentFromDataEmployee.value.id);
|
||||||
}
|
}
|
||||||
|
|
||||||
async function submitPersonal(imgList?: {
|
async function submitPersonal(imgList: {
|
||||||
selectedImage: string;
|
selectedImage: string;
|
||||||
list: { url: string; imgFile: File | null; name: string }[];
|
list: { url: string; imgFile: File | null; name: string }[];
|
||||||
}) {
|
}) {
|
||||||
|
|
@ -933,7 +932,6 @@ export const useEmployeeForm = defineStore('form-employee', () => {
|
||||||
if (res) {
|
if (res) {
|
||||||
await assignFormDataEmployee(res.id);
|
await assignFormDataEmployee(res.id);
|
||||||
currentFromDataEmployee.value.id = res.id;
|
currentFromDataEmployee.value.id = res.id;
|
||||||
currentFromDataEmployee.value.file = res.file;
|
|
||||||
state.value.statusSavePersonal = true;
|
state.value.statusSavePersonal = true;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue