|
|
@ -115,17 +115,9 @@ |
|
|
<view class="shop-popup-title-right-box" style="color: #088FEB;">{{goodsDetail.productName}} |
|
|
<view class="shop-popup-title-right-box" style="color: #088FEB;">{{goodsDetail.productName}} |
|
|
</view> |
|
|
</view> |
|
|
<view class="shop-popup-title-right-box">{{goodsDetail.productSn}}</view> |
|
|
<view class="shop-popup-title-right-box">{{goodsDetail.productSn}}</view> |
|
|
<!-- <view class="popup-title-right-box" style="color: darkorange;" |
|
|
|
|
|
@tap="inputDialogToggle('payDialog')"> |
|
|
|
|
|
<text style="margin-right:20rpx;">修改价格</text> |
|
|
|
|
|
</view> --> |
|
|
|
|
|
</view> |
|
|
</view> |
|
|
</view> |
|
|
</view> |
|
|
<view class="shop-popup-container"> |
|
|
<view class="shop-popup-container"> |
|
|
<!-- <view class="shop-purchase-price" v-if="storageType == 0"> |
|
|
|
|
|
<view style="margin-right: 20rpx;">实际价格</view> |
|
|
|
|
|
<uni-easyinput type="text" v-model="purchasePrice" placeholder="请输入实际价格" /> |
|
|
|
|
|
</view> --> |
|
|
|
|
|
<ul style="border-top:20rpx;"> |
|
|
<ul style="border-top:20rpx;"> |
|
|
<li v-for="(items,index) in goodsDetail.attributeList" :key="index"> |
|
|
<li v-for="(items,index) in goodsDetail.attributeList" :key="index"> |
|
|
<view class="shop-title-fur"> |
|
|
<view class="shop-title-fur"> |
|
|
@ -141,7 +133,7 @@ |
|
|
</ul> |
|
|
</ul> |
|
|
<view class="shop-checkList" v-for="(item,index) in temporaryList" :key="index"> |
|
|
<view class="shop-checkList" v-for="(item,index) in temporaryList" :key="index"> |
|
|
<view class="shop-checkList-box"> |
|
|
<view class="shop-checkList-box"> |
|
|
{{item.name}} |
|
|
<text style="width: 300rpx;display: inline-block;">{{item.name}}</text> <text style="color:#777;font-size: 12px;">库存:{{item.productNum}}</text> |
|
|
</view> |
|
|
</view> |
|
|
<uni-number-box max='1000000' v-model="item.productCount" @change="temporaryChange" /> |
|
|
<uni-number-box max='1000000' v-model="item.productCount" @change="temporaryChange" /> |
|
|
</view> |
|
|
</view> |
|
|
@ -196,7 +188,9 @@ |
|
|
keyList: [], |
|
|
keyList: [], |
|
|
temporaryList: [], |
|
|
temporaryList: [], |
|
|
zNum: 0, |
|
|
zNum: 0, |
|
|
storageType:'' |
|
|
storageType:'', |
|
|
|
|
|
productNum:0, |
|
|
|
|
|
productId:'' |
|
|
} |
|
|
} |
|
|
}, |
|
|
}, |
|
|
filters: { |
|
|
filters: { |
|
|
@ -288,7 +282,8 @@ |
|
|
methods: { |
|
|
methods: { |
|
|
scanCodeAdd() { |
|
|
scanCodeAdd() { |
|
|
uni.scanCode({ |
|
|
uni.scanCode({ |
|
|
success: (res) => { |
|
|
success: (res) => { |
|
|
|
|
|
this.productId = res.result |
|
|
this.toggle('bottom', res.result); |
|
|
this.toggle('bottom', res.result); |
|
|
}, |
|
|
}, |
|
|
fail: (res) => { |
|
|
fail: (res) => { |
|
|
@ -330,37 +325,48 @@ |
|
|
jishuqi++ |
|
|
jishuqi++ |
|
|
} |
|
|
} |
|
|
} |
|
|
} |
|
|
if (this.goodsDetail.attributeList.length == jishuqi) { |
|
|
if (this.goodsDetail.attributeList.length == jishuqi) { |
|
|
this.attributeList = { |
|
|
this.tui.request("/app/stock/productCount", "post", { |
|
|
attributeList: JSON.stringify(obj), |
|
|
productId: this.productId, |
|
|
productCount: this.temporaryNum, |
|
|
attributeList: JSON.stringify(obj) |
|
|
name: name, |
|
|
}, false, true).then((res) => { |
|
|
price: this.purchasePrice |
|
|
if (res.code == 200) { |
|
|
} |
|
|
this.productNum = res.result |
|
|
|
|
|
this.attributeList = { |
|
|
for (let i = 0; i < this.goodsDetail.attributeList.length; i++) { |
|
|
attributeList: JSON.stringify(obj), |
|
|
this.goodsDetail.attributeList[i].isChecked = false; |
|
|
productCount: this.temporaryNum, |
|
|
for (let m = 0; m < this.goodsDetail.attributeList[i].value.length; m++) { |
|
|
productNum:this.productNum, |
|
|
this.goodsDetail.attributeList[i].value[m].isChecked = false |
|
|
name: name, |
|
|
} |
|
|
price: this.purchasePrice |
|
|
} |
|
|
} |
|
|
if (this.temporaryList.length == 0) { |
|
|
|
|
|
this.temporaryList.push(this.attributeList); |
|
|
for (let i = 0; i < this.goodsDetail.attributeList.length; i++) { |
|
|
} else { |
|
|
this.goodsDetail.attributeList[i].isChecked = false; |
|
|
for (var i = 0; i < this.temporaryList.length; i++) { |
|
|
for (let m = 0; m < this.goodsDetail.attributeList[i].value.length; m++) { |
|
|
if (this.temporaryList[i].name.indexOf(this.attributeList.name) == -1 || this.temporaryList[i].name.indexOf(this.attributeList.name) == 1) { |
|
|
this.goodsDetail.attributeList[i].value[m].isChecked = false |
|
|
if (this.temporaryList.length == (i + 1)) { |
|
|
} |
|
|
this.temporaryList.push(this.attributeList); |
|
|
} |
|
|
return |
|
|
if (this.temporaryList.length == 0) { |
|
|
} |
|
|
this.temporaryList.push(this.attributeList); |
|
|
} else { |
|
|
} else { |
|
|
this.temporaryList[i] = this.attributeList |
|
|
for (var i = 0; i < this.temporaryList.length; i++) { |
|
|
return |
|
|
if (this.temporaryList[i].name.indexOf(this.attributeList.name) == -1 || this.temporaryList[i].name.indexOf(this.attributeList.name) == 1) { |
|
|
|
|
|
if (this.temporaryList.length == (i + 1)) { |
|
|
} |
|
|
this.temporaryList.push(this.attributeList); |
|
|
} |
|
|
return |
|
|
|
|
|
} |
|
|
} |
|
|
} else { |
|
|
|
|
|
this.temporaryList[i] = this.attributeList |
|
|
|
|
|
return |
|
|
|
|
|
|
|
|
|
|
|
} |
|
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
} |
|
|
|
|
|
} else { |
|
|
|
|
|
this.tui.toast(res.message) |
|
|
|
|
|
} |
|
|
|
|
|
}).catch((res) => {}) |
|
|
|
|
|
|
|
|
} |
|
|
} |
|
|
|
|
|
|
|
|
|