cnf
6 天以前 32274bc8fad5251f78229d67d86c234a4b32df2e
H5/Js/Scll.js
@@ -37,7 +37,7 @@
        getModel() {
            var that = this;
            that.isLoading = true;
            that.AxiosHttp("post", 'Womdaa/GetItemsByDaa001', {
            that.AxiosHttp("post", 'Womdaa/GetItemsByDaa001User', {
                daa001: that.modeInfo.daa001,
                userName: that.userInfo.loginAccount
            }, false)
@@ -48,10 +48,12 @@
                        console.log(json)
                        that.ItemDetail = json.data.tbBillList;
                        that.modeInfo.planNo = json.data.tbBillList.planNo;
                        that.$playSound('success');
                        that.$refs.barcode.focus();
                    }
                    else {
                        that.$toast.fail(json.message);
                        that.$playSound('error');
                        that.$refs.daa001.focus();
                        that.modeInfo.daa001 = "";
                        that.modeInfo.planNo = "";
@@ -62,6 +64,43 @@
                .catch(function (error) {
                    that.isLoading = false;
                    that.$toast.fail("网络错误,请重试!");
                    that.$playSound('error');
                    console.log(error);
                    that.$refs.daa001.focus();
                    that.modeInfo.daa001 = "";
                });
        },
        getModelAll() {
            var that = this;
            that.isLoading = true;
            that.AxiosHttp("post", 'Womdaa/GetItemsByDaa001', {
                daa001: that.modeInfo.daa001,
                userName: that.userInfo.loginAccount
            }, false)
                .then(function (res) {
                    var json = res;
                    if (json.status == 0) {
                        console.log(json)
                        that.ItemDetail = json.data.tbBillList;
                        that.modeInfo.planNo = json.data.tbBillList.planNo;
                        that.$playSound('success');
                        that.$refs.barcode.focus();
                    }
                    else {
                        that.$toast.fail(json.message);
                        that.$playSound('error');
                        that.$refs.daa001.focus();
                        that.modeInfo.daa001 = "";
                        that.modeInfo.planNo = "";
                        that.ItemDetail = [];
                    }
                    that.isLoading = false;
                })
                .catch(function (error) {
                    that.isLoading = false;
                    that.$toast.fail("网络错误,请重试!");
                    that.$playSound('error');
                    console.log(error);
                    that.$refs.daa001.focus();
                    that.modeInfo.daa001 = "";
@@ -76,10 +115,12 @@
            var that = this;
            if (that.modeInfo.daa001.length <= 0) {
                that.$toast.fail("工单单号不能为空!");
                that.$playSound('error');
                return;
            }
            if (that.scanInfo.barcode.length * 1 <= 0) {
                that.$toast.fail("物料条码不能为空!");
                that.$playSound('error');
                return;
            }
@@ -101,6 +142,7 @@
                    }
                    else if (json.status == 2) {
                        that.$refs.splitNum.focus();
                        that.$playSound('success');
                        that.scanInfo.splitNum = json.data.tbBillList.splitNum;
                        that.scanInfo.barcodeNum = json.data.tbBillList.barcodeNum;
                    }
@@ -129,14 +171,17 @@
            var that = this;
            if (that.modeInfo.daa001.length <= 0) {
                that.$toast.fail("工单单号不能为空!");
                that.$playSound('error');
                return;
            }
            if (that.scanInfo.splitNum * 1 <= 0) {
                that.$toast.fail("拆分数量不能为空!");
                that.$playSound('error');
                return;
            }
            if (that.scanInfo.barcode.length * 1 <= 0) {
                that.$toast.fail("物料条码不能为空!");
                that.$playSound('error');
                return;
            }
            //that.ip = "";