diff --git a/src/pages.json b/src/pages.json index a7d0f0f..5865655 100644 --- a/src/pages.json +++ b/src/pages.json @@ -60,6 +60,12 @@ "navigationBarTitleText": "退货" } }, + { + "path": "pages/order/detail", + "style": { + "navigationBarTitleText": "订单详情" + } + }, { "path": "pages/stock/list", "style": { diff --git a/src/pages/order/detail.vue b/src/pages/order/detail.vue new file mode 100644 index 0000000..34d7940 --- /dev/null +++ b/src/pages/order/detail.vue @@ -0,0 +1,396 @@ + + + + + \ No newline at end of file diff --git a/src/pages/order/list.vue b/src/pages/order/list.vue index 100bd8f..36a4a6c 100644 --- a/src/pages/order/list.vue +++ b/src/pages/order/list.vue @@ -192,11 +192,9 @@ export default { this.loadOrders() }, viewDetail(order) { - // 跳转到订单详情页或显示详情弹窗 - uni.showModal({ - title: '订单详情', - content: `订单号: ${order.orderNo}\n原价: ¥${order.totalAmount}\n优惠: ¥${order.discountAmount}\n实付: ¥${order.actualAmount}`, - showCancel: false + // 跳转到订单详情页 + uni.navigateTo({ + url: `/pages/order/detail?orderId=${order.orderId}` }) }, getItemCount(orderId) { diff --git a/src/pages/order/search.vue b/src/pages/order/search.vue index a7f705a..cedf376 100644 --- a/src/pages/order/search.vue +++ b/src/pages/order/search.vue @@ -205,10 +205,8 @@ export default { return time.substring(0, 16).replace('T', ' ') }, viewDetail(order) { - uni.showModal({ - title: '订单详情', - content: `订单号: ${order.orderNo}\n原价: ¥${order.totalAmount}\n优惠: ¥${order.discountAmount}\n实付: ¥${order.actualAmount}\n状态: ${this.getStatusText(order.status)}`, - showCancel: false + uni.navigateTo({ + url: `/pages/order/detail?orderId=${order.orderId}` }) } }