Commit 57018328 authored by 何远江's avatar 何远江

更新地址、bug修改

parent 678d25af
...@@ -109,7 +109,7 @@ export default { ...@@ -109,7 +109,7 @@ export default {
computed:{ computed:{
totalNum(){ totalNum(){
let num = 0; let num = 0;
this.goodsList.forEach((ele) => { this.list.forEach((ele) => {
num += ele.totalQuantity; num += ele.totalQuantity;
}); });
return num return num
...@@ -136,12 +136,12 @@ export default { ...@@ -136,12 +136,12 @@ export default {
} }
let params = [] let params = []
let item = [] let item = []
this.goodsList.forEach(ele => { this.list.forEach(ele => {
item.push({ item.push({
AUFNR:ele.workorderNo, AUFNR:ele.workorderNo,
PLNR: ele.qrcode, PLNR: ele.qrcode,
MATNR: ele.sapItemCode, MATNR: ele.sapItemCode,
WERKS: ele.factory, WERKS: this.vuex_user_factory,
LGORT: this.LGORT, LGORT: this.LGORT,
PACKNR: ele.qrcode, PACKNR: ele.qrcode,
ZSIZE: ele.standardSize, ZSIZE: ele.standardSize,
......
...@@ -7,8 +7,8 @@ ...@@ -7,8 +7,8 @@
<view class="item">产品编号:{{ item.sapItemCode }}</view> <view class="item">产品编号:{{ item.sapItemCode }}</view>
<view class="item">产品描述:{{ item.itemName }}</view> <view class="item">产品描述:{{ item.itemName }}</view>
<view class="item">入库仓位:{{ item.NLPLA }}</view> <view class="item">入库仓位:{{ item.NLPLA }}</view>
<view class="item">入库数量:{{ item.quantity }}</view> <view class="item">入库数量:{{ filterQuantity() }}</view>
<view class="item">loss数量:{{ item.lossNum }}</view> <view class="item">loss数量:{{ filterLoss() }}</view>
</view> </view>
<u-button size="mini" type="primary" plain @click="deleGonds(idx)"> <u-button size="mini" type="primary" plain @click="deleGonds(idx)">
<u-icon name="trash" size="28"></u-icon> <u-icon name="trash" size="28"></u-icon>
...@@ -33,6 +33,7 @@ ...@@ -33,6 +33,7 @@
<view class="bottomItem" v-for="(ele, idx) in list" :key="ele.qrcode+idx" v-if="ele.qrcode === item.qrcode"> <view class="bottomItem" v-for="(ele, idx) in list" :key="ele.qrcode+idx" v-if="ele.qrcode === item.qrcode">
<view class="items">尺码:{{ ele.standardSize }}</view> <view class="items">尺码:{{ ele.standardSize }}</view>
<view class="items">数量:{{ ele.quantity }}</view> <view class="items">数量:{{ ele.quantity }}</view>
<view class="items">loss数量:{{ ele.lossNum }}</view>
</view> </view>
</view> </view>
</view> </view>
...@@ -81,6 +82,12 @@ export default { ...@@ -81,6 +82,12 @@ export default {
deleGonds(idx) { deleGonds(idx) {
this.$emit('deleGonds',idx) this.$emit('deleGonds',idx)
}, },
filterQuantity() {
return this.list.filter(v => v.qrcode == this.item.qrcode).reduce((acc, cur) => acc + cur.quantity, 0)
},
filterLoss() {
return this.list.filter(v => v.qrcode == this.item.qrcode).reduce((acc, cur) => acc + cur.lossNum, 0)
}
} }
}; };
</script> </script>
......
...@@ -237,7 +237,7 @@ export default { ...@@ -237,7 +237,7 @@ export default {
this.$u.toast("提交成功"); this.$u.toast("提交成功");
setTimeout(() => { setTimeout(() => {
this.goBack(); this.goBack();
}, 1000); }, 3000);
} else { } else {
this.$u.toast(res.msg); this.$u.toast(res.msg);
} }
......
...@@ -78,9 +78,9 @@ class Request { ...@@ -78,9 +78,9 @@ class Request {
// 处理sap接口 // 处理sap接口
let url = this.config.baseUrl let url = this.config.baseUrl
if (options.url.indexOf('sap') > -1) { if (options.url.indexOf('sap') > -1) {
// #ifdef APP-PLUS // #ifdef APP-PLUS
url = 'http://192.168.3.109:8000' url = 'http://192.168.3.109:8000'
// #endif // #endif
options.header = { options.header = {
...options.header, ...options.header,
...@@ -101,10 +101,10 @@ class Request { ...@@ -101,10 +101,10 @@ class Request {
...options.header, ...options.header,
'content-type': 'application/json;charset=UTF-8', 'content-type': 'application/json;charset=UTF-8',
} }
url = 'http://192.168.3.91:8100' url = 'http://192.168.3.181:8100'
} else { } else {
// console.log('mobile') // console.log('mobile')
url = 'http://192.168.3.91:8100' url = 'http://192.168.3.181:8100'
} }
// 判断用户传递的URL是否/开头,如果不是,加上/,这里使用了uView的test.js验证库的url()方法 // 判断用户传递的URL是否/开头,如果不是,加上/,这里使用了uView的test.js验证库的url()方法
options.url = validate.url(options.url) ? options.url : (url + (options.url.indexOf('/') == 0 ? options.url = validate.url(options.url) ? options.url : (url + (options.url.indexOf('/') == 0 ?
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment