From 0810b43ff876b6fc2f66167bf1cdceef71c9ff19 Mon Sep 17 00:00:00 2001 From: 1154079537 <1154079537@qq.com> Date: Wed, 22 May 2024 18:21:10 +0800 Subject: [PATCH] =?UTF-8?q?=E6=89=B9=E5=8F=91=E5=AD=97=E6=AE=B5=E4=BF=AE?= =?UTF-8?q?=E6=94=B9?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- pages/product/addGoodDetail/addGoodDetail.vue | 23 ++++++++------ pages/product/addGoodDetail/goodsPrice.vue | 31 +++++++++++-------- 2 files changed, 32 insertions(+), 22 deletions(-) diff --git a/pages/product/addGoodDetail/addGoodDetail.vue b/pages/product/addGoodDetail/addGoodDetail.vue index 49dc292..20d65b8 100644 --- a/pages/product/addGoodDetail/addGoodDetail.vue +++ b/pages/product/addGoodDetail/addGoodDetail.vue @@ -135,6 +135,7 @@ 规格与价格 + @@ -147,17 +148,19 @@ - - - {{item.price}}元/{{item.unit_name}} - - {{item.wholesale_price}}元/{{item.wholesale_unit_name}} + + + + {{item.price}}元/{{item.unit_name}} + + + {{item.stock}} @@ -188,11 +191,8 @@ - - - @@ -742,7 +742,12 @@ async initFormData(option) { - this.isWholeSale = this.$store.state.app.userInfo?.mer_info?.wholesale == 2; + if (this.$store.state.app.userInfo?.mer_info?.wholesale == 0) { + this.isWholeSale = false; + } else { + this.isWholeSale = true; + } + this.mer_id = option.mer_id if (option.formData) { this.formData = JSON.parse(option.formData) diff --git a/pages/product/addGoodDetail/goodsPrice.vue b/pages/product/addGoodDetail/goodsPrice.vue index 913fb41..b90740d 100644 --- a/pages/product/addGoodDetail/goodsPrice.vue +++ b/pages/product/addGoodDetail/goodsPrice.vue @@ -13,19 +13,7 @@ - - - - / - - - - - + + + + + / + + + + @@ -313,7 +313,12 @@ } }, onLoad(option) { - this.isWholeSale = this.$store.state.app.userInfo?.mer_info?.wholesale == 2; + if (this.$store.state.app.userInfo?.mer_info?.wholesale == 2 || this.$store.state.app.userInfo?.mer_info + ?.wholesale == 1) { + this.isWholeSale = true; + } else { + this.isWholeSale = false; + } this.initFomrData(option) this.attrValue = this.formData.attrValue this.attrValue.forEach(item => {