From 7f92a1cefb513e0988eb6a0f79108739fd3f3e6a Mon Sep 17 00:00:00 2001 From: wangdong <1551135706@qq.com> Date: Wed, 4 Sep 2024 15:33:30 +0800 Subject: [PATCH] =?UTF-8?q?=E4=BF=AE=E6=94=B9=E5=95=86=E5=93=81=E9=BB=98?= =?UTF-8?q?=E8=AE=A4sku=E7=BC=96=E7=A0=81=E8=8E=B7=E5=8F=96?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- pages/goods/detail.vue | 5 ++++- pages/goods/seckillDetail.vue | 5 ++++- 2 files changed, 8 insertions(+), 2 deletions(-) diff --git a/pages/goods/detail.vue b/pages/goods/detail.vue index 924eb3b..4973616 100644 --- a/pages/goods/detail.vue +++ b/pages/goods/detail.vue @@ -1088,7 +1088,10 @@ that.isTodo = true; that.goods_sku_no = "" if (info.skuList && info.skuList.length > 0) { - that.goods_sku_no = info.skuList[0].goods_sku_no + if (info.goods_id) { + that.goods_sku_no = info.skuList.filter(item => item.goods_id === info.goods_id)[0].goods_sku_no; + } + // that.goods_sku_no = info.skuList[0].goods_sku_no } that.allPicture = info.goods_images.length; if (type == 1) { diff --git a/pages/goods/seckillDetail.vue b/pages/goods/seckillDetail.vue index f67492e..06cc612 100644 --- a/pages/goods/seckillDetail.vue +++ b/pages/goods/seckillDetail.vue @@ -979,7 +979,10 @@ that.isTodo = true; that.goods_sku_no = "" if (info.skuList && info.skuList.length > 0) { - that.goods_sku_no = info.skuList[0].goods_sku_no + if (info.goods_id) { + that.goods_sku_no = info.skuList.filter(item => item.goods_id === info.goods_id)[0].goods_sku_no; + } + // that.goods_sku_no = info.skuList[0].goods_sku_no } that.allPicture = info.goods_images.length; if (type == 1) {