| | |
| | | <view> |
| | | <view class="itemstyle"> |
| | | <uni-forms label-width="180"> |
| | | <uni-forms-item label="æçæ¡ç :"> |
| | | <uni-easyinput type="text" placeholder="è¯·æ«ææçæ¡ç " ref='midInput' :focus="!focus" v-model="barcode" |
| | | <uni-forms-item label="å°æ ç :"> |
| | | <uni-easyinput type="text" placeholder="è¯·æ«æå°æ ç " ref='midInput' :focus="!focus" v-model="Station" |
| | | @input="StationInput" /> |
| | | </uni-forms-item> |
| | | <uni-forms-item label="æçç :"> |
| | | <uni-easyinput type="text" placeholder="è¯·æ«ææçç " ref='midInput' :focus="focus" v-model="barcode" |
| | | @input="barcodeInput" /> |
| | | </uni-forms-item> |
| | | <uni-forms-item> |
| | |
| | | return { |
| | | focus: false, |
| | | barcode: "", |
| | | Station: "", |
| | | address: "", |
| | | WarehouseId: "" |
| | | } |
| | |
| | | innerAudioContext.src = src; // '../../static/success.mp3'; |
| | | innerAudioContext.play(); |
| | | }, |
| | | barcodeInput() { |
| | | // barcodeInput() { |
| | | // this.$nextTick(function(x) { |
| | | // if (this.barcode.length > 0) { |
| | | // this.focus = true; |
| | | // } |
| | | // }) |
| | | // }, |
| | | StationInput() { |
| | | this.$nextTick(function(x) { |
| | | if (this.barcode.length > 0) { |
| | | if (this.Station.length > 0) { |
| | | this.focus = true; |
| | | } |
| | | }) |
| | | }, |
| | | InEmpty() { |
| | | if (this.Station == "") { |
| | | this.$refs.uToast.show({ |
| | | title: "è¯·æ«æå°æ ç ", |
| | | type: 'error' |
| | | }) |
| | | return; |
| | | } |
| | | if (this.barcode == "") { |
| | | this.$refs.uToast.show({ |
| | | title: "è¯·æ«ææçç ", |
| | |
| | | }) |
| | | return; |
| | | } |
| | | this.$u.post('/api/PDA/InEmpty?barcode=' + this.barcode).then( |
| | | this.$u.post('/api/PDA/InEmpty?barcode=' + this.barcode + '&station=' + this.Station).then( |
| | | res => { |
| | | if (res.status) { |
| | | this.$refs.uToast.show({ |
| | | title: "空æå
¥åºç³è¯·æå", |
| | | type: "success" |
| | | }) |
| | | this.Station = ""; |
| | | this.barcode = ""; |
| | | this.focus = false; |
| | | } else { |
| | | this.$refs.uToast.show({ |
| | | title: res.message, |