From 5ddb70eb0c0a63a355fd792edf533d4ca1e4bb4f Mon Sep 17 00:00:00 2001
From: YL <YL@LAPTOP-SE03PLUR>
Date: 星期三, 12 一月 2022 17:52:16 +0800
Subject: [PATCH] nothing
---
WebTM/views/生产管理/生产包装单/Sc_PackUnionBill.html | 19 ++----
WebTM/views/index.html | 6 ++
WebTM/views/生产管理/报工台工序/产量汇报/Sc_Add_ProductReportStepBillList.html | 115 +++++++++++++++++++++++++++++++++-----
3 files changed, 111 insertions(+), 29 deletions(-)
diff --git a/WebTM/views/index.html b/WebTM/views/index.html
index c089d45..dcbfc6a 100644
--- a/WebTM/views/index.html
+++ b/WebTM/views/index.html
@@ -348,6 +348,12 @@
<dd><a lay-href="鐢熶骇绠$悊/缁勮鍗�/Sc_GroupOrderBillList.html">缁勮杩芥函鍗曠淮鎶�</a></dd>
</dl>
</dd>
+ <dd>
+ <a>缁勬墭鍗�</a>
+ <dl class="layui-nav-child">
+ <dd><a lay-href="鐢熶骇绠$悊/鐢熶骇鍖呰鍗�/Sc_PackUnionBill.html">缁勬墭鍗曠淮鎶�</a></dd>
+ </dl>
+ </dd>
</dl>
</li>
<!-- 杞﹂棿绠$悊 -->
diff --git "a/WebTM/views/\347\224\237\344\272\247\347\256\241\347\220\206/\346\212\245\345\267\245\345\217\260\345\267\245\345\272\217/\344\272\247\351\207\217\346\261\207\346\212\245/Sc_Add_ProductReportStepBillList.html" "b/WebTM/views/\347\224\237\344\272\247\347\256\241\347\220\206/\346\212\245\345\267\245\345\217\260\345\267\245\345\272\217/\344\272\247\351\207\217\346\261\207\346\212\245/Sc_Add_ProductReportStepBillList.html"
index 85547e6..430b58f 100644
--- "a/WebTM/views/\347\224\237\344\272\247\347\256\241\347\220\206/\346\212\245\345\267\245\345\217\260\345\267\245\345\272\217/\344\272\247\351\207\217\346\261\207\346\212\245/Sc_Add_ProductReportStepBillList.html"
+++ "b/WebTM/views/\347\224\237\344\272\247\347\256\241\347\220\206/\346\212\245\345\267\245\345\217\260\345\267\245\345\272\217/\344\272\247\351\207\217\346\261\207\346\212\245/Sc_Add_ProductReportStepBillList.html"
@@ -175,12 +175,6 @@
</div>
<div class="layui-form-item">
<div class="layui-inline">
- <label class="layui-form-label">璁″垝鏁伴噺:</label>
- <div class="layui-input-inline">
- <input class="layui-input" name="HPlanQty" lay-verify="HPlanQty" id="HPlanQty" autocomplete="off">
- </div>
- </div>
- <div class="layui-inline">
<label class="layui-form-label">鐢熶骇璧勬簮</label>
<div class="layui-input-inline">
<input type="text" name="HSourceName" id="HSourceName" class="layui-input" value="" style="float:left;width:150px;">
@@ -202,8 +196,6 @@
</button>
</div>
</div>
- </div>
- <div class="layui-form-item">
<div class="layui-inline">
<label class="layui-form-label">鎿嶄綔鍛�:</label>
<div class="layui-input-inline">
@@ -215,6 +207,29 @@
</button>
</div>
</div>
+ </div>
+ <div class="layui-form-item">
+ <div class="layui-inline">
+ <label class="layui-form-label">璁″垝鏁伴噺:</label>
+ <div class="layui-input-inline">
+ <input class="layui-input" name="HPlanQty" lay-verify="HPlanQty" id="HPlanQty" autocomplete="off">
+ </div>
+ </div>
+ <div class="layui-inline">
+ <label class="layui-form-label">閲囬泦鏁伴噺:</label>
+ <div class="layui-input-inline">
+ <input class="layui-input" name="GatherQty" lay-verify="GatherQty" id="GatherQty" autocomplete="off">
+ </div>
+ </div>
+ <div class="layui-inline">
+ <label class="layui-form-label">鍚堟牸鏁伴噺:</label>
+ <div class="layui-input-inline">
+ <input class="layui-input" name="HQty" lay-verify="HQty" id="HQty" autocomplete="off">
+ </div>
+ </div>
+
+ </div>
+ <div class="layui-form-item">
<div class="layui-inline">
<label class="layui-form-label">涓嶈壇鏁伴噺:</label>
<div class="layui-input-inline">
@@ -231,14 +246,6 @@
<label class="layui-form-label">鍥犳枡鎶ュ簾鏁�:</label>
<div class="layui-input-inline">
<input class="layui-input" name="HWasterQty2" lay-verify="HWasterQty2" id="HWasterQty2" autocomplete="off">
- </div>
- </div>
- </div>
- <div class="layui-form-item">
- <div class="layui-inline">
- <label class="layui-form-label">鎶ュ伐鏁伴噺:</label>
- <div class="layui-input-inline">
- <input class="layui-input" name="HQty" lay-verify="HQty" id="HQty" autocomplete="off">
</div>
</div>
</div>
@@ -996,6 +1003,78 @@
}
});
}
+
+ //#region 鐩戝惉杈撳叆妗嗘敼鍙樺��
+ //杈撳叆妗嗙殑鍊兼敼鍙樻椂瑙﹀彂
+ $("#HBadCount").on("input", function (e) {
+ //鑾峰彇input杈撳叆鐨勫��
+ var HBadCount = e.delegateTarget.value == '' ? '0' : e.delegateTarget.value;
+ //鑾峰彇閲囬泦鏁伴噺
+ var GatherQty = $("#GatherQty").val() == '' ? '0' : $("#GatherQty").val();
+ //鑾峰彇鍚堟牸鏁伴噺
+ var Hqy = $("#HQty").val() == '' ? '0' : $("#HQty").val();//parseFloat($("#HQty").val())
+ //鍥犲伐鎶ュ簾鏁�
+ var HWasterQty = $("#HWasterQty").val() == '' ? '0' : $("#HWasterQty").val();
+ //鍥犳枡鎶ュ簾鏁�
+ var HWasterQty2 = $("#HWasterQty2").val() == '' ? '0' : $("#HWasterQty2").val();
+ //鍚堟牸=閲囬泦-(涓嶈壇+鎶ュ簾)GatherQty
+ Hqy = parseFloat(GatherQty) - (parseFloat(HBadCount) + parseFloat(HWasterQty) + parseFloat(HWasterQty2));
+ if (Hqy < 0)
+ {
+ layer.msg("鍚堟牸鏁伴噺涓嶈兘涓鸿礋鏁�!");
+ HBadCount = 0;
+ Hqy = parseFloat(GatherQty) - (parseFloat(HBadCount) + parseFloat(HWasterQty) + parseFloat(HWasterQty2));
+ $("#HBadCount").val(HBadCount);
+ $("#HBadCount").focus();
+ }
+ $("#HQty").val(Hqy);
+ });
+ $("#HWasterQty").on("input", function (e) {
+ //鑾峰彇input杈撳叆鐨勫��
+ var HWasterQty = e.delegateTarget.value == '' ? '0' : e.delegateTarget.value;
+ //鑾峰彇閲囬泦鏁伴噺
+ var GatherQty = $("#GatherQty").val() == '' ? '0' : $("#GatherQty").val();
+ //鑾峰彇鍚堟牸鏁伴噺
+ var Hqy = $("#HQty").val() == '' ? '0' : $("#HQty").val();//parseFloat($("#HQty").val())
+ //涓嶈壇鏁伴噺
+ var HBadCount = $("#HBadCount").val() == '' ? '0' : $("#HBadCount").val();
+ //鍥犳枡鎶ュ簾鏁�
+ var HWasterQty2 = $("#HWasterQty2").val() == '' ? '0' : $("#HWasterQty2").val();
+ //鍚堟牸=閲囬泦-(涓嶈壇+鎶ュ簾)GatherQty
+ Hqy = parseFloat(GatherQty) - (parseFloat(HBadCount) + parseFloat(HWasterQty) + parseFloat(HWasterQty2));
+ if (Hqy < 0) {
+ layer.msg("鍚堟牸鏁伴噺涓嶈兘涓鸿礋鏁�!");
+ HWasterQty = 0;
+ Hqy = parseFloat(GatherQty) - (parseFloat(HBadCount) + parseFloat(HWasterQty) + parseFloat(HWasterQty2));
+ $("#HWasterQty").val(HWasterQty);
+ $("#HWasterQty").focus();
+ }
+ $("#HQty").val(Hqy);
+ });
+ $("#HWasterQty2").on("input", function (e) {
+ //鑾峰彇input杈撳叆鐨勫��
+ var HWasterQty2 = e.delegateTarget.value == '' ? '0' : e.delegateTarget.value;
+ //鑾峰彇閲囬泦鏁伴噺
+ var GatherQty = $("#GatherQty").val() == '' ? '0' : $("#GatherQty").val();
+ //鑾峰彇鍚堟牸鏁伴噺
+ var Hqy = $("#HQty").val() == '' ? '0' : $("#HQty").val();//parseFloat($("#HQty").val())
+ //涓嶈壇鏁伴噺
+ var HBadCount = $("#HBadCount").val() == '' ? '0' : $("#HBadCount").val();
+ //鍥犲伐鎶ュ簾鏁�
+ var HWasterQty = $("#HWasterQty").val() == '' ? '0' : $("#HWasterQty").val();
+ //鍚堟牸=閲囬泦-(涓嶈壇+鎶ュ簾)GatherQty
+ Hqy = parseFloat(GatherQty) - (parseFloat(HBadCount) + parseFloat(HWasterQty) + parseFloat(HWasterQty2));
+ if (Hqy < 0) {
+ layer.msg("鍚堟牸鏁伴噺涓嶈兘涓鸿礋鏁�!");
+ HWasterQty2 = 0;
+ Hqy = parseFloat(GatherQty) - (parseFloat(HBadCount) + parseFloat(HWasterQty) + parseFloat(HWasterQty2));
+ $("#HWasterQty2").val(HWasterQty2);
+ $("#HWasterQty2").focus();
+ }
+ $("#HQty").val(Hqy);
+ });
+ //#endregion
+
//浠ヤ笂涓簂ayui妯″潡
});
@@ -1030,6 +1109,10 @@
layer.msg("鎿嶄綔鍛樹笉鑳戒负绌猴紒", { icon: 5, btn: ['纭'], time: 2000, offset: 't', skin: 'layui-layer-lan', title: "娓╅Θ鎻愮ず" });
return Result = false;
}
+ if ($("#GatherQty").val() == '' || $("#GatherQty").val() == null) {
+ layer.msg("閲囬泦鏁伴噺涓嶈兘涓虹┖锛�", { icon: 5, btn: ['纭'], time: 2000, offset: 't', skin: 'layui-layer-lan', title: "娓╅Θ鎻愮ず" });
+ return Result = false;
+ }
if ($("#HQty").val() == '' || $("#HQty").val() == null) {
layer.msg("鎶ュ伐鏁伴噺涓嶈兘涓虹┖锛�", { icon: 5, btn: ['纭'], time: 2000, offset: 't', skin: 'layui-layer-lan', title: "娓╅Θ鎻愮ず" });
return Result = false;
diff --git "a/WebTM/views/\347\224\237\344\272\247\347\256\241\347\220\206/\347\224\237\344\272\247\345\214\205\350\243\205\345\215\225/Sc_PackUnionBill.html" "b/WebTM/views/\347\224\237\344\272\247\347\256\241\347\220\206/\347\224\237\344\272\247\345\214\205\350\243\205\345\215\225/Sc_PackUnionBill.html"
index 6e81920..f913cc6 100644
--- "a/WebTM/views/\347\224\237\344\272\247\347\256\241\347\220\206/\347\224\237\344\272\247\345\214\205\350\243\205\345\215\225/Sc_PackUnionBill.html"
+++ "b/WebTM/views/\347\224\237\344\272\247\347\256\241\347\220\206/\347\224\237\344\272\247\345\214\205\350\243\205\345\215\225/Sc_PackUnionBill.html"
@@ -125,7 +125,7 @@
, laydate = layui.laydate
, util = layui.util
//鏌ヨ鏉′欢
- var sWhere = " where 1 = 1 ";
+ var sWhere = "";
var option = [];
var Name = "Sc_PackUnionBillMain";
@@ -133,7 +133,7 @@
//鍒濆鍖栬〃鏍�
set_InitGrid();
//鍔犺浇鏁版嵁鍒扮綉鏍�
- get_Display(sWhere);
+ get_FastQuery(table, option);
//#endregion
//#region 鐐瑰嚮浜嬩欢鍖呮嫭on form浜嬩欢绛�
//澶村伐鍏锋爮浜嬩欢
@@ -243,14 +243,7 @@
//鍔犺浇缃戞牸
function get_Display(sWhere) {
var wait = layer.load();//閬僵
- var HBeginDate = $("#HBeginDate").val();//寮�濮嬫棩鏈�
- var HEndDate = $("#HEndDate").val();//缁撴潫鏃ユ湡
- if (HBeginDate) {
- sWhere += " and CONVERT(varchar(100),鏃ユ湡, 23) >= '" + HBeginDate + "'";
- }
- if (HEndDate) {
- sWhere += " and CONVERT(varchar(100),鏃ユ湡, 23) <= '" + HEndDate + "'";
- }
+
$.ajax({
url: GetWEBURL() + '/Sc_PackUnionBill/Get_PackUnionBillList',
type: "GET",
@@ -510,7 +503,7 @@
var index = layer.load(0);
get_Display(sWhere);
//璋冪敤鎺ュ彛鍚庢竻绌簊Where缂撳瓨
- sWhere = " where 1 = 1 ";
+ sWhere = " ";
}
//閲嶇疆杩囨护鏉′欢
function set_ClearQuery() {
@@ -522,8 +515,8 @@
$("#HMaterName").val("");
$("#HMaterModel").val("");
$("#HMakerMan").val("");
- sWhere = " where 1 = 1 ";
- get_Display(sWhere);
+ sWhere = " ";
+ get_FastQuery(table, option);
}
//鍒锋柊
function set_Refresh() {
--
Gitblit v1.9.1