优化订单退款
This commit is contained in:
@@ -93,6 +93,7 @@ import useStorage from '@/utils/useStorage.js'
|
||||
import { useGlobal } from '@/store/global.js'
|
||||
import { usePrint } from '@/store/print.js'
|
||||
import { useGoods } from '@/store/goods.js'
|
||||
import { useSocket } from '@/store/socket.js'
|
||||
|
||||
import { staffPermission } from '@/api/user.js'
|
||||
|
||||
@@ -102,8 +103,9 @@ const global = useGlobal()
|
||||
const printStore = usePrint()
|
||||
|
||||
const store = useUser();
|
||||
const socket = useSocket()
|
||||
|
||||
const emit = defineEmits("paySuccess");
|
||||
const emits = defineEmits(['success']);
|
||||
|
||||
const cartInfo = ref('')
|
||||
|
||||
@@ -122,10 +124,6 @@ const props = defineProps({
|
||||
type: String,
|
||||
default: "",
|
||||
},
|
||||
orderInfo: {
|
||||
type: Object,
|
||||
default: "",
|
||||
},
|
||||
masterId: {
|
||||
type: String,
|
||||
default: "",
|
||||
@@ -210,11 +208,13 @@ async function printOrderLable(isBefore = false) {
|
||||
|
||||
// 订单已支付
|
||||
function paySuccess() {
|
||||
emits('success')
|
||||
dialogVisible.value = false;
|
||||
ElMessage.success('支付成功')
|
||||
printOrderLable()
|
||||
useStorage.del('tableCode')
|
||||
goodsStore.successClearCart(!cartList.length)
|
||||
socket.cartInit()
|
||||
goodsStore.successClearCart()
|
||||
}
|
||||
|
||||
|
||||
|
||||
Reference in New Issue
Block a user