修改停车订单页面删除最后一条数据后造成的bug

This commit is contained in:
赵毅 2025-09-13 11:58:45 +08:00
parent 849d6149bb
commit db78fe36b0
2 changed files with 27 additions and 26 deletions

View File

@ -62,7 +62,7 @@
</view>
<view class="hr"></view>
<view class="info-item">
<view class="info-label1">下单总金额( ¥{{ orderInfo.orderAmount }} )</view>
<view class="info-label1">下单总金额( ¥{{ orderInfo.total_amount }} )</view>
<view class="info-action">明细</view>
</view>
<view class="info-item">
@ -170,7 +170,6 @@ export default {
},
onLoad(options) {
const item = JSON.parse(options?.item);
console.log("🚀 ~ onLoad ~ item:", item)
//
item.order_status == "1" ? this.startCountdown() : "";
this.status = JSON.stringify(item.order_status);
@ -210,7 +209,6 @@ export default {
});
},
gotoPayment() {
console.log("🚀 ~ gotoPayment ~ 去支付:");
//
// uni.navigateTo({
// url: "/kitchen/pay/index",

View File

@ -8,7 +8,9 @@
</view>
<!-- 订单列表 -->
<view class="order-item" v-for="order in monthGroup.orders" :key="order.id" @tap="viewOrderDetail(order)">
<view v-if="orderData.length > 0">
<view class="order-item" v-for="order in monthGroup.orders" :key="order.id"
@tap="viewOrderDetail(order)">
<view class="order-left">
<view class="order-type">
<view class="order-type1">
@ -38,6 +40,7 @@
</view>
</view>
</view>
</view>
<!-- 空状态显示 -->
<view class="empty-state" v-if="orderData.length === 0">