feat: 订单退款功能对接
This commit is contained in:
@@ -39,12 +39,7 @@
|
||||
|
||||
<script setup>
|
||||
import { defineProps, computed, ref, defineEmits } from "vue";
|
||||
import {
|
||||
preOrder,
|
||||
orderPayNow,
|
||||
orderCancel,
|
||||
orderRefund,
|
||||
} from "@/request/api/OrderApi";
|
||||
import { orderPayNow } from "@/request/api/OrderApi";
|
||||
|
||||
// 支付方式映射常量
|
||||
const PAY_WAY_MAP = {
|
||||
@@ -57,7 +52,7 @@ const PAY_WAY_MAP = {
|
||||
const isLoading = ref(false);
|
||||
|
||||
// 定义事件发射器
|
||||
const emit = defineEmits(['show-refund-popup']);
|
||||
const emit = defineEmits(["show-refund-popup"]);
|
||||
|
||||
const props = defineProps({
|
||||
orderData: {
|
||||
@@ -116,7 +111,7 @@ const handleButtonClick = async () => {
|
||||
|
||||
if (status === "2") {
|
||||
// 情况2:待使用状态,显示退款弹窗
|
||||
emit('show-refund-popup');
|
||||
emit("show-refund-popup");
|
||||
return; // 直接返回,不执行后续代码
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user