Browse Source

修复线上 商品权限问题

zhengjinyi 4 năm trước cách đây
mục cha
commit
99914fb0d5
1 tập tin đã thay đổi với 5 bổ sung5 xóa
  1. 5 5
      pages/goods/product.vue

+ 5 - 5
pages/goods/product.vue

@@ -396,9 +396,9 @@
 					this.shopId = response.data.shopID
 					this.product = response.data
 					//已删除/已冻结
-					if(this.product.validFlag === '0' || this.product.validFlag =='10'){
+					if(this.product.validFlag === 0 || this.product.validFlag ==10){
 						this.isInvalid = true
-					}else if(this.product.validFlag === '9'){
+					}else if(this.product.validFlag === 9){
 						if(this.userIdentity == 1){
 							this.isInvalid = false
 						}else{
@@ -428,7 +428,7 @@
 					}
 					
 					//处理下架商品和售罄商品
-					if(this.product.validFlag =='3' || this.stock == 0){
+					if(this.product.validFlag ==3 || this.stock == 0){
 						this.isNoneDisabled = true
 						this.disabled = true
 					}else{
@@ -449,10 +449,10 @@
 					}
 					this.goodsData.disabled = this.disabled
 					this.goodsData.isNoneDisabled = this.isNoneDisabled
-					if(this.product.validFlag =='3'){
+					if(this.product.validFlag ==3){
 						this.goodsData.disabledText = '下架'
 					}
-					if(this.product.validFlag =='10'){
+					if(this.product.validFlag ==10){
 						this.goodsData.disabledText = '停售'
 					}
 					if(this.stock == 0){