|
@@ -84,14 +84,13 @@
|
|
|
</view>
|
|
|
<text class="img-tip">失效</text>
|
|
|
<view class="pros-img">
|
|
|
- <image :src="failure.image ? failure.image:''" alt="" />
|
|
|
+ <image :src="failure.mainImage ? failure.mainImage:''" alt="" />
|
|
|
</view>
|
|
|
<view class="pros-product">
|
|
|
- <view class="producttitle">{{failure.name}}</view>
|
|
|
+ <view class="producttitle">{{failure.productName}}</view>
|
|
|
<view class="productspec">规格:{{failure.unit ? failure.unit : ''}}</view>
|
|
|
- <view class="productstate">{{failureStateText(failure.status)}}</view>
|
|
|
+ <view class="productstate">商品已下架</view>
|
|
|
</view>
|
|
|
- <view class="pros-marks" v-if="failure.isFailureLayer"></view>
|
|
|
</view>
|
|
|
</view>
|
|
|
</view>
|
|
@@ -261,9 +260,9 @@
|
|
|
} else {
|
|
|
this.goodsList = [];
|
|
|
}
|
|
|
- if( data.invalid && data.invalid.length > 0){
|
|
|
+ if( data.products && data.products.length > 0){
|
|
|
let newFailureList = [],isFailureLayer;
|
|
|
- data.invalid.forEach((failure,index) => {
|
|
|
+ data.products.forEach((failure,index) => {
|
|
|
if(failure.status == 1 || failure.status == 2) {
|
|
|
isFailureLayer = true
|
|
|
}else{
|
|
@@ -690,7 +689,7 @@
|
|
|
deletefailureList(){
|
|
|
this.failureList.forEach(failure=>{ this.delGoodsList += failure.productId+',' })
|
|
|
this.modal = true;
|
|
|
- this.contentModalText = '确定删除选中的商品吗?';
|
|
|
+ this.contentModalText = '确定清除所有失效商品吗?';
|
|
|
this.deleteType = 2
|
|
|
},
|
|
|
handleClick(e) {//用户操作订单
|
|
@@ -727,16 +726,8 @@
|
|
|
this.$api.navigateTo(`/pages/goods/product?id=${id}`)
|
|
|
},
|
|
|
failureToProduct(failure){
|
|
|
- if(failure.status == 1){
|
|
|
- this.$util.msg('商品已丢失,不能查看',2000)
|
|
|
- return
|
|
|
- }else if(failure.status == 2){
|
|
|
- this.$util.msg('商品已停售,不能查看',2000)
|
|
|
- return
|
|
|
- }else{
|
|
|
- this.isModallayer = true;
|
|
|
- this.$api.navigateTo(`/pages/goods/product?id=${failure.productId}`)
|
|
|
- }
|
|
|
+ this.isModallayer = true;
|
|
|
+ this.$api.navigateTo(`/pages/goods/product?id=${failure.productId}`)
|
|
|
},
|
|
|
failureStateText(state){
|
|
|
let stateText = '',
|