Commit f55be31d by liangjianmin

bug

parent f186ab76
Showing with 19 additions and 3 deletions
...@@ -57,8 +57,8 @@ ...@@ -57,8 +57,8 @@
<view class="uni-tr row verCenter" v-for="(item, index) in exceptionlist" :key="index"> <view class="uni-tr row verCenter" v-for="(item, index) in exceptionlist" :key="index">
<text class="txt w row verCenter">{{ item.model }}</text> <text class="txt w row verCenter">{{ item.model }}</text>
<text class="txt w row verCenter">{{ item.order_data }}</text> <text class="txt w row verCenter">{{ item.order_data }}</text>
<input class="w uni-input" type="text" /> <input class="w uni-input" type="text" @input="onInput($event, index)" />
<view class="w" style="padding-left: 0;"><switch checked style="transform: scale(0.5);" color="#197ADB" /></view> <view class="w" style="padding-left: 0;"><switch @change="switchChange($event, index)" style="transform: scale(0.5);" color="#197ADB" /></view>
</view> </view>
</view> </view>
<view class="upload-box"> <view class="upload-box">
...@@ -108,7 +108,8 @@ export default { ...@@ -108,7 +108,8 @@ export default {
erp_order_sn: 'B50413', //入仓号 erp_order_sn: 'B50413', //入仓号
sort_goods_img: '', //问题图片 sort_goods_img: '', //问题图片
ask_customer_remark: '', //仓库问客备注 ask_customer_remark: '', //仓库问客备注
entrys: {} entrys: {},
exception: []
} }
}; };
}, },
...@@ -154,6 +155,14 @@ export default { ...@@ -154,6 +155,14 @@ export default {
this.request(API.getExceptionData, 'POST', { ask_customer_exception_id: this.ask_customer_exception_id, entrys: this.form.entrys }, true).then(res => { this.request(API.getExceptionData, 'POST', { ask_customer_exception_id: this.ask_customer_exception_id, entrys: this.form.entrys }, true).then(res => {
if (res.err_code === 0) { if (res.err_code === 0) {
this.exceptionlist = res.data; this.exceptionlist = res.data;
if (res.data.length > 0) {
for (let i = 0; i < res.data.length; i++) {
this.form.exception.push({
val: '',
is: false
});
}
}
} else { } else {
uni.showToast({ uni.showToast({
title: res.err_msg, title: res.err_msg,
...@@ -162,6 +171,13 @@ export default { ...@@ -162,6 +171,13 @@ export default {
} }
}); });
}, },
onInput(e, index) {
this.form.exception[index].val = e.detail.value;
},
switchChange(e, index) {
console.log(e.target.value);
this.$set(this.form.exception[index], 'is', e.target.value);
},
toggle() { toggle() {
this.flag = !this.flag; this.flag = !this.flag;
}, },
......
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 sign in to comment