From b742f00aac8e1e1bb628232383c35e67f4a41e4e Mon Sep 17 00:00:00 2001
From: cwjbxqmz <1134865194@qq.com>
Date: 星期五, 26 一月 2024 15:21:28 +0800
Subject: [PATCH] 1
---
WebTM/views/模治具管理/模治具仓库管理/Sc_Add_MouldProdOutBillList.html | 68 +++++++++++++++++++++++++---------
1 files changed, 50 insertions(+), 18 deletions(-)
diff --git "a/WebTM/views/\346\250\241\346\262\273\345\205\267\347\256\241\347\220\206/\346\250\241\346\262\273\345\205\267\344\273\223\345\272\223\347\256\241\347\220\206/Sc_Add_MouldProdOutBillList.html" "b/WebTM/views/\346\250\241\346\262\273\345\205\267\347\256\241\347\220\206/\346\250\241\346\262\273\345\205\267\344\273\223\345\272\223\347\256\241\347\220\206/Sc_Add_MouldProdOutBillList.html"
index 5290bf5..0010e44 100644
--- "a/WebTM/views/\346\250\241\346\262\273\345\205\267\347\256\241\347\220\206/\346\250\241\346\262\273\345\205\267\344\273\223\345\272\223\347\256\241\347\220\206/Sc_Add_MouldProdOutBillList.html"
+++ "b/WebTM/views/\346\250\241\346\262\273\345\205\267\347\256\241\347\220\206/\346\250\241\346\262\273\345\205\267\344\273\223\345\272\223\347\256\241\347\220\206/Sc_Add_MouldProdOutBillList.html"
@@ -30,12 +30,11 @@
<button type="button" class="layui-btn layui-btn-normal layui-btn-radius" lay-submit="" lay-filter="print">鎵撳嵃</button>
</div>
-
</div>
<div class="layui-card-body">
<div class="layui-tab layui-tab-brief" lay-filter="docDemoTabBrief">
<!--<ul class="layui-tab-title">
- <li class="layui-this">鍩烘湰淇℃伅</li>-->
+ <li class="layui-this">鍩烘湰淇℃伅</li>-->
<!--<li>鍏朵粬淇℃伅</li>-->
<!--</ul>-->
<h1 style="text-align:center;"><b>鍣ㄥ叿棰嗙敤鍗�</b></h1>
@@ -140,8 +139,21 @@
</div>
</div>
</div>
+ <div class="layui-tab layui-tab-card" lay-filter="TabTest">
+ <ul class="layui-tab-title">
+ <li class="layui-this">鏄庣粏淇℃伅</li>
+ <li>姹囨�讳俊鎭�</li>
+ </ul>
+ <div class="layui-tab-content">
+ <div class="layui-tab-item layui-show">
+ <table class="layui-hide" id="mainTable" lay-filter="mainTable"></table>
+ </div>
+ <div class="layui-tab-item">
+ <table class="layui-hide" id="mainTable1" lay-filter="mainTable1"></table>
+ </div>
+ </div>
+ </div>
- <table class="layui-hide" id="mainTable" lay-filter="mainTable"></table>
<script type="text/html" id="toolbarDemo">
<div class="layui-btn-container">
@@ -222,6 +234,9 @@
, { field: 'HMaterName', title: '鍣ㄥ叿鍚嶇О', edit: 'text', width: 100 }
, { field: 'HMaterSpec', title: '瑙勬牸鍨嬪彿', edit: 'text', width: 100 }
, { field: 'HBatchNo', title: '鎵规', edit: 'text', width: 100 }
+ , { field: 'HUnitID', title: 'HUnitID', edit: 'text', width: 100, hide: true }
+ , { field: 'HUnitCode', title: '璁¢噺鍗曚綅浠g爜', edit: 'text', event: 'HUnitCode', width: 100 }
+ , { field: 'HUnitName', title: '璁¢噺鍗曚綅', edit: 'text', width: 100 }
, { field: 'HDesignLife', title: '璁捐瀵垮懡', edit: 'text', width: 100 }
, { field: 'HLeaveLife', title: '鍓╀綑瀵垮懡', edit: 'text', width: 100 }
, { field: 'HUseLife', title: '绱Н浣跨敤瀵垮懡', edit: 'text', width: 100 }
@@ -241,6 +256,28 @@
]]
, limit: 500 //姣忛〉榛樿鏄剧ず鐨勬暟閲�
};
+ var option1 = {
+ id:'#mainTable1'
+ ,elem: '#mainTable1'
+ , height: 500
+ , page: true //寮�鍚垎椤�
+ , cols: [[ //琛ㄥご
+ { type: 'checkbox', fixed: 'left' }
+ , { templet: '#xuhao', title: '搴忓彿', sort: true, fixed: 'left', event: "qwe", width: 100 }
+ , { field: '鐗╂枡浠g爜', title: '鐗╂枡浠g爜', edit: 'text', event: 'HMaterCode', width: 100 }
+ , { field: '鐗╂枡鍚嶇О', title: '鐗╂枡鍚嶇О', edit: 'text', width: 100 }
+ , { field: '瑙勬牸鍨嬪彿', title: '瑙勬牸鍨嬪彿', edit: 'text', width: 100 }
+ , { field: '鍗曟嵁鍙�', title: '鍗曟嵁鍙�', edit: 'text', width: 100 }
+ , { field: '鎵规', title: '鎵规', edit: 'text', width: 100 }
+ , { field: '瀹炲彂鏁伴噺', title: '瀹炲彂鏁伴噺', edit: 'text', width: 100 }
+ , { field: 'HWHSonID', title: 'HWHSonID', edit: 'text', width: 100, hide: true }
+ , { field: '鍙戞枡浠撳簱浠g爜', title: '鍙戞枡浠撳簱浠g爜', edit: 'text', event: 'HWHCode', width: 120 }
+ , { field: '鍙戞枡浠撳簱', title: '鍙戞枡浠撳簱', edit: 'text', width: 120 }
+ , { field: '琛ㄤ綋澶囨敞', title: '澶囨敞', edit: 'text', width: 100 }
+ ]]
+ , limit: 500 //姣忛〉榛樿鏄剧ず鐨勬暟閲�
+ };
+
//鍒ゆ柇鏄惁鏂板
if (OperationType == 1) {
//鍒濆鍔犺浇琛ㄦ牸{ "ID": 0, "HWasterReasonName": " ","HBadReasonID":0,"HEmpName": " ", "HSQProcName": " ","HProcID":0, "HZRProcName": " ", "HMRBChecker": " ", "HRemark": " ", "HPSProcName": " ", "HCloseMan": " " }
@@ -255,11 +292,11 @@
type: "GET",
data: { "sqlWhere": "and hmainid=" + linterid },
success: function (result) {
- //console.log(result);
- //console.log('gouba' + result);
if (result.count == 1) {
- option.data = result.data;
+ option.data = result.list[0];
table.render(option);
+ option1.data = result.list[1];
+ table.render(option1);
} else {
layer.alert(result.code + result.Message, { icon: 5 });
@@ -280,7 +317,7 @@
var checkStatus = table.checkStatus('mainTable')
, data = checkStatus.data;;
var AddRow = table.cache['mainTable'];
- var NewRow = { "HMaterID": 0, "HMaterCode": "", "HMaterName": "", "HMaterSpec": "", "HBatchNo": "", "HDesignLife": 0, "HLeaveLife": 0, "HUseLife": 0, "HQtyMust": 0, "HQty": 0, "HPrice": 0, "HMoney": 0, "HWHID": 0, "HWHCode": "", "HWHName": "", "HSPID": 0, "HSPCode": "", "HSPName": "", "HRemark": "" };
+ var NewRow = { "HMaterID": 0, "HMaterCode": "", "HMaterName": "", "HMaterSpec": "", "HBatchNo": "", "HUnitID": 0, "HUnitCode": "", "HUnitName": "", "HDesignLife": 0, "HLeaveLife": 0, "HUseLife": 0, "HQtyMust": 0, "HQty": 0, "HPrice": 0, "HMoney": 0, "HWHID": 0, "HWHCode": "", "HWHName": "", "HSPID": 0, "HSPCode": "", "HSPName": "", "HRemark": "" };
switch (obj.event) {
case 'btn-AddLine':
//table.cache["mainTable"].push(AddRow[rows]);
@@ -393,7 +430,7 @@
//鎸夐挳銆愭寜閽竴銆戠殑鍥炶皟
var iframeWindow = window['layui-layer-iframe' + index] //鑾峰彇寮规椤甸潰
- var checkStatus = iframeWindow.layui.table.checkStatus('ck-table');//鑾峰彇table鐨別lem:"#test"
+ var checkStatus = iframeWindow.layui.table.checkStatus('mainTable');//鑾峰彇table鐨別lem:"#test"
if (checkStatus.data.length === 0) {
return layer.msg('璇烽�夋嫨鏁版嵁');
}
@@ -617,7 +654,7 @@
//鎸夐挳銆愭寜閽竴銆戠殑鍥炶皟
var iframeWindow = window['layui-layer-iframe' + index] //鑾峰彇寮规椤甸潰
- var checkStatus = iframeWindow.layui.table.checkStatus('ck-table');//鑾峰彇table鐨別lem:"#test"
+ var checkStatus = iframeWindow.layui.table.checkStatus('mainTable');//鑾峰彇table鐨別lem:"#test"
if (checkStatus.data.length === 0) {
return layer.msg('璇烽�夋嫨鏁版嵁');
}
@@ -970,19 +1007,14 @@
return false;
}
if (!typeof (sSubStr) == "undefined") {
- //for (var i = 0; i <= sSubStr.length - 1; i++) { //鍒ゆ柇鎵爜鏁伴噺涓嶈兘澶т簬搴旀敹鏁伴噺
- // if (parseFloat(sSubStr[i].HQtyMust) > 0) {
- // if (parseFloat(sSubStr[i].HQty) > parseFloat(sSubStr[i].HQtyMust))
- // {
- // layer.msg("鏁伴噺涓嶈兘澶т簬搴旀敹鏁伴噺", { icon: 5, btn: ['纭畾'], time: 100000, offset: 't' });
- // return false;
- // }
- // }
- //}
for (var i = 0; i <= sSubStr.length - 1; i++) { //鍒ゆ柇鎵爜鏁伴噺涓嶈兘涓�0
if (parseFloat(sSubStr[i].HQty) > 0) {
s = 1;
}
+ if (sSubStr[i].HUnitID == "") {
+ layer.msg("鏄庣粏璁板綍绗�" + (i + 1) + "琛�,璁¢噺鍗曚綅涓虹┖!", { icon: 5, btn: ['纭'], time: 2000, offset: 't', skin: 'layui-layer-lan', title: "娓╅Θ鎻愮ず" });
+ return Result = false;
+ }
}
if (s == 0) {
layer.msg("浜у搧鍏ュ簱璁板綍鏈壂鐮�", { icon: 5, btn: ['纭'], time: 100000, offset: 't', skin: 'layui-layer-lan', title: "娓╅Θ鎻愮ず" });
--
Gitblit v1.9.1