refactor: use triggerChangeStatus of employee
This commit is contained in:
parent
4f714beecc
commit
b3922cddff
1 changed files with 4 additions and 5 deletions
|
|
@ -2273,11 +2273,9 @@ const emptyCreateDialog = ref(false);
|
|||
dialogEmployeeImageUpload && dialogEmployeeImageUpload.browse()
|
||||
"
|
||||
@update:toggle-status="
|
||||
() => {
|
||||
currentFromDataEmployee.status =
|
||||
currentFromDataEmployee.status === 'CREATED'
|
||||
? 'INACTIVE'
|
||||
: 'CREATED';
|
||||
(v) => {
|
||||
if (currentFromDataEmployee.id !== undefined)
|
||||
triggerChangeStatus(currentFromDataEmployee.id, v);
|
||||
}
|
||||
"
|
||||
active
|
||||
|
|
@ -2286,6 +2284,7 @@ const emptyCreateDialog = ref(false);
|
|||
icon="mdi-account-plus-outline"
|
||||
bg-color="linear-gradient(135deg, rgba(43,137,223,1) 0%, rgba(230,51,81,1) 100%)"
|
||||
v-model:current-tab="employeeFormState.currentTab"
|
||||
v-model:toggle-status="currentFromDataEmployee.status"
|
||||
v-model:cover-url="employeeFormState.profileUrl"
|
||||
fallback-cover="/images/employee-banner.png"
|
||||
:img="employeeFormState.profileUrl"
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue