From 7372a71c35150a37c4cf1b5e83d96f7f8bc374d3 Mon Sep 17 00:00:00 2001 From: 快乐的昕的电脑 <快乐的昕的电脑@DESKTOP-C2BQPQU> Date: 星期五, 12 九月 2025 17:29:33 +0800 Subject: [PATCH] 销售出库:条码拆分更改为存储过程实现 --- H5/Js/My.js | 64 ++++++++++++++++++++++++++------ 1 files changed, 52 insertions(+), 12 deletions(-) diff --git a/H5/Js/My.js b/H5/Js/My.js index 8dd73e0..d4fa6a0 100644 --- a/H5/Js/My.js +++ b/H5/Js/My.js @@ -44,7 +44,11 @@ img: "../Images/print.png", path: '/H5/Config.aspx' } - ] + ], + actions: [],//鍒楄〃鐨勫�� + orgName: "",//绾夸綋鍚嶇О + orgId: "",//绾夸綋缂栧彿 + show: false,//鍒楄〃灞曠ず } }, mounted() { @@ -82,20 +86,56 @@ }); }, - goOrg() { + changeOrg() { + this.show = true; var that = this; - this.$dialog.confirm({ - title: '鍙嬫儏鎻愮ず', - message: '纭畾鍒囨崲褰撳墠缁勭粐锛�', - confirmButtonText: '纭畾', - cancelButtonText: '鍙栨秷' - }) - .then(() => { - window.location.href = "/UserLogin.aspx"; + that.actions = []; + that.isLoading = true; + that.AxiosHttp("post", 'Login/changeOrg', { + userName: that.userInfo.loginAccount + }, false) + .then(function (res) { + var json = res; + if (json.status == 0) { + + if (json.data.tbBillList.length <= 0) { + that.$toast.fail("娌℃湁鍙敤鐨勬暟鎹�"); + that.$playSound('error'); + } else { + that.itemInfo = json.data.tbBillList; + that.actions = json.data.tbBillList.map(item => { + return { + name: item.orgName, + orgId: item.orgId, // 鏂板 + orgNo: item.orgNo // 鏂板 + }; + }); + } + } + else { + that.$toast.fail(json.message); + that.$playSound('error'); + } + that.isLoading = false; }) - .catch(() => { - // on cancel + .catch(function (error) { + that.isLoading = false; + that.$toast.fail("缃戠粶閿欒锛岃閲嶈瘯锛�"); + that.$playSound('error'); + console.log(error); }); }, + + onSelect(action) { + //this.xtNum = action.lineNo; // 缁戝畾line_no鍒皒tNum瀛楁 + //console.log("閫夋嫨鐨勭嚎浣撶紪鍙凤細", this.xtNum); + //this.xtName = action.name; // 缁戝畾name鍒皒tName瀛楁 + //this.show = false; + + Cookies.set('orgId', action.orgId); + Cookies.set('orgNo', action.orgNo); + Cookies.set('orgName', action.name); + this.show = false; + }, } }) \ No newline at end of file -- Gitblit v1.9.3