|
|
|
@ -202,8 +202,8 @@ export default {
|
|
|
|
|
this.originCode = this.udiCode;
|
|
|
|
|
} else if (response.code == 501) {
|
|
|
|
|
this.checkSuccess = false;
|
|
|
|
|
this.$refs.inputRef.focus();
|
|
|
|
|
this.$refs.inputRef.select();
|
|
|
|
|
// this.$refs.inputRef.focus();
|
|
|
|
|
// this.$refs.inputRef.select();
|
|
|
|
|
this.originCode = "";
|
|
|
|
|
this.$message.error(response.message);
|
|
|
|
|
} else if (response.code == 503) {
|
|
|
|
@ -225,6 +225,7 @@ export default {
|
|
|
|
|
this.udiCode = "01" + response.data.nameCode;
|
|
|
|
|
this.originCode = this.udiCode;
|
|
|
|
|
} else {
|
|
|
|
|
this.originCode = "";
|
|
|
|
|
this.$alert(response.message, '提示', {
|
|
|
|
|
confirmButtonText: '确定',
|
|
|
|
|
type: 'warning',
|
|
|
|
@ -397,21 +398,22 @@ export default {
|
|
|
|
|
window.sc = new A.KeyScaner(inputer);//传入要监听的DOM节点
|
|
|
|
|
sc.onInput = function (text) {
|
|
|
|
|
if (text.includes("delete")) {
|
|
|
|
|
that.vailQuery.code = "";
|
|
|
|
|
that.udiCode = "";
|
|
|
|
|
that.sictomText = "";
|
|
|
|
|
that.originCode = "";
|
|
|
|
|
return;
|
|
|
|
|
}
|
|
|
|
|
if (that.sitcomScan) {
|
|
|
|
|
let tempTxt = text;
|
|
|
|
|
let str = tempTxt.replace(/[\r]/g, "");
|
|
|
|
|
that.sictomText = that.sictomText + str;
|
|
|
|
|
that.vailQuery.code = that.sictomText;
|
|
|
|
|
that.udiCode = that.sictomText;
|
|
|
|
|
} else {
|
|
|
|
|
that.vailQuery.code = text;
|
|
|
|
|
that.udiCode = text;
|
|
|
|
|
}
|
|
|
|
|
};
|
|
|
|
|
inputer.focus();
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
},
|
|
|
|
|
created() {
|
|
|
|
|
|
|
|
|
|