update
This commit is contained in:
@@ -8,11 +8,17 @@ const {type} = defineProps({
|
|||||||
}
|
}
|
||||||
});
|
});
|
||||||
|
|
||||||
const {promise, resolve, reject} = Promise.withResolvers();
|
let promise, resolve, reject;
|
||||||
|
|
||||||
const value = ref();
|
const value = ref();
|
||||||
const DateTimeRef = ref();
|
const DateTimeRef = ref();
|
||||||
const open = () => {
|
const open = () => {
|
||||||
|
const {promise: _promise, resolve: _resolve, reject: _reject} = Promise.withResolvers();
|
||||||
|
|
||||||
|
promise = _promise;
|
||||||
|
resolve = _resolve;
|
||||||
|
reject = _reject;
|
||||||
|
|
||||||
DateTimeRef.value.show();
|
DateTimeRef.value.show();
|
||||||
return promise;
|
return promise;
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -89,11 +89,11 @@ const deleteItem = async (id) => {
|
|||||||
}
|
}
|
||||||
|
|
||||||
const changeStatus = async (value, item) => {
|
const changeStatus = async (value, item) => {
|
||||||
let abnormaltime = null;
|
|
||||||
if (value === 2) {
|
|
||||||
abnormaltime = await SelectTimeAsyncRef.value.open();
|
|
||||||
}
|
|
||||||
try {
|
try {
|
||||||
|
let abnormaltime = null;
|
||||||
|
if (value === 2) {
|
||||||
|
abnormaltime = await SelectTimeAsyncRef.value.open();
|
||||||
|
}
|
||||||
const {msg} = await Api.system.setAccountStatus({
|
const {msg} = await Api.system.setAccountStatus({
|
||||||
...item,
|
...item,
|
||||||
status: value,
|
status: value,
|
||||||
|
|||||||
Reference in New Issue
Block a user