From ab0d5003083a0a1dddf7660868363372861d76ea Mon Sep 17 00:00:00 2001 From: Agent Date: Fri, 27 Mar 2026 15:12:33 +0000 Subject: [PATCH] =?UTF-8?q?feat:=20=E6=96=B0=E5=A2=9E=E5=95=86=E5=93=81?= =?UTF-8?q?=E8=AF=A6=E6=83=85=E9=A1=B5=EF=BC=8C=E7=82=B9=E5=87=BB=E5=95=86?= =?UTF-8?q?=E5=93=81=E5=8D=A1=E7=89=87=E5=8F=AF=E6=9F=A5=E7=9C=8B=E8=AF=A6?= =?UTF-8?q?=E6=83=85?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/pages.json | 6 + src/pages/product/detail.vue | 250 +++++++++++++++++++++++++++++++++++ src/pages/product/list.vue | 4 +- 3 files changed, 259 insertions(+), 1 deletion(-) create mode 100644 src/pages/product/detail.vue diff --git a/src/pages.json b/src/pages.json index 0b7d0b6..b245b37 100644 --- a/src/pages.json +++ b/src/pages.json @@ -30,6 +30,12 @@ "navigationBarTitleText": "选择商品" } }, + { + "path": "pages/product/detail", + "style": { + "navigationBarTitleText": "商品详情" + } + }, { "path": "pages/order/create", "style": { diff --git a/src/pages/product/detail.vue b/src/pages/product/detail.vue new file mode 100644 index 0000000..92bd6ae --- /dev/null +++ b/src/pages/product/detail.vue @@ -0,0 +1,250 @@ + + + + + \ No newline at end of file diff --git a/src/pages/product/list.vue b/src/pages/product/list.vue index 71046a1..c21b19c 100644 --- a/src/pages/product/list.vue +++ b/src/pages/product/list.vue @@ -154,7 +154,9 @@ export default { this.loadProducts() }, viewDetail(item) { - uni.showToast({ title: '商品详情开发中', icon: 'none' }) + uni.navigateTo({ + url: `/pages/product/detail?productId=${item.productId}` + }) }, getStock(productId) { return this.stocks[productId] || 0