Commit cf6042b6 by 施宇

1

parent 69b15da7
......@@ -13,6 +13,7 @@ Page({
data: {
inputVal:"",
listArr:[],
pickTaskId:"",
},
/**
......@@ -39,10 +40,32 @@ Page({
},
inputConfirm:function(e){
let {value} = e.detail ;
this.setData({
inputVal:value
})
this.getList()
let RegXb = /^(XB)\d{11}$/;
let RegKb = /^(KB)\d{11}$/;
if(RegXb.test(value)){//扫描的是箱号
if(!this.data.pickTaskId){
wx.showToast({
title:'请先扫描卡板号',
icon: 'none',
duration: 2000
});
}else{
this.confirmOutStore()
}
}else if(RegKb.test(value)){//扫描的是卡版号
this.setData({
inputVal:value
});
this.getList()
}else{
//型号
wx.showToast({
title:'数据格式不准确',
icon: 'none',
duration: 2000
});
}
},
getList:function(){
let me = this;
......@@ -51,7 +74,12 @@ Page({
let data = res.data;
me.setData({
listArr:data||[]
})
});
if(data.length){
me.setData({
pickTaskId:data[0]['pick_task_detail_id']
})
}
} else {
wx.showToast({
......@@ -62,6 +90,20 @@ Page({
}
}, true,true)
},
confirmOutStore:function(){
let me = this;
getData(apis.confirm_out_store, 'post', {"pick_task_detail_id":me.data.pickTaskId}, function(res) {
if (res.errcode === 0) {
me.getList();
} else {
wx.showToast({
title: res.errmsg,
icon: 'none',
duration: 2000
});
}
}, true,true)
},
fhFun:function(){
let arr = this.data.listArr;
let idArr = []
......
......@@ -39,11 +39,11 @@
<view class="td-2 td borderBox Iflex jcc aic td-119"><text>{{item.pallet_id_cn}}</text></view>
<view class="td-2 td borderBox Iflex jcc aic td-119"><text>{{item.box_id_cn}}</text></view>
<view class="td-2 td borderBox Iflex jcc aic td-119"><text>{{item.warehousing_sn}}</text></view>
<view class="td-2 td borderBox Iflex jcc aic td-119"><text>{{item.out_store_id}}</text></view>
<view class="td-2 td borderBox Iflex jcc aic td-119"><text>{{item.out_store_sn}}</text></view>
<view class="td-2 td borderBox Iflex jcc aic td-58"><text>
<block wx:if="{{item.is_apply_customs == 0}}">否</block>
<block wx:elif="{{item.is_apply_customs == 1}}">是</block></text></view>
<view class="td-2 td borderBox Iflex jcc aic"><text>{{item.confirm_user_id}}</text></view>
<view class="td-2 td borderBox Iflex jcc aic"><text>{{item.confirm_user_name}}</text></view>
<view class="td-2 td borderBox Iflex jcc aic td-125"><text>{{item.confirm_time_cn}}</text></view>
<view class="td-2 td borderBox Iflex jcc aic"><text>{{item.store_id_cn}}</text></view>
</view>
......
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