From 43c1b4226774fde3a7dd0aff6663931363639766 Mon Sep 17 00:00:00 2001
From: yangle <admin@YINMOU>
Date: 星期三, 03 七月 2024 11:19:22 +0800
Subject: [PATCH] 检验单优化
---
WebTM/views/质量管理/巡检记录单/QC_Add_Edit_PatrolProcCheckOtherill.html | 115 ++++++++++++++++++++++++++++++++++++++++++++++++++-------
1 files changed, 101 insertions(+), 14 deletions(-)
diff --git "a/WebTM/views/\350\264\250\351\207\217\347\256\241\347\220\206/\345\267\241\346\243\200\350\256\260\345\275\225\345\215\225/QC_Add_Edit_PatrolProcCheckOtherill.html" "b/WebTM/views/\350\264\250\351\207\217\347\256\241\347\220\206/\345\267\241\346\243\200\350\256\260\345\275\225\345\215\225/QC_Add_Edit_PatrolProcCheckOtherill.html"
index 0931266..63f963c 100644
--- "a/WebTM/views/\350\264\250\351\207\217\347\256\241\347\220\206/\345\267\241\346\243\200\350\256\260\345\275\225\345\215\225/QC_Add_Edit_PatrolProcCheckOtherill.html"
+++ "b/WebTM/views/\350\264\250\351\207\217\347\256\241\347\220\206/\345\267\241\346\243\200\350\256\260\345\275\225\345\215\225/QC_Add_Edit_PatrolProcCheckOtherill.html"
@@ -216,9 +216,13 @@
</div>
</div>
<div class="layui-inline" id="hidediv1">
- <label class="layui-form-label" style="width: 85px;">宸ュ簭</label>
- <div class="layui-input-block" style="margin-left: 120px;">
- <input type="text" class="layui-input" name="HProcName" id="HProcName" style="background-color:#efefef4d;" readonly value="1">
+ <label class="layui-form-label" style="width: 85px;padding: 9px 18px;">宸ュ簭</label>
+ <div class="layui-input-block" style="margin-left: 77px;">
+ <input type="text" class="layui-input" name="HProcName" id="HProcName" style="background-color:#efefef4d;width: 60%;display: inline-block;" readonly>
+ <button class="layui-btn layuiadmin-btn-order" type="button" lay-submit="" lay-filter="btnHProc" id="btnHProc" style="padding: 0 10px;float: right;margin-right: 3px;">
+ <i class="layui-icon layui-icon-search layuiadmin-button-btn"></i>
+ </button>
+ <input type="hidden" name="HProcID" id="HProcID" value="0">
</div>
</div>
</div>
@@ -358,13 +362,13 @@
<div class="layui-inline">
<label class="layui-form-label" style="width: 85px;">鏍锋湰閲�</label>
<div class="layui-input-block" style="margin-left: 120px;">
- <input type="text" class="layui-input" name="HSampleQty" id="HSampleQty" style="background-color:#efefef4d;" readonly>
+ <input type="text" class="layui-input" name="HSampleQty" id="HSampleQty" value="0" style="background-color:#efefef4d;" readonly>
</div>
</div>
<div class="layui-inline">
<label class="layui-form-label" style="width: 85px;">鏍锋湰鐮村潖鏁�</label>
<div class="layui-input-block" style="margin-left: 120px;">
- <input type="text" class="layui-input" name="HSampleDamageQty" id="HSampleDamageQty" style="">
+ <input type="text" class="layui-input" name="HSampleDamageQty" id="HSampleDamageQty" value="0" style="">
</div>
</div>
</div>
@@ -841,6 +845,7 @@
//鏍规嵁婧愬崟id鑾峰彇婧愬崟淇℃伅(宸ュ簭娴佽浆鍗�)
function LoadingInformation_ProcExchange() {
+ $('#btnSearchSource').removeClass("layui-btn-disabled").attr("disabled", false);//鐢熶骇璧勬簮鎸夐挳鍚敤
var wait = layer.load();
$.ajax({
url: GetWEBURL() + '/QC_PatrolProcCheckOtherBill/get_ProcessExchangeBill',
@@ -1003,7 +1008,7 @@
"HQCCheckItemID": "", "妫�楠岄」鐩�": "", "HInspectInstruMentID": "0", "妫�楠屼华鍣�": "", "HQCStd": "", "HUnit": "", "HQCNote": "", "HAnalysisMethod": "", "HResult": "",
"HMax": "", "HMin": "", "HAvg": "", "HRemark": "", "HKeyInspect": false, "HStatus": 0, "HSampleSchemeID": 0, "HUnitID": 0,
"HInspectVal": '', "HTargetVal": '', "HUpLimit": '', "HDownLimit": '', "HUpOffSet": '', "HDownOffSet": '', "HSampleDamageQty": '0',
- "HSampleSchemeName": "", "HSampleQty": "", "HSampleDamageQty": "0", "HAcceptQty": "0", "HInspectionLevel": "", "HRejectQty": "",
+ "HSampleSchemeName": "", "HSampleQty": "0", "HSampleDamageQty": "0", "HAcceptQty": "0", "HInspectionLevel": "", "HRejectQty": "",
"HStrictness": "", "HSampleUnRightQty": "", "HAQL": "", "HSamplingType": ""
};
@@ -1523,7 +1528,7 @@
for (var i = 0; i < data.length; i++) {
rowdata.push(
{
- "HQCCheckItemID": data[i].HQCCheckItemID, "妫�楠岄」鐩�": data[i].妫�楠岄」鐩悕绉�, "HInspectInstruMentID": data[i].HInspectInstruMentID, "妫�楠屼华鍣�": data[i].妫�楠屼华鍣ㄥ悕绉�, "HQCStd": data[i].妫�楠屾爣鍑�,
+ "HQCCheckItemID": data[i].HQCCheckItemID, "妫�楠岄」鐩唬鐮�": data[i].妫�楠岄」鐩唬鐮�, "妫�楠岄」鐩�": data[i].妫�楠岄」鐩悕绉�, "HInspectInstruMentID": data[i].HInspectInstruMentID, "妫�楠屼华鍣�": data[i].妫�楠屼华鍣ㄥ悕绉�, "HQCStd": data[i].妫�楠屾爣鍑�,
"HUnit": data[i].妫�楠屽崟浣�, "HQCNote": data[i].妫�楠岃褰�, "HResult": data[i].缁撹 == "鍚堟牸" ? 1 : 2,
"HMax": data[i].鏈�澶у��, "HMin": data[i].鏈�灏忓��, "HAvg": data[i].骞冲潎鍊�, "HRemark": data[i].琛ㄤ綋澶囨敞,
"HAnalysisMethod": data[i].鍒嗘瀽鏂规硶 == "瀹氭�у垎鏋�" ? 1 : (data[i].鍒嗘瀽鏂规硶 == "瀹氶噺鍒嗘瀽" ? 2 : 3), "HKeyInspect": data[i].閲嶇偣妫�鏌� == "鍚�" ? false : true,
@@ -2040,6 +2045,7 @@
$("#HSourceName").val(checkStatus.data[0].鐢熶骇璧勬簮鍚嶇О);
$("#HSourceID").val(checkStatus.data[0].HItemID);
layer.close(layer.index); //瀹冭幏鍙栫殑濮嬬粓鏄渶鏂板脊鍑虹殑鏌愪釜灞傦紝鍊兼槸鐢眑ayer鍐呴儴鍔ㄦ�侀�掑璁$畻鐨�
+ get_ICMOBillStatusList();
}
, btn2: function (index, layero) {
//鎸夐挳銆愭寜閽簩銆戠殑鍥炶皟
@@ -2053,6 +2059,46 @@
}
});
});
+
+ //琛ㄥご淇℃伅宸ュ簭
+ form.on('submit(btnHProc)', function () {
+ //椤甸潰灞�-鑷畾涔�
+ layer.open({
+ type: 2,
+ skin: 'layui-layer-rim', //鍔犱笂杈规
+ title: '宸ュ簭鍒楄〃',
+ closeBtn: 1,
+ shift: 2,
+ area: ['90%', '90%'],
+ maxmin: true,
+ content: ['../../鍩虹璧勬枡/鐢熶骇鍩虹璧勬枡/Gy_Process.html', 'yes'],
+ btn: ['纭畾', '鍙栨秷']
+ , btn1: function (index, layero) {
+
+ //鎸夐挳銆愭寜閽竴銆戠殑鍥炶皟
+ var iframeWindow = window['layui-layer-iframe' + index] //鑾峰彇寮规椤甸潰
+ var checkStatus = iframeWindow.layui.table.checkStatus('mainTable');//鑾峰彇table鐨別lem:"#test"
+ if (checkStatus.data.length === 0) {
+ return layer.msg('璇烽�夋嫨鏁版嵁');
+ }
+ $("#HProcName").val(checkStatus.data[0].宸ュ簭鍚嶇О);
+ $("#HProcID").val(checkStatus.data[0].HItemID);
+ layer.close(layer.index); //瀹冭幏鍙栫殑濮嬬粓鏄渶鏂板脊鍑虹殑鏌愪釜灞傦紝鍊兼槸鐢眑ayer鍐呴儴鍔ㄦ�侀�掑璁$畻鐨�
+ get_ICMOBillStatusList();
+ }
+ , btn2: function (index, layero) {
+ //鎸夐挳銆愭寜閽簩銆戠殑鍥炶皟
+ //return false 寮�鍚浠g爜鍙姝㈢偣鍑昏鎸夐挳鍏抽棴
+ },
+ end: function () {
+
+ },
+ success: function (layero, index) {
+
+ }
+ });
+ });
+
//琛ㄥご淇℃伅鐢熶骇鐝寮圭獥
form.on('submit(btnHShifts)', function () {
@@ -2189,7 +2235,7 @@
"HQCCheckItemID": "", "妫�楠岄」鐩�": "", "HInspectInstruMentID": "0", "妫�楠屼华鍣�": "", "HQCStd": "", "HUnit": "", "HQCNote": "", "HAnalysisMethod": "", "HResult": "",
"HMax": "", "HMin": "", "HAvg": "", "HRemark": "", "HKeyInspect": false, "HStatus": 0, "HSampleSchemeID": 0, "HUnitID": 0,
"HInspectVal": '', "HTargetVal": '', "HUpLimit": '', "HDownLimit": '', "HUpOffSet": '', "HDownOffSet": '', "HSampleDamageQty": '0',
- "HSampleSchemeName": "", "HSampleQty": "", "HSampleDamageQty": "0", "HAcceptQty": "0", "HInspectionLevel": "", "HRejectQty": "",
+ "HSampleSchemeName": "", "HSampleQty": "0", "HSampleDamageQty": "0", "HAcceptQty": "0", "HInspectionLevel": "", "HRejectQty": "",
"HStrictness": "", "HSampleUnRightQty": "0", "HAQL": "", "HSamplingType": ""
}];
option = {
@@ -2203,6 +2249,7 @@
{ type: 'checkbox', totalRowText: '鍚堣琛�' }
, { type: 'numbers', title: '搴忓彿', totalRow: true }
, { field: 'HQCCheckItemID', title: 'HQCCheckItemID', hide: true }
+ , { field: '妫�楠岄」鐩唬鐮�', title: '妫�楠岄」鐩唬鐮�' }
, { field: '妫�楠岄」鐩�', title: '妫�楠岄」鐩�', edit: 'text', event: 'HQCCheckItemID' }
, { field: 'HInspectInstruMentID', title: 'HInspectInstruMentID', hide: true }
, { field: '妫�楠屼华鍣�', title: '妫�楠屼华鍣�', edit: 'text', event: 'HInspectInstruMentID' }
@@ -2212,6 +2259,9 @@
, { field: 'HQCStd', title: '妫�楠屾爣鍑�', edit: 'text' }
, { field: 'HUnit', title: '鍗曚綅', edit: 'text' }
, { field: 'HQCNote', title: '妫�楠岃褰�', edit: 'text' }
+ , { field: 'HInspectVal', title: '妫�楠屽��' }
+ , { field: 'HUpLimit', title: '涓婇檺鍊�' }
+ , { field: 'HDownLimit', title: '涓嬮檺鍊�' }
, { field: 'HMax', title: '鏈�澶у��', edit: 'text', totalRow: true }
, { field: 'HMin', title: '鏈�灏忓��', edit: 'text', totalRow: true }
, { field: 'HAvg', title: '骞冲潎鍊�', edit: 'text', totalRow: true }
@@ -2231,10 +2281,7 @@
, { field: 'xxx', title: '姣旇緝绗�', edit: 'text', hide: true }
, { field: 'HUnitID', title: '鍗曚綅ID', edit: 'text', hide: true }
, { field: 'HUnit', title: '鍗曚綅', edit: 'text', hide: true }
- , { field: 'HInspectVal', title: '妫�楠屽��', edit: 'text', hide: true }
, { field: 'HTargetVal', title: '鐩爣鍊�', edit: 'text', hide: true }
- , { field: 'HUpLimit', title: '涓婇檺鍊�', edit: 'text', hide: true }
- , { field: 'HDownLimit', title: '涓嬮檺鍊�', edit: 'text', hide: true }
, { field: 'HUpOffSet', title: '涓婂亸宸�', edit: 'text', hide: true }
, { field: 'HDownOffSet', title: '涓嬪亸宸�', edit: 'text', hide: true }
, { fixed: 'right', title: '鎿嶄綔', toolbar: '#barDemo', width: 85 }
@@ -2630,7 +2677,7 @@
$("#HUpOffSet").val(0);
$("#HDownOffSet").val(0);
$("#HSampleDamageQty").val("")
- $("#HSampleQty").val("")
+ $("#HSampleQty").val("0")
$("#HSampleQty2").val("")
$("#HAcceptQty").val("0")
$("#HInspectionLevel").val("")
@@ -2640,7 +2687,7 @@
$("#HSampleUnRightQty2").val("")
$("#HAQL").val("")
$("#HSamplingType").val("")
- $("#HSampleQty").val("")
+ $("#HSampleQty").val("0")
$("#HInspectResultToSee").val("")
$("#HInspectResultToSee2").val("")
$("#HSampleUnRightQty").val("")
@@ -3217,7 +3264,47 @@
$("#HInspectResultToSee2").val(HInspectResultToSee);
LastResult();
};
- //#endregion
+ //#endregion
+
+
+ //鏍规嵁鐢熶骇璧勬簮鎴栬�� 宸ュ簭 鏌ヨ鐢熶骇宸ュ崟淇℃伅
+ function get_ICMOBillStatusList() {
+ var sWhere = "";
+ var HProcID = $("#HProcID").val();
+ var HSourceID = $("#HSourceID").val();
+ var HProcExchInterID = $("#HProcExchInterID").val();
+
+ if (HProcID != "0") {
+ sWhere += " and HProcID=" + HProcID;
+ }
+ if (HSourceID != "0") {
+ sWhere += " and HSourceID=" + HSourceID
+ }
+
+ sWhere += " and HSourceInterID=" + HProcExchInterID;
+
+ $.ajax({
+ url: GetWEBURL() + "/CheckBill/GetICMOBillStatusList",
+ type: "GET",
+ async: false,
+ data: { "sWhere": sWhere, "user": sessionStorage["HUserName"] },
+ success: function (result) {
+ if (result.count == 1) {
+ $("#HProcID").val(result.data[0]["HProcID"]);
+ $("#HProcName").val(result.data[0]["宸ュ簭"]);
+ $("#HSourceID").val(result.data[0]["HSourceID"]);
+ $("#HSourceName").val(result.data[0]["鐢熶骇璧勬簮"]);
+
+ } else {
+ layer.msg(result.Message, { icon: 5, btn: ['纭'], time: 100000, offset: 't', skin: 'layui-layer-lan', title: "娓╅Θ鎻愮ず" });
+ }
+ },
+ error: function (err) {
+ layer.msg("鎺ュ彛璇锋眰澶辫触锛�" + err, { icon: 5, btn: ['纭'], time: 100000, offset: 't', skin: 'layui-layer-lan', title: "娓╅Θ鎻愮ず" });
+ }
+ })
+ }
+
//鑾峰彇涓嶅悎鏍兼暟鎬绘暟
function addUnRightQty() {
--
Gitblit v1.9.1