From 2a25354ee43bcc6a17b11c12183796610b4b37d9 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E5=A4=A7=E5=96=B5=E5=92=AA?= <15233722133@163.com> Date: Wed, 16 Sep 2026 09:54:35 +0800 Subject: [PATCH] =?UTF-8?q?feat:=20=E5=95=86=E5=9F=8E=E8=AE=A2=E5=8D=95?= =?UTF-8?q?=E6=B7=BB=E5=8A=A0=E5=88=A0=E9=99=A4=E6=8C=89=E9=92=AE=EF=BC=88?= =?UTF-8?q?=E5=B7=B2=E5=8F=96=E6=B6=88=EF=BC=89?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- components/card_orderBan/card_orderBan.vue | 30 ++++++++++++++++++++++ 1 file changed, 30 insertions(+) diff --git a/components/card_orderBan/card_orderBan.vue b/components/card_orderBan/card_orderBan.vue index 9c37491..88f6c74 100644 --- a/components/card_orderBan/card_orderBan.vue +++ b/components/card_orderBan/card_orderBan.vue @@ -144,6 +144,11 @@ name: '取消售后', value: '60', }, + { + id: 8, + name: '删除订单', + value: '40', + }, ]); const btnClick = (index) => { let timestamp = new Date().getTime(); @@ -189,6 +194,9 @@ case 7: remindStore(); break; + case 8: + deleteOrder(); + break; } }; // 取消订单 @@ -215,6 +223,28 @@ }, }); }; + const deleteOrder = () => { + const orderId = props.data?.id; + uni.showModal({ + title: '提示', + content: '确定要删除订单吗?', + confirmColor: '#FA7E31', + success: async function (res) { + if (!res.confirm) { + return; + } + + const { code } = await OrderApi.deleteOrder(orderId); + if (code === 0) { + uni.showToast({ + title: '订单已删除', + icon: 'none', + }); + upData(); + } + }, + }); + }; // 去付款 const payOrder = (id) => { sheep.$router.go('/pages/pay/index', {