fix: first time status change not working
This commit is contained in:
parent
60b0f3cd5f
commit
70f19c2082
1 changed files with 2 additions and 2 deletions
|
|
@ -386,11 +386,11 @@ async function triggerChangeStatus(id: string, status: string) {
|
||||||
: t('confirmChangeStatusOnMessage'),
|
: t('confirmChangeStatusOnMessage'),
|
||||||
action: async () => {
|
action: async () => {
|
||||||
if (currentTab.value === 'employee') {
|
if (currentTab.value === 'employee') {
|
||||||
await toggleStatusEmployee(id, status === 'ACTIVE' ? true : false)
|
await toggleStatusEmployee(id, status === 'INACTIVE' ? false : true)
|
||||||
.then(resolve)
|
.then(resolve)
|
||||||
.catch(reject);
|
.catch(reject);
|
||||||
} else {
|
} else {
|
||||||
await toggleStatusCustomer(id, status === 'ACTIVE' ? true : false)
|
await toggleStatusCustomer(id, status === 'INACTIVE' ? false : true)
|
||||||
.then(resolve)
|
.then(resolve)
|
||||||
.catch(reject);
|
.catch(reject);
|
||||||
}
|
}
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue