From 8e4aa88d5b4b85d19cdaf49f14fca22540b7e3dd Mon Sep 17 00:00:00 2001 From: cdk <2441919651@qq.com> Date: 星期一, 15 九月 2025 09:52:50 +0800 Subject: [PATCH] 其他出库加入库存限制 --- H5/Js/BarCfBefore.js | 8 +++++--- 1 files changed, 5 insertions(+), 3 deletions(-) diff --git a/H5/Js/BarCfBefore.js b/H5/Js/BarCfBefore.js index 449abc5..ced1062 100644 --- a/H5/Js/BarCfBefore.js +++ b/H5/Js/BarCfBefore.js @@ -68,7 +68,7 @@ var that = this; that.isLoading = true; - that.AxiosHttp("post", 'MesBarCF/GetBarInfo', { + that.AxiosHttp("post", 'MesBarCF/GetBarInfoBefore', { barcode: that.formData.barcode, }, false) .then(function (res) { @@ -115,16 +115,18 @@ that.$toast.fail("鎷嗗垎鏁伴噺涓嶈兘涓虹┖锛�"); return; } - if (that.formData.cfNum > that.formData.sumQuantity) { + + if (parseFloat(that.formData.cfNum) > parseFloat(that.formData.sumQuantity)) { that.$toast.fail("鎷嗗垎鏁伴噺涓嶈兘澶т簬鏉$爜鏁伴噺锛�"); return; } + if (that.formData.barcode.length * 1 <= 0) { that.$toast.fail("鐗╂枡鏉$爜涓嶈兘涓虹┖锛�"); return; } that.isLoading = true; - that.AxiosHttp("post", 'MesBarCF/BarCF', { + that.AxiosHttp("post", 'MesBarCF/BarCfBefore', { userName: that.userInfo.loginAccount, barcode: that.formData.barcode, CfNum: that.formData.cfNum, -- Gitblit v1.9.3