diff --git a/src/views/wpm_bx/inmOut.vue b/src/views/wpm_bx/inmOut.vue index 97bca4be..c32f3701 100644 --- a/src/views/wpm_bx/inmOut.vue +++ b/src/views/wpm_bx/inmOut.vue @@ -270,6 +270,17 @@ 取消 + +

没有找到该前缀的发货编号,请完善发货流水号位数(填整数)

+ + + + + + +
{ let number_out_last = ''; - if(res.number_out_last==null){ - number_out_last = that.prefix+'000'; - }else{ + if(res.number_out_last==null){//没有该前缀的发货编号 + number_out_last = null; + that.showBatch=false; + that.showDigit = true; + }else{//有该前缀的发货编号 + let items = []; number_out_last = res.number_out_last; - } - that.number_out_last = number_out_last; - let num = number_out_last.slice(-3) - let str = number_out_last.slice(0,-3) - let items = []; - for(let i=0;i< that.wprList.length;i++){ - let obj = {}; - let numb = Number(num)+i+1; - if(numb<10){ - numb = '00'+numb; - }else if(numb<100){ - numb = '0'+numb; + let str = number_out_last.replace(/[^a-zA-Z]/g, ''); // 提取字母 + let num = number_out_last.replace(/[^0-9]/g, ''); // 提取数字 + let length = num.length;//流水号的长度 + for(let i=0;i< that.wprList.length;i++){ + let numb = Number(num)+i+1; + let numbs = numb+''; + let len = numbs.length; + let zoreStr = ''; + for(let j=0;j { + that.showBatch=false; + that.getRowWpr(); + }) } - let params = {}; + }) + }, + //没有找到前缀的发货编号,从1开始编号时 + digitSure(){ + let that = this; + //根据前缀和流水位数获取编号 + let items = []; + for(let i=0;i< that.wprList.length;i++){ + let numb = i+1,zoreStr = ''; + numb+= ''; + let len = numb.length; + for(let j=0;j { + that.showDigit = false; that.getRowWpr(); }) - }) }, //本地更新数据 handleSaveSuccess(data, mode) {