|  |  | 
 |  |  |          </view> | 
 |  |  |          <view class="item"> | 
 |  |  |             <view class="code-decs">暂存位:</view> | 
 |  |  |             <input type="text" placeholder=" 扫码 / 输入" v-model="stationCode" :focus="matFocus"> | 
 |  |  |             <input type="text" placeholder=" 扫码 / 输入" v-model="stationCode" :focus="stationCodeFocus" | 
 |  |  |                @input="stationCodeInput()"> | 
 |  |  |             <view class="item-right"> | 
 |  |  |                <button></button> | 
 |  |  |                <!-- <text style="text-align: right;color: #409EFF;" @click="selectMat()">提取+</text> --> | 
 |  |  | 
 |  |  |             token: '', | 
 |  |  |             barcode: '', | 
 |  |  |             stationCode: '', | 
 |  |  |             stationCodeFocus: false, | 
 |  |  |             dataList: [], | 
 |  |  |             count: 0, | 
 |  |  |             rowNum: '', | 
 |  |  | 
 |  |  |             this.msgType1 = type | 
 |  |  |             this.$refs.message.open() | 
 |  |  |          }, | 
 |  |  |          stationCodeInput() { | 
 |  |  |             setTimeout(() => { | 
 |  |  |                var len = this.stationCode.length | 
 |  |  |                if (len != 15) { | 
 |  |  |                   this.stationCode = '' | 
 |  |  |                   this.stationCodeFocus = true | 
 |  |  |                   uni.showToast({ | 
 |  |  |                      title: '暂存码有误请重试', | 
 |  |  |                      icon: "none", | 
 |  |  |                      position: 'top' | 
 |  |  |                   }); | 
 |  |  |                   return; | 
 |  |  |                } | 
 |  |  |                this.focuss() | 
 |  |  |             }, 200) | 
 |  |  |          }, | 
 |  |  |          // barcode input 事件 | 
 |  |  |          barcodeInput() { | 
 |  |  |             // 不设置定时器 会出现扫入的字符串不全 | 
 |  |  |             setTimeout(() => { | 
 |  |  |                var len = this.barcode.length | 
 |  |  |                if (len != 8) { | 
 |  |  |                if (len != 10) { | 
 |  |  |                   uni.showToast({ | 
 |  |  |                      title: '托盘码有误请重试', | 
 |  |  |                      icon: "none", | 
 |  |  | 
 |  |  |                   this.barcodeFocuss() | 
 |  |  |                   return; | 
 |  |  |                } | 
 |  |  |                this.focuss() | 
 |  |  |                this.stationCodeFocuss() | 
 |  |  |             }, 200) | 
 |  |  |          }, | 
 |  |  |          // 暂存位有误重置 | 
 |  |  |          stationCodeFocuss() { | 
 |  |  |             let that = this; | 
 |  |  |             that.stationCodeFocus = false; | 
 |  |  |             setTimeout(() => { | 
 |  |  |                that.stationCodeFocus = true; | 
 |  |  |             }, 100); | 
 |  |  |          }, | 
 |  |  |          // 托盘码有误重置 | 
 |  |  |          barcodeFocuss() { | 
 |  |  | 
 |  |  |          // 确认重置 | 
 |  |  |          resetConfirm() { | 
 |  |  |             this.dataList = [] | 
 |  |  |             this.barcode = '' | 
 |  |  |             this.stationCode = '' | 
 |  |  |             this.messageText = "重置完成" | 
 |  |  |             this.messageToggle('success') |