hookehuyr

fix: 修复弹窗拖动问题和修改订单操作确认文本

为评价弹窗和订单详情弹窗添加catch-move属性防止拖动时关闭
将删除订单和取消订单的确认提示文本修改为更简洁的表述
<!--
* @Date: 2022-09-19 14:11:06
* @LastEditors: hookehuyr hookehuyr@gmail.com
* @LastEditTime: 2025-07-14 17:03:37
* @LastEditTime: 2025-07-14 18:18:12
* @FilePath: /jgdl/src/pages/myOrders/index.vue
* @Description: 订单管理页面
-->
......@@ -127,7 +127,7 @@
<payCard :visible="show_pay" :data="payData" @close="onPayClose" @paySuccess="onPaySuccess" />
<!-- 评价弹窗 -->
<nut-popup v-model:visible="showRatePopup" position="right" :style="{ width: '100%', height: '100%' }" closeable
<nut-popup v-model:visible="showRatePopup" position="right" :catch-move="true" :style="{ width: '100%', height: '100%' }" closeable
close-icon-position="top-right" @close="closeRatePopup">
<view class="rate-popup">
<view class="rate-header">
......@@ -177,7 +177,7 @@
</nut-popup>
<!-- 订单详情弹窗 -->
<nut-popup v-model:visible="showOrderDetailPopup" position="right" :style="{ width: '100%', height: '100%' }"
<nut-popup v-model:visible="showOrderDetailPopup" position="right" :catch-move="true" :style="{ width: '100%', height: '100%' }"
@close="closeOrderDetailPopup">
<view class="order-detail-popup">
<view class="detail-header">
......@@ -285,7 +285,7 @@
>
<template #default>
<view>
<text style="font-size: 1rem;">删除订单将无法恢复,请谨慎操作。</text>
<text style="font-size: 1rem;">是否确认删除订单?</text>
</view>
</template>
</nut-dialog>
......@@ -301,7 +301,7 @@
>
<template #default>
<view>
<text style="font-size: 1rem;">取消订单后将无法恢复,确定要取消吗?</text>
<text style="font-size: 1rem;">是否确认取消订单?</text>
</view>
</template>
</nut-dialog>
......@@ -684,23 +684,23 @@ const submitRate = async () => {
note: rateContent.value,
created_time: new Date().toLocaleString('zh-CN')
}
// 同时更新order.review和order.details.review,确保状态一致
order.review = reviewData
if (order.details) {
order.details.review = reviewData
}
// 确保订单状态为已完成
order.status = 5
}
Taro.showToast({
title: response.msg || '评价提交成功',
icon: 'success',
duration: 2000
})
closeRatePopup()
} else {
throw new Error(response.msg || '提交失败')
......