fix:修复点击两次问题

This commit is contained in:
yangqingyuan
2024-08-27 16:46:53 +08:00
parent 9d57b01fd1
commit ee22fdd8fc

View File

@@ -120,24 +120,19 @@ import {addOrderPay} from "@/api/order";
form.expirationTime = d2 + ' 23:59:59';
form.orderNo=props.data?.orderNo;
form.rentOrderId=props.data?.rentOrderId;
validate()
.then(() => {
loading.value = true;
// 转字符串
addOrderPay(form)
.then((msg) => {
loading.value = false;
message.success(msg);
updateVisible(false);
emit('done');
})
.catch((e) => {
loading.value = false;
message.error(e.message);
});
loading.value = true;
// 转字符串
addOrderPay(form)
.then((msg) => {
loading.value = false;
message.success(msg);
updateVisible(false);
emit('done');
})
.catch(() => {});
.catch((e) => {
loading.value = false;
message.error(e.message);
});
};
watch(