From ceeb1a367bee96d0ce18209fc1862f270a3dca65 Mon Sep 17 00:00:00 2001
From: YL <YL@LAPTOP-SE03PLUR>
Date: 星期三, 20 十月 2021 22:10:57 +0800
Subject: [PATCH] Merge branch 'master' of http://101.37.171.70:10101/r/MESWMS-LayUI
---
WebTM/views/基础资料/公用基础资料/Gy_Warehouse.html | 2
WebTM/views/采购管理/采购订单/Cg_POOrderBillList.html | 907 +++++++++++++++++---
WebTM/views/基础资料/公用基础资料/Gy_DepartmentList.html | 2
WebTM/views/基础资料/公用基础资料/xmlLBM_EquipTypeBill.aspx | 28
WebTM/views/基础资料/公用基础资料/Xt_ORGANIZATIONSList.html | 2
WebTM/views/基础资料/公用基础资料/Gy_EmployeeList.html | 2
WebTM/views/基础资料/公用基础资料/Gy_Material.html | 2
WebTM/views/基础资料/采购基础资料/Gy_Supplier.html | 2
WebTM/views/test/testRenderAutomationList.html | 93 ++
/dev/null | 780 ------------------
WebTM/views/基础资料/销售基础资料/Gy_Customer.html | 2
WebTM/views/基础资料/公用基础资料/Gy_EquipTypeEdit.html | 211 ++++
WebTM/views/基础资料/公用基础资料/Gy_EquipType.html | 422 +++++++++
WebTM/views/基础资料/公用基础资料/Gy_Unit.html | 2
WebTM/layuiadmin/Scripts/webConfig.js | 2
WebTM/views/基础资料/公用基础资料/xmlLBM_EquipTypeBill.aspx.designer.cs | 26
WebTM/views/index.html | 2
WebTM/views/基础资料/公用基础资料/xmlLBM_EquipTypeBill.aspx.cs | 17
WebTM/views/基础资料/公用基础资料/HBarPlanPrint.html | 3
WebTM/WebTM.csproj | 14
WebTM/layuiadmin/PubCustom.js | 41
21 files changed, 1,621 insertions(+), 941 deletions(-)
diff --git a/WebTM/WebTM.csproj b/WebTM/WebTM.csproj
index 804c8c4..9d856c9 100644
--- a/WebTM/WebTM.csproj
+++ b/WebTM/WebTM.csproj
@@ -113,10 +113,13 @@
<Content Include="views\PublicPage\Organizations.html" />
<Content Include="views\PublicPage\PeopleInformation.html" />
<Content Include="views\ReportHtml.html" />
+ <Content Include="views\test\testRenderAutomationList.html" />
<Content Include="views\鍩虹璧勬枡\鍏敤鍩虹璧勬枡\Add_Edit_Gy_Warehouse.html" />
<Content Include="views\鍩虹璧勬枡\鍏敤鍩虹璧勬枡\Add_Edit_Xt_ORGANIZATIONSList.html" />
<Content Include="views\鍩虹璧勬枡\鍏敤鍩虹璧勬枡\Add_Edit_Gy_Department.html" />
<Content Include="views\鍩虹璧勬枡\鍏敤鍩虹璧勬枡\Gy_Employee_Add_Edit_.html" />
+ <Content Include="views\鍩虹璧勬枡\鍏敤鍩虹璧勬枡\Gy_EquipType.html" />
+ <Content Include="views\鍩虹璧勬枡\鍏敤鍩虹璧勬枡\Gy_EquipTypeEdit.html" />
<Content Include="views\鍩虹璧勬枡\鍏敤鍩虹璧勬枡\Gy_WorkCenter_Add_Edit.html" />
<Content Include="views\鍩虹璧勬枡\鍏敤鍩虹璧勬枡\Add_Edit_Gy_MouldType.html" />
<Content Include="views\鍩虹璧勬枡\鍏敤鍩虹璧勬枡\grf\b.grf" />
@@ -534,6 +537,7 @@
<Content Include="views\鍩虹璧勬枡\鍏敤鍩虹璧勬枡\Gy_Currency.html" />
<Content Include="views\鍩虹璧勬枡\鍏敤鍩虹璧勬枡\xmlLBM_EquipMaintainBill.aspx" />
<Content Include="views\鍩虹璧勬枡\鍏敤鍩虹璧勬枡\xmlLBM_EquipMaintainPlanBill.aspx" />
+ <Content Include="views\鍩虹璧勬枡\鍏敤鍩虹璧勬枡\xmlLBM_EquipTypeBill.aspx" />
<Content Include="views\鍩虹璧勬枡\鍏敤鍩虹璧勬枡\xmlLBM_Gy_Material.aspx" />
<Content Include="views\鍩虹璧勬枡\鍏敤鍩虹璧勬枡\Gy_DepartmentList.html" />
<Content Include="views\鍩虹璧勬枡\鍏敤鍩虹璧勬枡\xmlLBM_MouldDotCheckBill.aspx" />
@@ -746,7 +750,7 @@
<Content Include="views\杞﹂棿绠$悊\宸ュ簭杩涚珯鎺ユ敹鍗昞MES_StationInBill_PDA.html" />
<Content Include="views\杞﹂棿绠$悊\宸ュ簭杩涚珯鎺ユ敹鍗昞Sc_StationInBill_Mul_PDA.html" />
<Content Include="views\杞﹂棿绠$悊\宸ュ簭杩涚珯鎺ユ敹鍗昞Sc_StationInBill_Mul.html" />
- <Content Include="views\閲囪喘绠$悊\閲囪喘璁㈠崟\Cg_POOrderBillList1111.html" />
+ <Content Include="views\閲囪喘绠$悊\閲囪喘璁㈠崟\Cg_POOrderBillList.html" />
<Content Include="views\楠屾敹鍏ュ簱\浜у搧鍏ュ簱\Kf_ProductInBillList.html" />
<Content Include="views\楠屾敹鍏ュ簱\鍏朵粬鍏ュ簱\Kf_OtherInBillList.html" />
<Content Include="views\妯℃不鍏风鐞哱妯℃不鍏风鐞哱Kf_ProductInBillList.html" />
@@ -803,7 +807,6 @@
<Content Include="views\閲囪喘绠$悊\濮斿璁㈠崟\WW_EntrustOrderBillList.html" />
<Content Include="views\閲囪喘绠$悊\鏀舵枡閫氱煡鍗昞Cg_POInStockBillList.html" />
<Content Include="views\閲囪喘绠$悊\閫�鏂欓�氱煡鍗昞Cg_POInStockBackBillList.html" />
- <Content Include="views\閲囪喘绠$悊\閲囪喘璁㈠崟\Cg_POOrderBillList.html" />
<Content Include="views\閿�鍞鐞哱閫�璐ч�氱煡鍗昞Xs_SeOutStockBackBillList.html" />
<Content Include="views\閿�鍞鐞哱鍙戣揣閫氱煡鍗昞Xs_SeOutStockBillList.html" />
<Content Include="views\閿�鍞鐞哱閿�鍞鍗昞Xs_SeOrderBillList.html" />
@@ -863,6 +866,13 @@
<Compile Include="views\鍩虹璧勬枡\鍏敤鍩虹璧勬枡\xmlLBM_EquipMaintainPlanBill.aspx.designer.cs">
<DependentUpon>xmlLBM_EquipMaintainPlanBill.aspx</DependentUpon>
</Compile>
+ <Compile Include="views\鍩虹璧勬枡\鍏敤鍩虹璧勬枡\xmlLBM_EquipTypeBill.aspx.cs">
+ <DependentUpon>xmlLBM_EquipTypeBill.aspx</DependentUpon>
+ <SubType>ASPXCodeBehind</SubType>
+ </Compile>
+ <Compile Include="views\鍩虹璧勬枡\鍏敤鍩虹璧勬枡\xmlLBM_EquipTypeBill.aspx.designer.cs">
+ <DependentUpon>xmlLBM_EquipTypeBill.aspx</DependentUpon>
+ </Compile>
<Compile Include="views\鍩虹璧勬枡\鍏敤鍩虹璧勬枡\xmlLBM_Gy_Material.aspx.cs">
<DependentUpon>xmlLBM_Gy_Material.aspx</DependentUpon>
<SubType>ASPXCodeBehind</SubType>
diff --git a/WebTM/layuiadmin/PubCustom.js b/WebTM/layuiadmin/PubCustom.js
index ec9209f..4b6ad42 100644
--- a/WebTM/layuiadmin/PubCustom.js
+++ b/WebTM/layuiadmin/PubCustom.js
@@ -240,4 +240,43 @@
//#region 鎶樺彔娉ㄩ噴
-//#endregion
\ No newline at end of file
+//#endregion
+
+
+/**
+ *閫掑叆鎺ュ彛result杩斿洖list浣滀负option鐨刢ols
+ *by zgq
+ *
+ */
+function Pub_backTableHead(result) {
+ var resultTableHead = [];
+ var cols_arr = [];
+ for (var key in result.list) {
+ resultTableHead.push({ "name": result.list[key].ColmName, "Type": result.list[key].ColmType });
+ }
+ //濉厖琛ㄦ牸澶存暟缁�
+ var data = resultTableHead;
+ cols_arr[0] = [];
+ cols_arr[0][0] = { checkbox: true, fixed: true, totalRowText: '鍚堣' };
+ cols_arr[0][1] = { type: 'numbers', title: '搴忓彿' };
+ for (var i = 0; i < data.length; i++) {
+ if (data[i].name.indexOf("H") ? 0 : -1 ) {
+ cols_arr[0][i + 2] = { field: data[i].name, title: data[i].name, align: 'center', hide: true };
+ }
+ else {
+ switch (data[i].Type) {
+ //int
+ case 'Int32':
+ cols_arr[0][i + 2] = { field: data[i].name, title: data[i].name, align: 'center', totalRow: true, sort: true };
+ break;
+ //Decimal
+ case 'Decimal':
+ cols_arr[0][i + 2] = { field: data[i].name, title: data[i].name, align: 'center', totalRow: true, sort: true };
+ break;
+ default:
+ cols_arr[0][i + 2] = { field: data[i].name, title: data[i].name, align: 'center', sort: true };
+ }
+ }
+ }
+ return cols_arr
+}
\ No newline at end of file
diff --git a/WebTM/layuiadmin/Scripts/webConfig.js b/WebTM/layuiadmin/Scripts/webConfig.js
index 8c20031..44db418 100644
--- a/WebTM/layuiadmin/Scripts/webConfig.js
+++ b/WebTM/layuiadmin/Scripts/webConfig.js
@@ -12,7 +12,7 @@
//var WEBURL = "http://183.129.128.86:9090/API/"; //鍑礉濂堢壒瀹㈡埛鏈嶅姟鍣ㄥ缃�
//var WEBURL = "http://192.168.1.253:8080/API/"; //鍑礉濂堢壒瀹㈡埛鏈嶅姟鍣ㄥ唴缃�
//var WEBURL = "http://220.189.218.154:8092/API/"; //涓镐簳鍥涚淮灏旀湇鍔″櫒
- //var WEBURL = "http://localhost/API/";
+ var WEBURL = "http://localhost/API/";
return WEBURL
}
diff --git a/WebTM/views/index.html b/WebTM/views/index.html
index 53e3572..1650502 100644
--- a/WebTM/views/index.html
+++ b/WebTM/views/index.html
@@ -545,7 +545,7 @@
<dd>
<a>鍩虹寤烘ā</a>
<dl class="layui-nav-child">
- <dd><a lay-href="">璁惧鍒嗙被鍒楄〃n</a></dd>
+ <dd><a lay-href="鍩虹璧勬枡/鍏敤鍩虹璧勬枡/Gy_EquipType.html">璁惧鍒嗙被缁存姢</a></dd>
<dd><a lay-href="鍩虹璧勬枡/鍏敤鍩虹璧勬枡/Gy_EquipMent_Edit.html">璁惧妗f</a></dd>
<dd><a lay-href="鍩虹璧勬枡/鍏敤鍩虹璧勬枡/Gy_EquipMent.html">璁惧妗f缁存姢</a></dd>
</dl>
diff --git a/WebTM/views/test/testRenderAutomationList.html b/WebTM/views/test/testRenderAutomationList.html
new file mode 100644
index 0000000..99f1bed
--- /dev/null
+++ b/WebTM/views/test/testRenderAutomationList.html
@@ -0,0 +1,93 @@
+锘�<!DOCTYPE html>
+<html xmlns="http://www.w3.org/1999/xhtml">
+<head>
+ <meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
+ <title>娴嬭瘯鑷姩娓叉煋鍒楄〃</title>
+ <meta name="renderer" content="webkit">
+ <meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1">
+ <meta name="viewport" content="width=device-width, initial-scale=1, maximum-scale=1">
+ <link rel="stylesheet" href="../../../layuiadmin/layui/css/layui.css" media="all">
+ <link rel="stylesheet" href="../../../layuiadmin/style/admin.css" media="all">
+ <script src="../../../layuiadmin/layui/layui.js"></script>
+ <script src="../../../layuiadmin/Scripts/json2.js"></script>
+ <script src="../../../layuiadmin/Scripts/jquery-1.4.1.js"></script>
+ <script src="../../../layuiadmin/Scripts/webConfig.js"></script>
+ <script src="../../layuiadmin/PubCustom.js"></script>
+
+</head>
+<body>
+ <div class="layui-fluid">
+ <div class="layui-col-md12">
+ <div class="layui-card" style="padding: 1px">
+ <div class="layui-card-body" style="padding: 1px;">
+ <form class="layui-form" action="" lay-filter="component-form-group">
+ <table class="" id="mainTable" lay-filter="mainTable"></table>
+ </form>
+ </div>
+ </div>
+ </div>
+ </div>
+ <script>
+ layui.config({
+ base: '../../../layuiadmin/' //闈欐�佽祫婧愭墍鍦ㄨ矾寰�
+ }).extend({
+ index: 'lib/index', //涓诲叆鍙fā鍧�
+ }).use(['index', 'form', 'table', 'element', 'laypage', 'laydate'], function () {
+ var $ = layui.$
+ , layer = layui.layer
+ , table = layui.table
+
+ var option = [];
+ var cols_arr = [];
+
+ get_Display();
+
+ //#region 鏌ヨ
+ function get_Display() {
+ var wait = layer.load();
+ $.ajax({
+ url: GetWEBURL() + '/Sc_MESReportFrom/ReportFromBillList2',
+ type: "GET",
+ data: { "sWhere": "" },
+ success: function (result) {
+ if (result.code == 1) {
+ cols_arr = Pub_backTableHead(result);
+ set_InitGrid(cols_arr);
+ option.data = result.data;
+ table.render(option);
+ layer.close(wait);
+ } else {
+ layer.close(wait);
+ layer.alert(result.Message, { icon: 5 });
+ }
+ }, error: function () {
+ layer.close(wait);
+ layer.alert("鎺ュ彛璇锋眰澶辫触!", { icon: 5 });
+ }
+ });
+ }
+ //#endregion
+
+ //#region 鍒濆鍖栬〃鏍兼柟娉�
+ function set_InitGrid(cols_arr) {
+ option = {
+ elem: '#mainTable'
+ //, toolbar: '#toolbarDemo'
+ , height: 'full-50'
+ , page: true
+ , cellMinWidth: 90
+ , cols: cols_arr
+ , totalRow: true
+ , limit: 10
+ , limits: [10, 15, 20, 30, 40, 50, 100, 1000]
+ };
+ }
+ //#endregion
+
+
+
+ });
+ </script>
+
+</body>
+</html>
\ No newline at end of file
diff --git "a/WebTM/views/\345\237\272\347\241\200\350\265\204\346\226\231/\345\205\254\347\224\250\345\237\272\347\241\200\350\265\204\346\226\231/Gy_DepartmentList.html" "b/WebTM/views/\345\237\272\347\241\200\350\265\204\346\226\231/\345\205\254\347\224\250\345\237\272\347\241\200\350\265\204\346\226\231/Gy_DepartmentList.html"
index db1cd97..d73c0f8 100644
--- "a/WebTM/views/\345\237\272\347\241\200\350\265\204\346\226\231/\345\205\254\347\224\250\345\237\272\347\241\200\350\265\204\346\226\231/Gy_DepartmentList.html"
+++ "b/WebTM/views/\345\237\272\347\241\200\350\265\204\346\226\231/\345\205\254\347\224\250\345\237\272\347\241\200\350\265\204\346\226\231/Gy_DepartmentList.html"
@@ -172,7 +172,7 @@
$.ajax({
url: GetWEBURL() + '/Gy_Department/list',
type: "GET",
- data: { "sWhere": sWhere },
+ data: { "sWhere": sWhere, "Organization": Organization },
success: function (result) {
if (result.count == 1) {
option.data = result.data;
diff --git "a/WebTM/views/\345\237\272\347\241\200\350\265\204\346\226\231/\345\205\254\347\224\250\345\237\272\347\241\200\350\265\204\346\226\231/Gy_EmployeeList.html" "b/WebTM/views/\345\237\272\347\241\200\350\265\204\346\226\231/\345\205\254\347\224\250\345\237\272\347\241\200\350\265\204\346\226\231/Gy_EmployeeList.html"
index 445a1fe..5d5fd61 100644
--- "a/WebTM/views/\345\237\272\347\241\200\350\265\204\346\226\231/\345\205\254\347\224\250\345\237\272\347\241\200\350\265\204\346\226\231/Gy_EmployeeList.html"
+++ "b/WebTM/views/\345\237\272\347\241\200\350\265\204\346\226\231/\345\205\254\347\224\250\345\237\272\347\241\200\350\265\204\346\226\231/Gy_EmployeeList.html"
@@ -203,7 +203,7 @@
//url: "http://61.130.49.162:9090/WMSAPI///Web/GetMAXNum",
url: GetWEBURL() + '/Gy_Employee/list',
type: "GET",
- data: { "sWhere": sWhere },
+ data: { "sWhere": sWhere, "Organization": Organization },
success: function (data1) {
if (data1.count == 1) {
option.data = data1.data;
diff --git "a/WebTM/views/\345\237\272\347\241\200\350\265\204\346\226\231/\345\205\254\347\224\250\345\237\272\347\241\200\350\265\204\346\226\231/Gy_EquipType.html" "b/WebTM/views/\345\237\272\347\241\200\350\265\204\346\226\231/\345\205\254\347\224\250\345\237\272\347\241\200\350\265\204\346\226\231/Gy_EquipType.html"
new file mode 100644
index 0000000..83bb5bd
--- /dev/null
+++ "b/WebTM/views/\345\237\272\347\241\200\350\265\204\346\226\231/\345\205\254\347\224\250\345\237\272\347\241\200\350\265\204\346\226\231/Gy_EquipType.html"
@@ -0,0 +1,422 @@
+锘�<!DOCTYPE html>
+<html>
+<head>
+ <meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
+ <title>璁惧鍒嗙被</title>
+ <meta name="renderer" content="webkit">
+ <meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1">
+ <meta name="viewport" content="width=device-width, initial-scale=1, maximum-scale=1">
+ <link rel="stylesheet" href="../../../layuiadmin/layui/css/layui.css" media="all">
+ <link rel="stylesheet" href="../../../layuiadmin/style/admin.css" media="all">
+ <script src="../../../layuiadmin/layui/layui.js"></script>
+ <script src="../../../layuiadmin/Scripts/json2.js"></script>
+ <script src="../../../layuiadmin/Scripts/jquery-1.4.1.js"></script>
+ <script src="../../../layuiadmin/Scripts/webConfig.js"></script>
+ <script src="../../../layuiadmin/PubCustom.js"></script>
+</head>
+<body>
+ <div class="layui-fluid">
+ <div class="layui-col-md12">
+ <div class="layui-card" style="padding: 1px">
+ <div class="layui-card-body" style="padding: 1px;">
+ <form class="layui-form" action="" lay-filter="component-form-group">
+ <div class="layui-collapse">
+ <div class="layui-colla-item">
+ <div class="layui-inline">
+ <label class="layui-form-label" style="width: 85px;">浠g爜</label>
+ <div class="layui-input-block" style="margin-left: 120px;">
+ <input type="text" class="layui-input" name="HNumber" id="HNumber">
+ </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="HName" id="HName">
+ </div>
+ </div>
+ <button class="layui-btn layuiadmin-btn-order" type="button" lay-submit="" lay-filter="btnSearch" id="btnSearch">
+ <i class="layui-icon layui-icon-search layuiadmin-button-btn"></i>
+ </button>
+ <button class="layui-btn layuiadmin-btn-order" type="button" lay-submit="" lay-filter="btnReSearch" id="btnReSearch" style="padding:0 5px">閲嶇疆</button>
+
+ </div>
+ </div>
+ <table class="" id="mainTable" lay-filter="mainTable"></table>
+ <script type="text/html" id="toolbarDemo">
+ <div class="layui-btn-container">
+ <button type="button" class="layui-btn layui-btn-sm" lay-event="set_AddNew"><i class="layui-icon layui-icon-file-b"></i>鏂板</button>
+ <button type="button" class="layui-btn layui-btn-sm" lay-event="set_ShowBill"><i class="layui-icon layui-icon-form"></i>缂栬緫</button>
+ <button type="button" class="layui-btn layui-btn-sm" lay-event="set_DeleteBill"><i class="layui-icon layui-icon-delete"></i>鍒犻櫎</button>
+ <button type="button" class="layui-btn layui-btn-sm" lay-event="get_Refresh"><i class="layui-icon layui-icon-refresh-3"></i>鍒锋柊</button>
+ <button type="button" class="layui-btn layui-btn-sm" lay-event="btn-view"><i class="layui-icon layui-icon-tips"></i>棰勮</button>
+ <!--<button type="button" class="layui-btn layui-btn-sm" lay-event="btn-Audit"><i class="layui-icon layui-icon-radio"></i>瀹℃牳</button>
+ <button type="button" class="layui-btn layui-btn-sm" lay-event="btn-DeAudit"><i class="layui-icon layui-icon-circle"></i>鍙嶅鏍�</button>-->
+ <button type="button" class="layui-btn layui-btn-sm" lay-event="get_Exit"><i class="layui-icon layui-icon-logout"></i>閫�鍑�</button>
+ </div>
+ </script>
+ </form>
+ </div>
+ </div>
+ </div>
+ </div>
+ <script>
+ var TagId = "";
+ var TagParentId = "";
+ var Level = "1";
+ layui.config({
+ base: '../../../layuiadmin/' //闈欐�佽祫婧愭墍鍦ㄨ矾寰�
+ }).extend({
+ index: 'lib/index', //涓诲叆鍙fā鍧�
+ }).use(['tree', 'index', 'form', 'table', 'element', 'laypage', 'laydate'], function () {
+ //#region 鍏叡鍙橀噺
+ var $ = layui.$
+ , admin = layui.admin
+ , layer = layui.layer
+ , table = layui.table
+ , form = layui.form
+ , element = layui.element
+ , laypage = layui.laypage
+ , laydate = layui.laydate
+ , util = layui.util
+ , tree = layui.tree
+ //鏌ヨ鏉′欢
+ var sWhere = "";
+ var option = [];
+ //#endregion
+
+ //#region 杩涘叆椤甸潰鏃㈠姞杞�
+ set_ClearBill();
+ //#endregion
+
+ //#region 澶村伐鍏锋爮浜嬩欢
+
+ table.on('toolbar(mainTable)', function (obj) {
+ switch (obj.event) {
+ //鏂板
+ case 'set_AddNew': set_AddNew();
+ break;
+ //缂栬緫
+ case 'set_ShowBill': set_ShowBill();
+ break;
+ //鍒犻櫎
+ case 'set_DeleteBill': set_DeleteBill();
+ break;
+ //鍒锋柊
+ case 'get_Refresh': get_Refresh();
+ break;
+ //娴忚
+ case 'btn-view':
+ get_ViewReport();
+ break;
+ //瀹℃牳
+ case 'btn-Audit': set_AuditBill();
+ break;
+ //鍙嶅鏍�
+ case 'btn-DeAudit': set_DeAuditBill();
+ break;
+ //閫�鍑烘寜閽�
+ case 'get_Exit': Pub_Close(2);
+ break;
+ };
+ });
+ //#endregion
+
+ //#region 閲嶇疆鎸夐挳
+ form.on('submit(btnReSearch)', function (data) {
+ set_ClearQuery();
+ });
+ //#endregion
+
+ //#region 鏌ヨ鎸夐挳
+ form.on('submit(btnSearch)', function (data) {
+ get_FastQuery();
+ });
+ //#endregion
+ //鍒濆鍖栬〃鏍�
+
+ function set_ClearBill() {
+ //鍒濆鍖栬〃鏍�
+ set_InitGrid();
+
+ //鏌ヨ
+ get_Display(sWhere);
+ }
+
+ //#region鍒濆鍖栬〃鏍�
+ function set_InitGrid() {
+ option = {
+ elem: '#mainTable'
+ , toolbar: '#toolbarDemo'
+ , height: 'full-50'
+ , page: true
+ , limits: [50, 200, 500, 1000, 5000, 10000]
+ , limit: 50 //姣忛〉榛樿鏄剧ず鐨勬暟閲�
+ , cellMinWidth: 90
+ , limit: 50
+ , limits: [50, 200, 500, 1000, 5000, 10000]
+ , cols: [[
+ { type: 'checkbox', fixed: 'left' }
+ , { field: 'HItemID', title: 'HItemID', sort: true, hide: true }
+ , { field: 'HParentID', title: 'HParentID', sort: true, hide: true }
+ , { field: 'HNumber', title: '浠g爜', width: 200 }
+ , { field: 'HName', title: '鍚嶇О', width: 200 }
+ , { field: 'HLevel', title: '绛夌骇', width: 200 }
+ , { field: 'HEndFlag', title: '鏄庣粏鏍囪', width: 200 }
+ , { field: 'HStopFlag', title: '绂佺敤鏍囪', width: 200 }
+ , { field: 'HRemark', title: '澶囨敞', width: 200 }
+ , { field: 'HUseFlag', title: '浣跨敤鏍囪', width: 200 }
+ ]]
+ };
+ }
+ //鏌ヨ
+ function get_Display(sWhere) {
+ var ajaxLoad = layer.load();
+ //杩涘叆椤甸潰鏄剧ず鐨勭紦瀛樺垪琛�
+ $.ajax({
+ url: GetWEBURL() + '/Gy_EquipType/GetList',
+ type: "GET",
+ data: { "sWhere": sWhere},
+ success: function (data1) {
+ if (data1.count == 1) {
+ option.data = data1.data;
+ table.render(option);
+ layer.close(ajaxLoad);
+ } else {
+ layer.close(ajaxLoad);
+ layer.alert(data1.code + data1.Message, { icon: 5 });
+ }
+ }, error: function () {
+ layer.close(ajaxLoad);
+ layer.alert("鎺ュ彛璇锋眰澶辫触!", { icon: 5 });
+ }
+ });
+ }
+ //#endregion
+
+ //#region 蹇�熻繃婊�
+ function get_FastQuery() {
+ var HNumber = $("#HNumber").val();
+ var HName = $("#HName").val();
+ if (HNumber) {
+ sWhere += " and 璁惧浠g爜 like '%" + HNumber + "%'";
+ }
+ if (HName) {
+ sWhere += " and 璁惧鍚嶇О like '%" + HName + "%'";
+ }
+ get_Display(sWhere);
+ sWhere = "";//璋冪敤鎺ュ彛鍚庢竻绌簊Where缂撳瓨
+ }
+ //#endregion
+
+ //#region 閲嶇疆杩囨护鏉′欢鏂规硶
+ function set_ClearQuery() {
+ $("#HNumber").val("");
+ $("#HName").val("");
+ sWhere = "";
+ get_Display(sWhere);
+ }
+ //#endregion
+
+ //#region 宸ュ叿鏍忎簨浠�
+ //鏂板
+ function set_AddNew() {
+ //椤甸潰灞�-鑷畾涔�
+ layer.open({
+ type: 2,
+ skin: 'layui-layer-rim', //鍔犱笂杈规
+ title: '鏂板妫�楠岄」鐩�',
+ closeBtn: 1,
+ shift: 2,
+ area: ['80%', '80%'],
+ maxmin: true,
+ content: '../鍏敤鍩虹璧勬枡/Gy_EquipTypeEdit.html?OperationType=1&linterid=&HSouceBillType=0&closeType=1',
+ end: function () {
+ //鍒锋柊椤甸潰,
+ location.reload();
+ },
+ success: function (layero, index) {
+
+ }
+ });
+
+ }
+
+ //鍒犻櫎
+ function set_DeleteBill() {
+ var checkStatus = table.checkStatus('mainTable')
+ , data = checkStatus.data;
+ var layEvent = checkStatus.event;
+ if (checkStatus.data.length === 1) {
+ layer.confirm('鎮ㄧ‘瀹氳鍒犻櫎鍚楋紵', {
+ btn: ['纭畾', '鍙栨秷'] //鎸夐挳
+ , yes: function (index, layero) {
+
+ $.ajax({
+ url: GetWEBURL() + '/Gy_EquipType/Delete_EquipType',
+ type: "GET",
+ //async: true,
+ data: { "HItemID": data[0].HItemID},
+ success: function (result) {
+ if (result.count == 1) {
+ layer.msg(result.Message, { time: 1 * 1000, icon: 1 }, function () {
+ // 寰楀埌frame绱㈠紩
+ var index = layer.getFrameIndex(window.name);
+ //鍏抽棴褰撳墠frame
+ layer.close(index);
+ //淇敼涓哄姛鍚庡埛鏂扮晫闈�
+ window.location.reload();
+ //閲嶈浇tree
+ //tree.reload('treeDepartment', {});
+ });
+
+ } else {
+ layer.alert(result.code + result.Message, { icon: 5 });
+ }
+ }
+ })
+ }
+ });
+ }
+ else {
+ layer.msg('璇烽�夋嫨涓�琛屾暟鎹紪杈戯紒');
+ }
+ };
+
+ //鍒锋柊
+ function set_Refresh() {
+ $("#btnSearch").click();
+ }
+
+ //棰勮
+ function get_ViewReport() {
+ var checkStatus = table.checkStatus('mainTable')
+ , data = checkStatus.data;
+ if (checkStatus.data.length === 1) {
+ var InterID = data[0].hmainid.toString();
+ window.open("../../鍩虹璧勬枡/鍏敤鍩虹璧勬枡/HBarPlanPrint.html?linterid=" + InterID + "&Type=HEquipType&OpenTmp=璁惧鍒嗙被");
+
+ }
+ else {
+ layer.msg('璇烽�夋嫨涓�琛屾暟鎹墦鍗帮紒');
+ }
+ }
+
+ //瀹℃牳
+ function set_AuditBill() {
+ var checkStatus = table.checkStatus('mainTable')
+ , data = checkStatus.data;
+ if (checkStatus.data.length === 1) {
+ var HBillStatus = data[0].HBillStatus.toString(); //鍗曟嵁鐘舵��
+ var HInterID = data[0].hmainid.toString();
+ if (HBillStatus > 0) {
+ layer.msg('鍗曟嵁涓嶄负鏈鏍哥姸鎬侊紒');
+ return false;
+ }
+ //閫昏緫瀹℃牳鏂规硶
+ $.ajax({
+ type: "GET",
+ url: GetWEBURL() + "/Gy_Mould/AuditProcessReportList", //鏂规硶鎵�鍦ㄩ〉闈㈠拰鏂规硶鍚�
+ data: { "HInterID": HInterID, "IsAudit": 0, "CurUserName": sessionStorage["HUserName"] },
+ success: function (result) {
+ if (result.count == 1) {
+ layer.msg(result.Message, { time: 1 * 1000, icon: 1 }, function () {
+ // 寰楀埌frame绱㈠紩
+ var index = layer.getFrameIndex(window.name);
+ //鍏抽棴褰撳墠frame
+ layer.close(index);
+ //淇敼涓哄姛鍚庡埛鏂扮晫闈�
+ $("#btnSearch").trigger('click');
+ });
+
+ } else {
+ layer.alert(result.code + result.Message, { icon: 5 });
+ }
+ }, error: function () {
+ layer.alert("鎺ュ彛璇锋眰澶辫触!", { icon: 5 });
+ }
+ });
+ }
+ else {
+ layer.msg('璇烽�夋嫨涓�琛屾暟鎹鏍革紒');
+ }
+ }
+
+ //鍙嶅鏍�
+ function set_DeAuditBill() {
+ var checkStatus = table.checkStatus('mainTable')
+ , data = checkStatus.data;
+ if (checkStatus.data.length === 1) {
+ var HBillStatus = data[0].HBillStatus.toString(); //鍗曟嵁鐘舵��
+ var HInterID = data[0].hmainid.toString();
+ if (HBillStatus = 0) {
+ layer.msg('鍗曟嵁宸蹭负鏈鏍哥姸鎬�,鏃犻渶鍙嶅鏍革紒');
+ return false;
+ }
+ //閫昏緫瀹℃牳鏂规硶
+ $.ajax({
+ type: "GET",
+ url: GetWEBURL() + "/Gy_Mould/AuditProcessReportList", //鏂规硶鎵�鍦ㄩ〉闈㈠拰鏂规硶鍚�
+ data: { "HInterID": HInterID, "IsAudit": 1, "CurUserName": sessionStorage["HUserName"] },
+ success: function (result) {
+ if (result.count == 1) {
+ layer.msg(result.Message, { time: 1 * 1000, icon: 1 }, function () {
+ // 寰楀埌frame绱㈠紩
+ var index = layer.getFrameIndex(window.name);
+ //鍏抽棴褰撳墠frame
+ layer.close(index);
+ //淇敼涓哄姛鍚庡埛鏂扮晫闈�
+ $("#btnSearch").trigger('click');
+ });
+
+ } else {
+ layer.alert(result.code + result.Message, { icon: 5 });
+ }
+ }, error: function () {
+ layer.alert("鎺ュ彛璇锋眰澶辫触!", { icon: 5 });
+ }
+ });
+ }
+ else {
+ layer.msg('璇烽�夋嫨涓�琛屾暟鎹鏍革紒');
+ }
+
+ }
+
+ //淇敼鎸夐挳
+ function set_ShowBill() {
+ var checkStatus = table.checkStatus('mainTable')
+ , data = checkStatus.data;
+ if (checkStatus.data.length === 1) {
+ var linterid = data[0].HItemID;
+ TagParentId = data[0].HParentID;
+ //if (AllowLoadData(sSubStr) != false) {//闈炵┖楠岃瘉
+ layer.open({
+ type: 2
+ , area: ['80%', '80%']
+ , title: '缂栬緫妯℃不鍏峰垎绫�'
+ , closeBtn: 1
+ , shade: 0.6 //閬僵閫忔槑搴�
+ , maxmin: true //鍏佽鍏ㄥ睆鏈�灏忓寲
+ , anim: 0 //0-6鐨勫姩鐢诲舰寮忥紝-1涓嶅紑鍚痌
+ , content: '../鍏敤鍩虹璧勬枡/Gy_EquipTypeEdit.html?OperationType=3&linterid=' + linterid + '&HSouceBillType=0&closeType=1'
+
+ , resize: false,
+ end: function () {
+ //鍒锋柊椤甸潰,
+ location.reload();
+ }
+ , cancel: function () {
+ //$(".layui-btn").removeClass("layui-btn-disabled");
+ }
+ })
+
+ } else {
+ layer.msg('璇烽�夋嫨涓�琛屾暟鎹紪杈戯紒');
+ }
+ };
+ //浠ヤ笂鏄痩ayui妯″潡
+ });
+ </script>
+
+</body>
+</html>
\ No newline at end of file
diff --git "a/WebTM/views/\345\237\272\347\241\200\350\265\204\346\226\231/\345\205\254\347\224\250\345\237\272\347\241\200\350\265\204\346\226\231/Gy_EquipTypeEdit.html" "b/WebTM/views/\345\237\272\347\241\200\350\265\204\346\226\231/\345\205\254\347\224\250\345\237\272\347\241\200\350\265\204\346\226\231/Gy_EquipTypeEdit.html"
new file mode 100644
index 0000000..d6dc014
--- /dev/null
+++ "b/WebTM/views/\345\237\272\347\241\200\350\265\204\346\226\231/\345\205\254\347\224\250\345\237\272\347\241\200\350\265\204\346\226\231/Gy_EquipTypeEdit.html"
@@ -0,0 +1,211 @@
+锘�<!DOCTYPE html>
+<html>
+<head>
+ <meta charset="utf-8" />
+ <title>鏂板/缂栬緫妯℃不鍏峰垎绫�</title>
+ <meta name="renderer" content="webkit">
+ <meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1">
+ <meta name="viewport" content="width=device-width, initial-scale=1.0, minimum-scale=1.0, maximum-scale=1.0, user-scalable=0">
+ <link rel="stylesheet" href="../../../layuiadmin/layui/css/layui.css" media="all">
+ <link rel="stylesheet" href="../../../layuiadmin/style/admin.css" media="all">
+ <script src="../../../layuiadmin/layui/layui.js"></script>
+ <script src="../../../layuiadmin/Scripts/json2.js"></script>
+ <script src="../../../layuiadmin/Scripts/jquery-1.4.1.js"></script>
+ <script src="../../../layuiadmin/Scripts/webConfig.js"></script>
+ <script src="../../../layuiadmin/PubCustom.js"></script>
+ <style type="text/css">
+ .layui-form-label {
+ width: 85px;
+ }
+ </style>
+</head>
+<body>
+ <div id="layout1" class="layui-fluid">
+ <div class="layui-row layui-col-space15">
+ <div class="layui-col-md12">
+ <div class="layui-card">
+ <form id="form0" class="layui-form" lay-filter="component-form-group" action="">
+ <div class="layui-card-header">
+ <div class="layui-btn-group">
+
+ <button type="button" id="add-btn" class="layui-btn layui-btn-normal layui-btn-radius" lay-submit="" lay-filter="Saver">淇濆瓨</button>
+ <button type="button" class="layui-btn layui-btn-normal layui-btn-radius" lay-submit="" lay-filter="Exit">閫�鍑�</button>
+
+ </div>
+
+ </div>
+ <div class="layui-card-body">
+ <div class="layui-tab layui-tab-brief" lay-filter="docDemoTabBrief">
+ <div class="layui-tab-content">
+ <div class="layui-tab-item layui-show">
+ <div class="layui-form-item">
+ <div class="layui-inline">
+ <label class="layui-form-label">浠g爜</label>
+ <div class="layui-input-inline">
+ <input class="layui-input" name="HNumber" lay-verify="HNumber" id="HNumber">
+ <input id="HItemID" name="HItemID" type="hidden" />
+ <input id="HParentID" name="HParentID" type="hidden" />
+ <input id="HLevel" name="HLevel" type="hidden" />
+ </div>
+ </div>
+ <div class="layui-inline">
+ <label class="layui-form-label">鍚嶇О</label>
+ <div class="layui-input-inline">
+ <input class="layui-input" name="HName" lay-verify="HName" id="HName">
+ </div>
+ </div>
+ <div class="layui-inline">
+ <label class="layui-form-label">鍔╄鐮�</label>
+ <div class="layui-input-inline">
+ <input class="layui-input" name="HHelpCode" lay-verify="HHelpCode" id="HHelpCode">
+ </div>
+ </div>
+ <div class="layui-inline">
+ <label class="layui-form-label">澶囨敞</label>
+ <div class="layui-input-inline">
+ <textarea placeholder="璇疯緭鍏ョ淮澶囨敞" class="layui-textarea" name="HRemark" id="HRemark"></textarea>
+ </div>
+ </div>
+ </div>
+ <div class="layui-form-item">
+ <label class="layui-form-label">绂佺敤鏍囧織</label>
+ <div class="layui-input-block">
+ <input type="checkbox" name="HStopflag" id="HStopflag" lay-skin="primary" title="">
+ </div>
+ </div>
+ </div>
+ </div>
+ </div>
+ </div>
+ </form>
+ </div>
+ </div>
+ </div>
+ </div>
+ <script>
+ //鑾峰彇鍙傛暟
+ var params = get_UrlVars();
+ if (typeof (params[params[0]]) == "undefined") {
+ var OperationType = 1;//鎿嶄綔绫诲瀷
+ var closeType = 2; //鍏抽棴绫诲瀷
+ } else {
+ debugger;
+ var OperationType = params[params[0]];//鎿嶄綔绫诲瀷
+ var linterid = params[params[1]];//婧愬崟id
+ var HSouceBillType = params[params[2]];//婧愬崟绫诲瀷
+ var closeType = params[params[3]]; //鍏抽棴绫诲瀷
+ }
+
+ layui.config({
+ base: '../../../layuiadmin/' //闈欐�佽祫婧愭墍鍦ㄨ矾寰�
+ }).extend({
+ index: 'lib/index' //涓诲叆鍙fā鍧�
+ }).use(['index', 'form', 'laydate', 'table', 'element'], function () {
+
+ //#region 鍏叡鍙橀噺
+ var $ = layui.$
+ , admin = layui.admin
+ , layer = layui.layer
+ , table = layui.table
+ , form = layui.form
+ , laydate = layui.laydate
+ , element = layui.element;
+ //#endregion
+ //甯歌鐢ㄦ硶
+
+ //#region 宸ュ叿鎸夐挳
+ //閫�鍑烘寜閽�
+ form.on('submit(Exit)', function () {
+ Pub_Close(1);
+ })
+
+ //淇濆瓨
+ form.on('submit(Saver)', function (data) {//淇濆瓨
+ var refSav = "";
+ if (linterid == "" || linterid == null) {
+ refSav = "Add";
+ }
+ if (linterid != "" && linterid != null) {
+ refSav = "Update";
+ }
+ //debugger;
+ var isEndCheck = document.getElementById("HStopflag").checked;
+ data.field.HStopflag = isEndCheck;//灏嗘暟缁勫悎骞舵垚瀛楃涓�
+
+ data.field.HItemID = linterid == "" ? 0 : linterid;
+
+ data.field.HParentID = 0;
+ data.field.HLevel = $("#HLevel").val() == "" ? 1 : $("#HLevel").val();
+
+ var oMain = JSON.stringify(data.field)
+
+ var sMainSub = oMain + ';' + refSav ;
+
+ $.ajax(
+ {
+ type: "POST",
+ url: GetWEBURL() + "/Gy_EquipType/SaveEquipTypeList", //鏂规硶鎵�鍦ㄩ〉闈㈠拰鏂规硶鍚�
+ async: true,
+ data: { "msg": sMainSub },
+ dataType: "json",
+ success: function (data) {
+ if (data.count == 1) { // 璇存槑楠岃瘉鎴愬姛浜嗭紝
+ layer.msg(data.Message, { time: 1 * 1000, icon: 1 }, function () {
+ $('#add-btn').addClass("layui-btn-disabled").attr("disabled", true);
+ var index = parent.layer.getFrameIndex(window.name); //鍏堝緱鍒板綋鍓峣frame灞傜殑绱㈠紩
+ parent.layer.close(index); //鍐嶆墽琛屽叧闂� 聽 聽 聽 聽 聽聽 聽聽聽 聽
+ });
+ }
+ else {
+
+ f_alert(data.Message);
+ console.log("Reason" + sMainStr + "sub:" + JSON.stringify(layui.table.cache.mainTable));
+ }
+ layer.closeAll("loading");
+ },
+ error: function (err) {
+
+ f_alert("閿欒:" + err);
+ console.log("Reason" + sMainStr);
+ }
+ });
+ });
+
+ //#endregion
+
+
+ function f_alert(sMsg) {
+ layer.alert(sMsg, { icon: 5 });
+
+ }
+
+ if (OperationType == 3) {
+ $.ajax({
+ url: GetWEBURL() + "/Gy_EquipType/Gy_EquipTypeCheckDetai",
+ type: "GET",
+ data: {
+ "HInterID": linterid
+ },
+ success: function (d) {
+
+ ajaxReturnData = JSON.parse(JSON.stringify(d)).data;
+ $("#HNumber").val(d.data[0].HNumber);
+ $("#HName").val(d.data[0].HName);
+ $("#HHelpCode").val(d.data[0].HHelpCode);
+ $("#HRemark").val(d.data[0].HRemark);
+ $("#HLevel").val(d.data[0].HLevel);
+ $("input[name='HStopflag']").prop("checked", d.data[0].HStopflag);//true:閫変腑 false:涓嶉�変腑
+ layui.form.render();//瀹炴椂娓叉煋閫変腑鍜屼笉閫変腑鐨勬牱寮�,鏈�濂芥坊鍔犺繖鍙ヨ瘽
+ $("#HUpDater").val(sessionStorage["HUserName"]);//淇敼浜�
+ //table.reload(layTableId, {
+ // data: ajaxReturnData
+ //});
+ }
+
+ });
+ }
+ });
+ </script>
+</body>
+
+</html>
\ No newline at end of file
diff --git "a/WebTM/views/\345\237\272\347\241\200\350\265\204\346\226\231/\345\205\254\347\224\250\345\237\272\347\241\200\350\265\204\346\226\231/Gy_Material.html" "b/WebTM/views/\345\237\272\347\241\200\350\265\204\346\226\231/\345\205\254\347\224\250\345\237\272\347\241\200\350\265\204\346\226\231/Gy_Material.html"
index 3ee2c24..1a37772 100644
--- "a/WebTM/views/\345\237\272\347\241\200\350\265\204\346\226\231/\345\205\254\347\224\250\345\237\272\347\241\200\350\265\204\346\226\231/Gy_Material.html"
+++ "b/WebTM/views/\345\237\272\347\241\200\350\265\204\346\226\231/\345\205\254\347\224\250\345\237\272\347\241\200\350\265\204\346\226\231/Gy_Material.html"
@@ -215,7 +215,7 @@
//url: "http://61.130.49.162:9090/WMSAPI///Web/GetMAXNum",
url: GetWEBURL() + '/Gy_Material/list',
type: "GET",
- data: { "sWhere": sWhere },
+ data: { "sWhere": sWhere, "Organization": Organization},
success: function (data1) {
if (data1.count == 1) {
option.data = data1.data;
diff --git "a/WebTM/views/\345\237\272\347\241\200\350\265\204\346\226\231/\345\205\254\347\224\250\345\237\272\347\241\200\350\265\204\346\226\231/Gy_Unit.html" "b/WebTM/views/\345\237\272\347\241\200\350\265\204\346\226\231/\345\205\254\347\224\250\345\237\272\347\241\200\350\265\204\346\226\231/Gy_Unit.html"
index b50d472..60833c4 100644
--- "a/WebTM/views/\345\237\272\347\241\200\350\265\204\346\226\231/\345\205\254\347\224\250\345\237\272\347\241\200\350\265\204\346\226\231/Gy_Unit.html"
+++ "b/WebTM/views/\345\237\272\347\241\200\350\265\204\346\226\231/\345\205\254\347\224\250\345\237\272\347\241\200\350\265\204\346\226\231/Gy_Unit.html"
@@ -151,7 +151,7 @@
$.ajax({
url: GetWEBURL() + '/Gy_Unit/list1',
type: "GET",
- data: { "sWhere": sWhere },
+ data: { "sWhere": sWhere, "Organization": Organization },
success: function (data1) {
if (data1.count == 1) {
option.data = data1.data;
diff --git "a/WebTM/views/\345\237\272\347\241\200\350\265\204\346\226\231/\345\205\254\347\224\250\345\237\272\347\241\200\350\265\204\346\226\231/Gy_Warehouse.html" "b/WebTM/views/\345\237\272\347\241\200\350\265\204\346\226\231/\345\205\254\347\224\250\345\237\272\347\241\200\350\265\204\346\226\231/Gy_Warehouse.html"
index 390c345..5651949 100644
--- "a/WebTM/views/\345\237\272\347\241\200\350\265\204\346\226\231/\345\205\254\347\224\250\345\237\272\347\241\200\350\265\204\346\226\231/Gy_Warehouse.html"
+++ "b/WebTM/views/\345\237\272\347\241\200\350\265\204\346\226\231/\345\205\254\347\224\250\345\237\272\347\241\200\350\265\204\346\226\231/Gy_Warehouse.html"
@@ -178,7 +178,7 @@
//url: "http://61.130.49.162:9090/WMSAPI///Web/GetMAXNum",
url: GetWEBURL() + '/Gy_Warehouse/list',
type: "GET",
- data: { "sWhere": sWhere },
+ data: { "sWhere": sWhere, "Organization": Organization },
success: function (data1) {
if (data1.count == 1) {
option.data = data1.data;
diff --git "a/WebTM/views/\345\237\272\347\241\200\350\265\204\346\226\231/\345\205\254\347\224\250\345\237\272\347\241\200\350\265\204\346\226\231/HBarPlanPrint.html" "b/WebTM/views/\345\237\272\347\241\200\350\265\204\346\226\231/\345\205\254\347\224\250\345\237\272\347\241\200\350\265\204\346\226\231/HBarPlanPrint.html"
index 9d25bd4..ff4ab19 100644
--- "a/WebTM/views/\345\237\272\347\241\200\350\265\204\346\226\231/\345\205\254\347\224\250\345\237\272\347\241\200\350\265\204\346\226\231/HBarPlanPrint.html"
+++ "b/WebTM/views/\345\237\272\347\241\200\350\265\204\346\226\231/\345\205\254\347\224\250\345\237\272\347\241\200\350\265\204\346\226\231/HBarPlanPrint.html"
@@ -135,6 +135,9 @@
case "HMouldMaintainBill"://鍣ㄥ叿淇濆吇璁板綍鏉$爜
CreateDisplayViewerEx("100%", "100%", "../../grf/" + OpenTmp + ".grf", "xmlLBM_MouldMaintainBill.aspx?linterid=" + value, true, "");
break;
+ case "HEquipType"://璁惧鍒嗙被鍗曟墦鍗�
+ CreateDisplayViewerEx("100%", "100%", "../../grf/" + OpenTmp + ".grf", "xmlLBM_EquipTypeBill.aspx?linterid=" + value, true, "");
+ break;
}
</script>
</body>
diff --git "a/WebTM/views/\345\237\272\347\241\200\350\265\204\346\226\231/\345\205\254\347\224\250\345\237\272\347\241\200\350\265\204\346\226\231/Xt_ORGANIZATIONSList.html" "b/WebTM/views/\345\237\272\347\241\200\350\265\204\346\226\231/\345\205\254\347\224\250\345\237\272\347\241\200\350\265\204\346\226\231/Xt_ORGANIZATIONSList.html"
index 285f770..df458ea 100644
--- "a/WebTM/views/\345\237\272\347\241\200\350\265\204\346\226\231/\345\205\254\347\224\250\345\237\272\347\241\200\350\265\204\346\226\231/Xt_ORGANIZATIONSList.html"
+++ "b/WebTM/views/\345\237\272\347\241\200\350\265\204\346\226\231/\345\205\254\347\224\250\345\237\272\347\241\200\350\265\204\346\226\231/Xt_ORGANIZATIONSList.html"
@@ -156,7 +156,7 @@
//url: "http://61.130.49.162:9090/WMSAPI///Web/GetMAXNum",
url: GetWEBURL() + '/Xt_ORGANIZATIONS/list',
type: "GET",
- data: { "sWhere": sWhere },
+ data: { "sWhere": sWhere, "Organization": Organization },
success: function (data1) {
if (data1.count == 1) {
option.data = data1.data;
diff --git "a/WebTM/views/\345\237\272\347\241\200\350\265\204\346\226\231/\345\205\254\347\224\250\345\237\272\347\241\200\350\265\204\346\226\231/xmlLBM_EquipTypeBill.aspx" "b/WebTM/views/\345\237\272\347\241\200\350\265\204\346\226\231/\345\205\254\347\224\250\345\237\272\347\241\200\350\265\204\346\226\231/xmlLBM_EquipTypeBill.aspx"
new file mode 100644
index 0000000..008c0d7
--- /dev/null
+++ "b/WebTM/views/\345\237\272\347\241\200\350\265\204\346\226\231/\345\205\254\347\224\250\345\237\272\347\241\200\350\265\204\346\226\231/xmlLBM_EquipTypeBill.aspx"
@@ -0,0 +1,28 @@
+锘�<%@ Page Language="C#" AutoEventWireup="true" CodeBehind="xmlLBM_EquipTypeBill.aspx.cs" Inherits="WebTM.views.鍩虹璧勬枡.鍏敤鍩虹璧勬枡.xmlLBM_EquipTypeBill" %>
+
+<!DOCTYPE html>
+
+<html xmlns="http://www.w3.org/1999/xhtml">
+<head runat="server">
+<meta http-equiv="Content-Type" content="text/html; charset=utf-8"/>
+ <title></title>
+ <script runat="server">
+ protected void Page_Load(object sender, EventArgs e)
+ {
+ //鈽呯壒鍒彁绀衡槄锛�
+ //涓嶅悓鐨勬暟鎹簱搴旇閫夌敤涓嶅悓鐨勬姤琛╔ML鏁版嵁鐢熸垚绫伙紝SQL Server鏁版嵁搴撶敤SqlXMLReportData锛孫racle鏁版嵁搴撶敤OracleXMLReportData
+ //OledbXMLReportData閫傚悎浜嶢ccess绛夋湰鍦版暟鎹簱锛屼负浜嗘紨绀烘柟渚匡紝杩欓噷浠嶨rid++Report鐨凙ccess渚嬪瓙鏁版嵁搴撲腑鑾峰彇鎶ヨ〃鏁版嵁
+
+ //OledbXMLReportData.GenOneRecordset(this, "select * from Customers order by CustomerID");
+ //SqlXMLReportData.GenOneRecordset(this, "select * from h_v_Kf_POStockInBillList_K3 where hmainid=1781");
+ SqlXMLReportData.GenOneRecordset(this, "select * from h_v_Gy_EquipTypeList where hmainid=" + Request.Params["linterid"]+ " order by hsubid");
+ }
+</script>
+</head>
+<body>
+ <form id="form1" runat="server">
+ <div>
+ </div>
+ </form>
+</body>
+</html>
diff --git "a/WebTM/views/\345\237\272\347\241\200\350\265\204\346\226\231/\345\205\254\347\224\250\345\237\272\347\241\200\350\265\204\346\226\231/xmlLBM_EquipTypeBill.aspx.cs" "b/WebTM/views/\345\237\272\347\241\200\350\265\204\346\226\231/\345\205\254\347\224\250\345\237\272\347\241\200\350\265\204\346\226\231/xmlLBM_EquipTypeBill.aspx.cs"
new file mode 100644
index 0000000..cb4c12a
--- /dev/null
+++ "b/WebTM/views/\345\237\272\347\241\200\350\265\204\346\226\231/\345\205\254\347\224\250\345\237\272\347\241\200\350\265\204\346\226\231/xmlLBM_EquipTypeBill.aspx.cs"
@@ -0,0 +1,17 @@
+锘縰sing System;
+using System.Collections.Generic;
+using System.Linq;
+using System.Web;
+using System.Web.UI;
+using System.Web.UI.WebControls;
+
+namespace WebTM.views.鍩虹璧勬枡.鍏敤鍩虹璧勬枡
+{
+ public partial class xmlLBM_EquipTypeBill : System.Web.UI.Page
+ {
+ protected void Page_Load(object sender, EventArgs e)
+ {
+
+ }
+ }
+}
\ No newline at end of file
diff --git "a/WebTM/views/\345\237\272\347\241\200\350\265\204\346\226\231/\345\205\254\347\224\250\345\237\272\347\241\200\350\265\204\346\226\231/xmlLBM_EquipTypeBill.aspx.designer.cs" "b/WebTM/views/\345\237\272\347\241\200\350\265\204\346\226\231/\345\205\254\347\224\250\345\237\272\347\241\200\350\265\204\346\226\231/xmlLBM_EquipTypeBill.aspx.designer.cs"
new file mode 100644
index 0000000..9185d2c
--- /dev/null
+++ "b/WebTM/views/\345\237\272\347\241\200\350\265\204\346\226\231/\345\205\254\347\224\250\345\237\272\347\241\200\350\265\204\346\226\231/xmlLBM_EquipTypeBill.aspx.designer.cs"
@@ -0,0 +1,26 @@
+锘�//------------------------------------------------------------------------------
+// <鑷姩鐢熸垚>
+// 姝や唬鐮佺敱宸ュ叿鐢熸垚銆�
+//
+// 瀵规鏂囦欢鐨勬洿鏀瑰彲鑳藉鑷翠笉姝g‘鐨勮涓猴紝濡傛灉
+// 閲嶆柊鐢熸垚浠g爜锛屽垯鎵�鍋氭洿鏀瑰皢涓㈠け銆�
+// </鑷姩鐢熸垚>
+//------------------------------------------------------------------------------
+
+namespace WebTM.views.鍩虹璧勬枡.鍏敤鍩虹璧勬枡
+{
+
+
+ public partial class xmlLBM_EquipTypeBill
+ {
+
+ /// <summary>
+ /// form1 鎺т欢銆�
+ /// </summary>
+ /// <remarks>
+ /// 鑷姩鐢熸垚鐨勫瓧娈点��
+ /// 鑻ヨ杩涜淇敼锛岃灏嗗瓧娈靛0鏄庝粠璁捐鍣ㄦ枃浠剁Щ鍒颁唬鐮侀殣钘忔枃浠躲��
+ /// </remarks>
+ protected global::System.Web.UI.HtmlControls.HtmlForm form1;
+ }
+}
diff --git "a/WebTM/views/\345\237\272\347\241\200\350\265\204\346\226\231/\351\207\207\350\264\255\345\237\272\347\241\200\350\265\204\346\226\231/Gy_Supplier.html" "b/WebTM/views/\345\237\272\347\241\200\350\265\204\346\226\231/\351\207\207\350\264\255\345\237\272\347\241\200\350\265\204\346\226\231/Gy_Supplier.html"
index 4e624e8..f65f189 100644
--- "a/WebTM/views/\345\237\272\347\241\200\350\265\204\346\226\231/\351\207\207\350\264\255\345\237\272\347\241\200\350\265\204\346\226\231/Gy_Supplier.html"
+++ "b/WebTM/views/\345\237\272\347\241\200\350\265\204\346\226\231/\351\207\207\350\264\255\345\237\272\347\241\200\350\265\204\346\226\231/Gy_Supplier.html"
@@ -153,7 +153,7 @@
$.ajax({
url: GetWEBURL() + '/Gy_Supplier/list',
type: "GET",
- data: { "sWhere": sWhere },
+ data: { "sWhere": sWhere, "Organization": Organization },
success: function (data1) {
if (data1.count == 1) {
option.data = data1.data;
diff --git "a/WebTM/views/\345\237\272\347\241\200\350\265\204\346\226\231/\351\224\200\345\224\256\345\237\272\347\241\200\350\265\204\346\226\231/Gy_Customer.html" "b/WebTM/views/\345\237\272\347\241\200\350\265\204\346\226\231/\351\224\200\345\224\256\345\237\272\347\241\200\350\265\204\346\226\231/Gy_Customer.html"
index 8d38328..9940913 100644
--- "a/WebTM/views/\345\237\272\347\241\200\350\265\204\346\226\231/\351\224\200\345\224\256\345\237\272\347\241\200\350\265\204\346\226\231/Gy_Customer.html"
+++ "b/WebTM/views/\345\237\272\347\241\200\350\265\204\346\226\231/\351\224\200\345\224\256\345\237\272\347\241\200\350\265\204\346\226\231/Gy_Customer.html"
@@ -161,7 +161,7 @@
//url: "http://61.130.49.162:9090/WMSAPI///Web/GetMAXNum",
url: GetWEBURL() + '/Gy_Customer/list',
type: "GET",
- data: { "sWhere": sWhere },
+ data: { "sWhere": sWhere, "Organization": Organization },
success: function (data1) {
if (data1.count == 1) {
option.data = data1.data;
diff --git "a/WebTM/views/\351\207\207\350\264\255\347\256\241\347\220\206/\351\207\207\350\264\255\350\256\242\345\215\225/Cg_POOrderBillList.html" "b/WebTM/views/\351\207\207\350\264\255\347\256\241\347\220\206/\351\207\207\350\264\255\350\256\242\345\215\225/Cg_POOrderBillList.html"
index fca88ac..165065d 100644
--- "a/WebTM/views/\351\207\207\350\264\255\347\256\241\347\220\206/\351\207\207\350\264\255\350\256\242\345\215\225/Cg_POOrderBillList.html"
+++ "b/WebTM/views/\351\207\207\350\264\255\347\256\241\347\220\206/\351\207\207\350\264\255\350\256\242\345\215\225/Cg_POOrderBillList.html"
@@ -1,7 +1,7 @@
锘�<!DOCTYPE html>
-<html xmlns="http://www.w3.org/1999/xhtml">
+<html>
<head>
-<meta http-equiv="Content-Type" content="text/html; charset=utf-8"/>
+ <meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<title>閲囪喘璁㈠崟鍒楄〃</title>
<meta name="renderer" content="webkit">
<meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1">
@@ -9,6 +9,12 @@
<link rel="stylesheet" href="../../../layuiadmin/layui/css/layui.css" media="all">
<link rel="stylesheet" href="../../../layuiadmin/style/admin.css" media="all">
<script src="../../../layuiadmin/layui/layui.js"></script>
+ <script src="../../../layuiadmin/layui/layui.js"></script>
+ <script src="../../../layuiadmin/Scripts/json2.js"></script>
+ <script src="../../../layuiadmin/Scripts/jquery-1.4.1.js"></script>
+ <script src="../../../layuiadmin/Scripts/webConfig.js"></script>
+ <script src="../../../layuiadmin/PubCustom.js"></script>
+ <script src="../../../layuiadmin/zgqCustom/zgqCustom.js"></script>
</head>
<body>
<div class="layui-fluid">
@@ -24,28 +30,33 @@
</div>
</div>
<div class="layui-inline">
+ <label class="layui-form-label">鍙戝竷鐘舵��</label>
+ <div class="layui-input-block">
+ <select name="HStatus" lay-filter="HStatus" style="width:190px;">
+ <option value="-1" selected="selected">鍏ㄩ儴</option>
+ <option value="1">鏈垎閰�</option>
+ <option value="2">宸插垎閰�</option>
+ <option value="3">宸插彂甯�</option>
+ </select>
+ </div>
+ </div>
+ <div class="layui-inline">
<label class="layui-form-label">寮�濮嬫棩鏈�</label>
<div class="layui-input-block">
- <input type="date" class="layui-input" id="HDate">
+ <input type="date" class="layui-input" id="HBeginDate" style="width:190px;">
</div>
</div>
<div class="layui-inline">
<label class="layui-form-label">缁撴潫鏃ユ湡</label>
<div class="layui-input-block">
- <input type="date" class="layui-input" id="HDate1">
+ <input type="date" class="layui-input" id="HEndDate" style="width:190px;">
</div>
</div>
- <!--<div class="layui-inline">
- <label class="layui-form-label">璁㈠崟璺熻釜鍙�</label>
- <div class="layui-input-block">
- <input type="text" class="layui-input" name="HOrderProcNO" id="HOrderProcNO">
- </div>
- </div>-->
+
<button class="layui-btn layuiadmin-btn-order" type="button" lay-submit="" lay-filter="btnSearch" id="btnSearch">
<i class="layui-icon layui-icon-search layuiadmin-button-btn"></i>
</button>
<button class="layui-btn layuiadmin-btn-order" type="button" lay-submit="" lay-filter="btnReSearch" id="btnReSearch" style="padding:0 5px">閲嶇疆</button>
-
<div class="layui-colla-content">
<div class="layui-inline">
<div class="layui-inline">
@@ -55,7 +66,17 @@
<div class="layui-inline">
<label class="layui-form-label">鍗曟嵁鍙�</label>
<div class="layui-input-block">
- <input type="text" class="layui-input" name="WorkCenter" id="WorkCenter">
+ <input type="text" class="layui-input" name="HBillNo" id="HBillNo" style="width:190px;">
+ </div>
+ </div>
+ <div class="layui-inline">
+ <label class="layui-form-label">渚涘簲鍟嗕俊鎭�</label>
+ <div class="layui-input-inline">
+ <input type="text" name="HSupName" id="HSupName" readonly class="layui-input" value="" style="float:left;width:150px;">
+ <input type="hidden" name="HSupID" id="HSupID" class="layui-input" value="" style="float:left;width:150px;">
+ <button type="button" lay-submit="" class="layui-btn" lay-filter="Department" style="width:40px;">
+ <i class="layui-icon layui-icon-search layuiadmin-button-btn" style="margin-left:-9px;"></i>
+ </button>
</div>
</div>
</div>
@@ -64,14 +85,16 @@
<table class="" id="mainTable" lay-filter="mainTable"></table>
<script type="text/html" id="toolbarDemo">
<div class="layui-btn-container">
- <!--<button type="button" class="layui-btn layui-btn-sm" lay-event="btn-getCheckData"><i class="layui-icon layui-icon-tips"></i>棰勮</button>-->
- <button type="button" class="layui-btn layui-btn-sm" lay-event="btn-reload"><i class="layui-icon layui-icon-refresh"></i>鍒锋柊</button>
- <button type="button" class="layui-btn layui-btn-sm" lay-event="btn-confirm" id="btn_confirm"><i class="layui-icon layui-icon-ok-circle"></i>纭</button>
- <button type="button" class="layui-btn layui-btn-sm" lay-event="btn-back" id="btn_back"><i class="layui-icon layui-icon-close-fill"></i>椹冲洖</button>
- <button type="button" class="layui-btn layui-btn-sm" lay-event="btn-details"><i class="layui-icon layui-icon-form"></i>璇︽儏</button>
- <button type="button" class="layui-btn layui-btn-sm" lay-event="btn-generate"><i class="layui-icon layui-icon-file"></i>鐢熸垚閫佽揣鍗�</button>
- <button type="button" class="layui-btn layui-btn-sm" lay-event="btn-exit"><i class="layui-icon layui-icon-return"></i>閫�鍑�</button>
+ <!--<button type="button" class="layui-btn layui-btn-sm" lay-event="btn-Add"><i class="layui-icon layui-icon-file-b"></i>鏂板</button>
+ <button type="button" class="layui-btn layui-btn-sm" lay-event="btn-Edit"><i class="layui-icon layui-icon-form"></i>缂栬緫</button>
+ <button type="button" class="layui-btn layui-btn-sm" lay-event="btn-Delete"><i class="layui-icon layui-icon-delete"></i>鍒犻櫎</button>-->
+ <button type="button" class="layui-btn layui-btn-sm" lay-event="btn-fp"><i class="layui-icon layui-icon-tips"></i>鍒嗛厤</button>
+ <button type="button" class="layui-btn layui-btn-sm" lay-event="btn-fb"><i class="layui-icon layui-icon-tips"></i>鍙戝竷</button>
+ <button type="button" class="layui-btn layui-btn-sm" lay-event="btn-view"><i class="layui-icon layui-icon-tips"></i>棰勮</button>
+ <button type="button" class="layui-btn layui-btn-sm" lay-event="btn-print"><i class="layui-icon layui-icon-print"></i>鎵撳嵃</button>
+ <button type="button" class="layui-btn layui-btn-sm" lay-event="get_Refresh"><i class="layui-icon layui-icon-refresh-3"></i>鍒锋柊</button>
+ <button type="button" class="layui-btn layui-btn-sm" lay-event="get_Exit"><i class="layui-icon layui-icon-logout"></i>閫�鍑�</button>
</div>
</script>
</form>
@@ -79,165 +102,753 @@
</div>
</div>
</div>
- <script src="../../../layuiadmin/layui/layui.js"></script>
- <script src="../../../layuiadmin/Scripts/json2.js"></script>
- <script src="../../../layuiadmin/Scripts/jquery-1.4.1.js"></script>
- <script src="../../../layuiadmin/Scripts/webConfig.js"></script>
- <script>
+ <script type="text/javascript">
layui.config({
base: '../../../layuiadmin/' //闈欐�佽祫婧愭墍鍦ㄨ矾寰�
}).extend({
index: 'lib/index', //涓诲叆鍙fā鍧�
- }).use(['index', 'form', 'table', 'element', 'laypage','laydate'], function () {
+ }).use(['index', 'form', 'table', 'element', 'laypage', 'laydate'], function () {
+ //#region 鍏叡鍙橀噺
var $ = layui.$
- , admin = layui.admin
- , layer = layui.layer
- , table = layui.table
- , form = layui.form
- , element = layui.element
- , laypage = layui.laypage
- , laydate = layui.laydate
- //var sWhere = " 浜у搧浠g爜 = 'BX0002'";
+ , admin = layui.admin
+ , layer = layui.layer
+ , table = layui.table
+ , form = layui.form
+ , element = layui.element
+ , laypage = layui.laypage
+ , laydate = layui.laydate
+ , util = layui.util
+ //鏌ヨ鏉′欢
var sWhere = "";
+ var option = [];
+ var Name = "MouldProdInHouseCellWidth";
+ //#endregion
- var option = {
- elem: '#mainTable'
- //, toolbar: '#toolbarDemo'
- ,height: 'full-50'
- , page: true
- ,cellMinWidth: 90
- , cols: [[
- { field: 'hmainid', title: 'hmainid', sort: true, hide: true }
- , { field: '鏃ユ湡', title: '鏃ユ湡' }
- , { field: '鍗曟嵁鍙�', title: '鍗曟嵁鍙�' }
- , { field: 'HBillType', title: 'HBillType', hide: true }
- , { field: 'HSupID', title: 'HSupID', hide: true }
- , { field: '渚涘簲鍟嗕唬鐮�', title: '渚涘簲鍟嗕唬鐮�' }
- , { field: '渚涘簲鍟�', title: '渚涘簲鍟�' }
- , { field: '浜よ揣鍦扮偣', title: '浜よ揣鍦扮偣' }
- , { field: 'HPSStyleID', title: 'HPSStyleID', hide: true }
- , { field: '閲囪喘鏂瑰紡浠g爜', title: '閲囪喘鏂瑰紡浠g爜' }
- , { field: '閲囪喘鏂瑰紡', title: '閲囪喘鏂瑰紡' }
- , { field: 'HSSID', title: 'HSSID', hide: true }
- , { field: '缁撶畻鏂瑰紡浠g爜', title: '缁撶畻鏂瑰紡浠g爜' }
- , { field: '缁撶畻鏂瑰紡', title: '缁撶畻鏂瑰紡' }
- , { field: '缁撶畻鏃ユ湡', title: '缁撶畻鏃ユ湡' }
- , { field: 'HCurID', title: 'HCurID', hide: true }
- , { field: '甯佸埆浠g爜', title: '甯佸埆浠g爜' }
- , { field: '甯佸埆', title: '甯佸埆' }
- , { field: '姹囩巼', title: '姹囩巼' }
- , { field: 'HDeptID', title: 'HDeptID', hide: true }
- , { field: '閮ㄩ棬浠g爜', title: '閮ㄩ棬浠g爜' }
- , { field: '閮ㄩ棬', title: '閮ㄩ棬' }
- , { field: 'HManagerID', title: 'HManagerID', hide: true }
- , { field: '涓荤浠g爜', title: '涓荤浠g爜' }
- , { field: '涓荤', title: '涓荤' }
- , { field: 'HEmpID', title: 'HEmpID', hide: true }
- , { field: '涓氬姟鍛樹唬鐮�', title: '涓氬姟鍛樹唬鐮�' }
- , { field: '涓氬姟鍛�', title: '涓氬姟鍛�' }
- , { field: '鎽樿', title: '鎽樿' }
- , { field: '琛ㄥご澶囨敞', title: '琛ㄥご澶囨敞' }
- , { field: 'hsubid', title: 'hsubid', hide: true }
- , { field: 'HMaterID', title: 'HMaterID', hide: true }
- , { field: '鐗╂枡浠g爜', title: '鐗╂枡浠g爜' }
- , { field: '鐗╂枡鍚嶇О', title: '鐗╂枡鍚嶇О' }
- , { field: '瑙勬牸鍨嬪彿', title: '瑙勬牸鍨嬪彿' }
- , { field: '鎵瑰彿', title: '鎵瑰彿' }
- , { field: 'HUnitID', title: 'HUnitID', hide: true }
- , { field: '璁¢噺鍗曚綅浠g爜', title: '璁¢噺鍗曚綅浠g爜' }
- , { field: '璁¢噺鍗曚綅', title: '璁¢噺鍗曚綅' }
- , { field: '鏁伴噺', title: '鏁伴噺' }
- , { field: '鍗曚环', title: '鍗曚环' }
- , { field: '閲戦', title: '閲戦' }
- , { field: '绋庣巼', title: '绋庣巼' }
- , { field: '绋庨', title: '绋庨' }
- , { field: '浠风◣鍚堣', title: '浠风◣鍚堣' }
- , { field: '浜よ揣鏃ユ湡', title: '浜よ揣鏃ユ湡' }
- , { field: '婧愬崟鍗曞彿', title: '婧愬崟鍗曞彿' }
- , { field: '璁″垝璺熻釜鍙�', title: '璁″垝璺熻釜鍙�' }
- , { field: '琛ㄤ綋澶囨敞', title: '琛ㄤ綋澶囨敞' }
- , { field: '鍒跺崟浜�', title: '鍒跺崟浜�' }
- , { field: '鍒跺崟鏃ユ湡', title: '鍒跺崟鏃ユ湡' }
- , { field: '瀹℃牳浜�', title: '瀹℃牳浜�' }
- , { field: '瀹℃牳鏃ユ湡', title: '瀹℃牳鏃ユ湡' }
- , { field: '淇敼浜�', title: '淇敼浜�' }
- , { field: '淇敼鏃ユ湡', title: '淇敼鏃ユ湡' }
- , { field: '鍏抽棴浜�', title: '鍏抽棴浜�' }
- , { field: '鍏抽棴鏃ユ湡', title: '鍏抽棴鏃ユ湡' }
- , { field: '浣滃簾浜�', title: '浣滃簾浜�' }
- , { field: '浣滃簾鏃ユ湡', title: '浣滃簾鏃ユ湡' }
- ]]
- };
+ //#region 杩涘叆椤甸潰鏃㈠姞杞�
+ //鍒濆鍖栬〃鏍�
+ set_InitGrid();
+ //鍔犺浇鏁版嵁鍒扮綉鏍�
+ get_Display(sWhere);
+ //#endregion
- //杩涘叆椤甸潰鏄剧ず鐨勭紦瀛樺垪琛�
- var index0 = layer.load(0, { shade: false });
- $.ajax({
- //url: "http://61.130.49.162:9090/WMSAPI///Web/GetMAXNum",
- url: GetWEBURL() + '/Cg_POOrderBill/list',
- type: "GET",
- data: { "sWhere": sWhere },
- success: function (data1) {
- if (data1.count == 1) {
- option.data = data1.data;
- table.render(option);
- layer.close(index0);
- } else {
- layer.close(index0);
- layer.alert(data1.code + data1.Message, { icon: 5 });
- }
- }, error: function () {
- layer.close(index0);
- layer.alert("鎺ュ彛璇锋眰澶辫触!", { icon: 5 });
- }
- });
+ //#region 鐐瑰嚮浜嬩欢鍖呮嫭on form浜嬩欢绛�
+ //澶村伐鍏锋爮浜嬩欢
+ table.on('toolbar(mainTable)', function (obj) {
+ switch (obj.event) {
+ //鏂板鎸夐挳
+ case 'btn-Add': set_AddNew();
+ break;
+ //缂栬緫鎸夐挳
+ case 'btn-Edit': set_ShowBill();
+ break;
+ //鍒犻櫎鎸夐挳
+ case 'btn-Delete': set_DeleteBill();
+ break;
+ //娴忚
+ case 'btn-view': get_ViewReport();
+ break;
+ //鎵撳嵃
+ case 'btn-print': get_PrintReport();
+ break;
+ //鍒锋柊
+ case 'get_Refresh': set_Refresh();
+ break;
+
+ //閫�鍑�
+ case 'get_Exit': Pub_Close(2);
+ break;
+ //鍒嗛厤
+ case 'btn-fp': set_Distribut();
+ break;
+ //鍙戝竷
+ case 'btn-fb': set_Release();
+ break;
+ };
+ });
+
//閲嶇疆鎸夐挳
form.on('submit(btnReSearch)', function (data) {
- $("#HDate").val("");//寮�濮嬫棩鏈�
- $("#HDate1").val("");//缁撴潫鏃ユ湡
- $("#WorkCenter").val("");//鍗曟嵁鍙�
- $("#btnSearch").click();
+ set_ClearQuery();
});
//鏌ヨ鎸夐挳
- form.on('submit(btnSearch)', function (data) {//閫夋嫨浠撲綅
- var HDate = $("#HDate").val();//寮�濮嬫棩鏈�
- var HDate1 = $("#HDate1").val();//缁撴潫鏃ユ湡
- var HOrderProcNO = $("#HOrderProcNO").val();//璁㈠崟璺熻釜鍙�
- var WorkCenter = $("#WorkCenter").val();//鍗曟嵁鍙�
- if (HDate) {
- sWhere += " and 鏃ユ湡 >= '" + HDate + "'";
+ form.on('submit(btnSearch)', function (data) {
+ get_FastQuery(table, option);
+ });
+
+ //琛ㄥご淇℃伅閮ㄩ棬寮圭獥
+ form.on('submit(Department)', function () {
+ //椤甸潰灞�-鑷畾涔�
+ layer.open({
+ type: 2,
+ skin: 'layui-layer-rim', //鍔犱笂杈规
+ title: '渚涘簲鍟嗗垪琛�',
+ closeBtn: 1,
+ shift: 2,
+ area: ['80%', '80%'],
+ maxmin: true,
+ content: ['../../PublicPage/SupplierInformation.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('璇烽�夋嫨鏁版嵁');
+ }
+ $("#HSupName").val(checkStatus.data[0].HName);
+ $("#HSupID").val(checkStatus.data[0].HItemID);
+ layer.close(layer.index); //瀹冭幏鍙栫殑濮嬬粓鏄渶鏂板脊鍑虹殑鏌愪釜灞傦紝鍊兼槸鐢眑ayer鍐呴儴鍔ㄦ�侀�掑璁$畻鐨�
+ }
+ , btn2: function (index, layero) {
+ //鎸夐挳銆愭寜閽簩銆戠殑鍥炶皟
+ //return false 寮�鍚浠g爜鍙姝㈢偣鍑昏鎸夐挳鍏抽棴
+ },
+ end: function () {
+
+ },
+ success: function (layero, index) {
+
+ }
+ });
+ });
+ //#endregion
+
+
+ //#region 姝ら〉闈㈡墍鏈夋柟娉�
+ //鍒濆鍖栬〃鏍�
+ function set_InitGrid() {
+ $("#HBeginDate").val(Format(new Date(new Date() - 1000 * 60 * 60 * 24 * 30), "yyyy-MM-dd"));
+ $("#HEndDate").val(Format(new Date(), "yyyy-MM-dd"));
+ var columns = [
+ { type: 'checkbox', fixed: 'left', totalRowText: '鍚堣' }
+ ,{ field: 'hmainid', title: 'hmainid', sort: true, hide: true }
+ , { field: '鏃ユ湡', title: '鏃ユ湡', width: 120, templet: "<div>{{d.鏃ユ湡 ==null ?'':layui.util.toDateString(d.鏃ユ湡, 'yyyy-MM-dd')}}</div>" }
+ , { field: '鍗曟嵁鍙�', title: '鍗曟嵁鍙�', width: 150 }
+ , { field: 'HBillType', title: 'HBillType', hide: true }
+ , { field: 'HSupID', title: 'HSupID', hide: true }
+ , { field: '涓氬姟鐘舵��', title: '涓氬姟鐘舵��', width: 100 }
+ , { field: '渚涘簲鍟嗕唬鐮�', title: '渚涘簲鍟嗕唬鐮�', width: 120}
+ , { field: '渚涘簲鍟�', title: '渚涘簲鍟�', width: 100 }
+ , { field: '涓氬姟鍛樹唬鐮�', title: '涓氬姟鍛樹唬鐮�', width: 100 }
+ , { field: '涓氬姟鍛�', title: '涓氬姟鍛�', width: 100 }
+ , { field: '浜よ揣鍦扮偣', title: '浜よ揣鍦扮偣', width: 100}
+ , { field: 'HPSStyleID', title: 'HPSStyleID', hide: true }
+ , { field: '閲囪喘鏂瑰紡浠g爜', title: '閲囪喘鏂瑰紡浠g爜', width: 120}
+ , { field: '閲囪喘鏂瑰紡', title: '閲囪喘鏂瑰紡', width: 100}
+ , { field: 'HSSID', title: 'HSSID', hide: true }
+ , { field: '缁撶畻鏂瑰紡浠g爜', title: '缁撶畻鏂瑰紡浠g爜', width: 120}
+ , { field: '缁撶畻鏂瑰紡', title: '缁撶畻鏂瑰紡', width: 100}
+ , { field: '缁撶畻鏃ユ湡', title: '缁撶畻鏃ユ湡', width: 120, templet: "<div>{{d.鏃ユ湡 ==null ?'':layui.util.toDateString(d.缁撶畻鏃ユ湡, 'yyyy-MM-dd')}}</div>" }
+ , { field: 'HCurID', title: 'HCurID', hide: true }
+ , { field: '甯佸埆浠g爜', title: '甯佸埆浠g爜', width: 100}
+ , { field: '甯佸埆', title: '甯佸埆', width: 100}
+ , { field: '姹囩巼', title: '姹囩巼', width: 100}
+ , { field: 'HDeptID', title: 'HDeptID', hide: true }
+ , { field: '閮ㄩ棬浠g爜', title: '閮ㄩ棬浠g爜', width: 100}
+ , { field: '閮ㄩ棬', title: '閮ㄩ棬', width: 100}
+ , { field: 'HManagerID', title: 'HManagerID', hide: true }
+ , { field: '涓荤浠g爜', title: '涓荤浠g爜', width: 100}
+ , { field: '涓荤', title: '涓荤', width: 100}
+ , { field: 'HEmpID', title: 'HEmpID', hide: true }
+ , { field: '鎽樿', title: '鎽樿', width: 100}
+ , { field: '琛ㄥご澶囨敞', title: '琛ㄥご澶囨敞', width: 100}
+ , { field: 'hsubid', title: 'hsubid', hide: true }
+ , { field: 'HMaterID', title: 'HMaterID', hide: true }
+ , { field: '鐗╂枡浠g爜', title: '鐗╂枡浠g爜', width: 100}
+ , { field: '鐗╂枡鍚嶇О', title: '鐗╂枡鍚嶇О', width: 100}
+ , { field: '瑙勬牸鍨嬪彿', title: '瑙勬牸鍨嬪彿', width: 100}
+ , { field: '鎵瑰彿', title: '鎵瑰彿', width: 100}
+ , { field: 'HUnitID', title: 'HUnitID', hide: true }
+ , { field: '璁¢噺鍗曚綅浠g爜', title: '璁¢噺鍗曚綅浠g爜', width: 120}
+ , { field: '璁¢噺鍗曚綅', title: '璁¢噺鍗曚綅', width: 100}
+ , { field: '鏁伴噺', title: '鏁伴噺', width: 100}
+ , { field: '鍗曚环', title: '鍗曚环', width: 100}
+ , { field: '閲戦', title: '閲戦', width: 100}
+ , { field: '绋庣巼', title: '绋庣巼', width: 100}
+ , { field: '绋庨', title: '绋庨', width: 100}
+ , { field: '浠风◣鍚堣', title: '浠风◣鍚堣', width: 100}
+ , { field: '浜よ揣鏃ユ湡', title: '浜よ揣鏃ユ湡', width: 120, templet: "<div>{{d.鏃ユ湡 ==null ?'':layui.util.toDateString(d.浜よ揣鏃ユ湡, 'yyyy-MM-dd')}}</div>" }
+ , { field: '婧愬崟鍗曞彿', title: '婧愬崟鍗曞彿', width: 100}
+ , { field: '璁″垝璺熻釜鍙�', title: '璁″垝璺熻釜鍙�', width: 100}
+ , { field: '琛ㄤ綋澶囨敞', title: '琛ㄤ綋澶囨敞', width: 100}
+ , { field: '鍒跺崟浜�', title: '鍒跺崟浜�', width: 100}
+ , { field: '鍒跺崟鏃ユ湡', title: '鍒跺崟鏃ユ湡', width: 120, templet: "<div>{{d.鏃ユ湡 ==null ?'':layui.util.toDateString(d.鍒跺崟鏃ユ湡, 'yyyy-MM-dd')}}</div>" }
+ , { field: '瀹℃牳浜�', title: '瀹℃牳浜�', width: 100}
+ , { field: '瀹℃牳鏃ユ湡', title: '瀹℃牳鏃ユ湡', width: 120, templet: "<div>{{d.鏃ユ湡 ==null ?'':layui.util.toDateString(d.瀹℃牳鏃ユ湡, 'yyyy-MM-dd')}}</div>" }
+ , { field: '淇敼浜�', title: '淇敼浜�', width: 100}
+ , { field: '淇敼鏃ユ湡', title: '淇敼鏃ユ湡', width: 120, templet: "<div>{{d.鏃ユ湡 ==null ?'':layui.util.toDateString(d.淇敼鏃ユ湡, 'yyyy-MM-dd')}}</div>" }
+ , { field: '鍏抽棴浜�', title: '鍏抽棴浜�', width: 100}
+ , { field: '鍏抽棴鏃ユ湡', title: '鍏抽棴鏃ユ湡', width: 120, templet: "<div>{{d.鏃ユ湡 ==null ?'':layui.util.toDateString(d.鍏抽棴鏃ユ湡, 'yyyy-MM-dd')}}</div>" }
+ , { field: '浣滃簾浜�', title: '浣滃簾浜�', width: 100}
+ , { field: '浣滃簾鏃ユ湡', title: '浣滃簾鏃ユ湡', width: 120, templet: "<div>{{d.鏃ユ湡 ==null ?'':layui.util.toDateString(d.浣滃簾鏃ユ湡, 'yyyy-MM-dd')}}</div>" }
+
+ ];
+ option = {
+ elem: '#mainTable'
+ , toolbar: '#toolbarDemo'
+ , page: true
+ , cellMinWidth: 120
+ , totalRow: true
+ , limit: 10
+ , height: 'full-50'
+ , cols: [columns]
+ , limits: [50, 500, 1000, 5000]
+ , done: function (res, curr, count) {
+
+ }
+ };
+ ////璁剧疆鍒楀
+ //var colWidth = getColumnsWidth();
+ //if (colWidth == "" || colWidth == []) {
+
+ //}
+ //else {
+ // $.each(columns, function (x, m) {
+ // m["width"] = colWidth[x];
+ // });
+ //}
+ }
+ //鍔犺浇缃戞牸
+ 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 (HDate1) {
- sWhere += " and 鏃ユ湡 <= '" + HDate1 + "'";
+ if (HEndDate) {
+ sWhere += " and CONVERT(varchar(100),鏃ユ湡, 23) <= '" + HEndDate + "'";
}
- if (WorkCenter) {
- sWhere += " and 鍗曟嵁鍙� like '%" + WorkCenter + "%'";
- }
- var index = layer.load(0, { shade: false });
$.ajax({
url: GetWEBURL() + '/Cg_POOrderBill/list',
type: "GET",
- data: { "sWhere": sWhere },
+ data: { "sWhere": sWhere},
success: function (data1) {
if (data1.count == 1) {
+ DataList = data1.data;
option.data = data1.data;
table.render(option);
- layer.close(index);
- layer.alert("鏌ヨ鎴愬姛", { icon: 1 });
+ layer.close(wait);
} else {
- layer.close(index);
- layer.alert(data1.code + data1.Message, { icon: 5 });
+ layer.close(wait);
+ layer.alert(data1.Message, { icon: 5 });
}
}, error: function () {
- layer.close(index);
+ layer.close(wait);
layer.alert("鎺ュ彛璇锋眰澶辫触!", { icon: 5 });
}
});
- sWhere = "";//璋冪敤鎺ュ彛鍚庢竻绌簊Where缂撳瓨
- });
+ }
+ //鏂板
+ function set_AddNew() {
+ layer.open({
+ type: 2,
+ skin: 'layui-layer-rim', //鍔犱笂杈规
+ title: '鏂板鍣ㄥ叿閲囪喘鍏ュ簱鍗�',
+ closeBtn: 1,
+ shift: 2,
+ area: ['100%', '100%'],
+ maxmin: true,
+ content: '../妯℃不鍏蜂粨搴撶鐞�/Sc_MouldProdInBillEdit.html?OperationType=1&linterid=&HSouceBillType=0&closeType=1',
+ end: function () {
+ //鍒锋柊椤甸潰,
+ get_FastQuery(table, option);
+ },
+ success: function (layero, index) {
+ }
+ });
+ }
+ //缂栬緫鍗曟嵁
+ function set_ShowBill() {
+ var checkStatus = table.checkStatus('mainTable')
+ , data = checkStatus.data;
+ if (checkStatus.data.length === 1) {
+ var linterid = data[0].hmainid.toString();
+ //if (AllowLoadData(sSubStr) != false) {//闈炵┖楠岃瘉
+ layer.open({
+ type: 2
+ , area: ['100%', '100%']
+ , title: '缂栬緫鍣ㄥ叿閲囪喘鍏ュ簱鍗�'
+ , closeBtn: 1
+ , shade: 0.6 //閬僵閫忔槑搴�
+ , maxmin: true //鍏佽鍏ㄥ睆鏈�灏忓寲
+ , anim: 0 //0-6鐨勫姩鐢诲舰寮忥紝-1涓嶅紑鍚�
+ , content: '../妯℃不鍏蜂粨搴撶鐞�/Sc_MouldProdInBillEdit.html?OperationType=3&linterid=' + linterid + '&HSouceBillType=0&closeType=1'
+ , resize: false,
+ end: function () {
+ get_FastQuery(table, option);
+ }
+ , cancel: function () {
+ //$(".layui-btn").removeClass("layui-btn-disabled");
+ }
+ })
+ } else {
+ layer.msg('璇烽�夋嫨涓�琛屾暟鎹紪杈戯紒');
+ }
+ }
+ //鍒犻櫎
+ function set_DeleteBill() {
+ var checkStatus = table.checkStatus('mainTable')
+ , data = checkStatus.data;
+ if (checkStatus.data.length === 1) {
+ var InterID = data[0].hmainid.toString();
+ //閫昏緫鍒犻櫎鏂规硶
+ layer.confirm("纭瑕佸垹闄ゅ悧锛屽垹闄ゅ悗涓嶈兘鎭㈠", { title: "鍒犻櫎纭" }, function (index) {
+ var wait = layer.load();
+ $.ajax({
+ type: "GET",
+ url: GetWEBURL() + "/Sc_MouldProdInBill/set_DeleteBill", //鏂规硶鎵�鍦ㄩ〉闈㈠拰鏂规硶鍚�
+ data: { "HInterID": InterID, "user": sessionStorage["HUserName"] },
+ success: function (result) {
+ if (result.count == 1) {
+ layer.msg(result.Message, { time: 1 * 1000, icon: 1 }, function () {
+ // 寰楀埌frame绱㈠紩
+ var index = layer.getFrameIndex(window.name);
+ //鍏抽棴褰撳墠frame
+ layer.close(index);
+ //淇敼涓哄姛鍚庡埛鏂扮晫闈�
+ window.location.reload();
+ });
+
+ } else {
+ layer.alert(result.code + result.Message, { icon: 5 });
+ }
+ layer.close(wait);
+ }, error: function () {
+ layer.close(wait);
+ layer.alert("鎺ュ彛璇锋眰澶辫触!", { icon: 5 });
+ }
+ });
+ })
+ }
+ else {
+ layer.msg('璇烽�夋嫨涓�琛屾暟鎹垹闄わ紒');
+ }
+ }
+
+ //棰勮
+ function get_ViewReport() {
+ var checkStatus = table.checkStatus('mainTable')
+ , data = checkStatus.data;
+ if (checkStatus.data.length === 1) {
+ layer.open({
+ type: 2
+ , area: ['50%', '50%']
+ , title: '鎵撳嵃妯$増閫夋嫨'
+ , shade: 0.6 //閬僵閫忔槑搴�
+ , maxmin: false //鍏佽鍏ㄥ睆鏈�灏忓寲
+ , anim: 0 //0-6鐨勫姩鐢诲舰寮忥紝-1涓嶅紑鍚�
+ , content: ['../../BaseSet/SRM_OpenTmpList.html?linterid=' + data[0].hmainid.toString() + '&MyMsg=' + data[0].hmainid.toString() + '&Type=HMouldProdInBill', 'yes']
+ , resize: false
+ })
+ }
+ else {
+ layer.msg('璇烽�夋嫨涓�琛屾暟鎹墦鍗帮紒');
+ }
+ }
+
+ //鎵撳嵃
+ function get_PrintReport() {
+ var checkStatus = table.checkStatus('mainTable')
+ , data = checkStatus.data;
+ if (checkStatus.data.length === 1) {
+ layer.open({
+ type: 2
+ , area: ['50%', '50%']
+ , title: '鎵撳嵃妯$増閫夋嫨'
+ , shade: 0.6 //閬僵閫忔槑搴�
+ , maxmin: false //鍏佽鍏ㄥ睆鏈�灏忓寲
+ , anim: 0 //0-6鐨勫姩鐢诲舰寮忥紝-1涓嶅紑鍚�
+ , content: ['../../BaseSet/SRM_OpenTmpList.html?linterid=' + data[0].hmainid.toString() + '&MyMsg=' + data[0].hmainid.toString() + '&Type=HMouldProdInBill', 'yes']
+ , resize: false
+ })
+ }
+ else {
+ layer.msg('璇烽�夋嫨涓�琛屾暟鎹墦鍗帮紒');
+ }
+ }
+
+ //瀹℃牳
+ function set_CheckBill() {
+ var checkStatus = table.checkStatus('mainTable')
+ , data = checkStatus.data;
+ if (checkStatus.data.length === 1) {
+ var InterID = data[0].hmainid.toString();
+ //閫昏緫瀹℃牳鏂规硶
+ var wait = layer.load();
+ $.ajax({
+ type: "GET",
+ url: GetWEBURL() + "/Sc_MouldProdInBill/set_CheckBill", //鏂规硶鎵�鍦ㄩ〉闈㈠拰鏂规硶鍚�
+ data: { "HInterID": InterID, "CurUserName": sessionStorage["HUserName"] },
+ success: function (result) {
+ if (result.count == 1) {
+ layer.msg(result.Message, { time: 1 * 1000, icon: 1 }, function () {
+ // 寰楀埌frame绱㈠紩
+ var index = layer.getFrameIndex(window.name);
+ //鍏抽棴褰撳墠frame
+ layer.close(index);
+ //淇敼涓哄姛鍚庡埛鏂扮晫闈�
+ get_FastQuery(table, option);
+ });
+ } else {
+ layer.alert(result.Message, { icon: 5 });
+ }
+ layer.close(wait);
+ }, error: function () {
+ layer.close(wait);
+ layer.alert("鎺ュ彛璇锋眰澶辫触!", { icon: 5 });
+ }
+ });
+ }
+ else {
+ layer.msg('璇烽�夋嫨涓�琛屾暟鎹鏍革紒');
+ }
+ }
+ //鍙嶅鏍�
+ function set_AbandonCheck() {
+ var checkStatus = table.checkStatus('mainTable')
+ , data = checkStatus.data;
+ if (checkStatus.data.length === 1) {
+ var InterID = data[0].hmainid.toString();
+ //閫昏緫瀹℃牳鏂规硶
+ var wait = layer.load();
+ $.ajax({
+ type: "GET",
+ url: GetWEBURL() + "/Sc_MouldProdInBill/set_AbandonCheck", //鏂规硶鎵�鍦ㄩ〉闈㈠拰鏂规硶鍚�
+ data: { "HInterID": InterID, "CurUserName": sessionStorage["HUserName"] },
+ success: function (result) {
+ if (result.count == 1) {
+ layer.msg(result.Message, { time: 1 * 1000, icon: 1 }, function () {
+ // 寰楀埌frame绱㈠紩
+ var index = layer.getFrameIndex(window.name);
+ //鍏抽棴褰撳墠frame
+ layer.close(index);
+ //淇敼涓哄姛鍚庡埛鏂扮晫闈�
+ get_FastQuery(table, option);
+ });
+
+ } else {
+ layer.alert(result.code + result.Message, { icon: 5 });
+ }
+ layer.close(wait);
+ }, error: function () {
+ layer.close(wait);
+ layer.alert("鎺ュ彛璇锋眰澶辫触!", { icon: 5 });
+ }
+ });
+ }
+ else {
+ layer.msg('璇烽�夋嫨涓�琛屾暟鎹弽瀹℃牳锛�');
+ }
+
+ }
+
+
+ //鑾峰彇鍒楀
+ function getColumnsWidth() {
+ var result = [];
+ var colNum = $(".layui-table-header").find("tr").eq(0).find("th").length;
+ //鑾峰彇鍒楀
+ $.ajax({
+ url: GetWEBURL() + '/Cg_POOrderBill/list',
+ async: false,
+ type: "Get",
+ dataType: "json",
+ data: { "colNum": colNum, "Name": Name },
+ success: function (data1) {
+ if (data1.code == 1) {
+ result = data1.data;
+ }
+ else if (data1.code == -1) {
+
+ }
+ else {
+ layer.alert(data1.Message, { icon: 5 });
+ }
+ }, error: function (e) {
+ layer.alert(e.Message, { icon: 5 });
+ }
+ });
+
+ return result;
+ }
+ //淇濆瓨鍒楀
+ function set_SaveGridColWidth() {
+ var arr = [];
+ // 鍒楁暟
+ var colNum = $(".layui-table-header").find("tr").eq(0).find("th").length;
+ for (var i = 0; i <= colNum; i++) {
+ var colName = $(".layui-table-header").find("tr").eq(0).find("th").eq(i).text();
+ var colWidth = $(".layui-table-header").find("tr").eq(0).find("th").eq(i).width();
+ if (colName != "" && colName != null) {
+ arr.push(colWidth == -1 ? 200 : colWidth);
+ }
+ }
+ arr.unshift(40); //棣栦綅杩藉姞
+ $.ajax({
+ url: GetWEBURL() + '/tb_CellWidth/GetMouldScrapInHouseCellWidth',
+ async: false,
+ type: "POST",
+ dataType: "json",
+ data: { "myMap": JSON.stringify(arr), "Name": Name },
+ success: function (data1) {
+ if (data1.count == 1) {
+ layer.alert(data1.Message, { icon: 1 });
+ } else {
+ layer.alert(data1.Message, { icon: 5 });
+ }
+ }, error: function (e) {
+ layer.alert(e.Message, { icon: 5 });
+ }
+ });
+ //璁剧疆璧嬪�煎垪瀹�
+ var colWidth = getColumnsWidth();
+ if (colWidth == "" || colWidth == []) {
+
+ }
+ else {
+ $.each(columns, function (x, m) {
+ m["width"] = colWidth[x];
+ });
+ }
+ get_FastQuery(table, option);
+ }
+ //榛樿鍒楀
+ function set_DefaultGridColWidth() {
+ var arr = [];
+ // 鍒楁暟
+ var colNum = $(".layui-table-header").find("tr").eq(0).find("th").length;
+ for (var i = 0; i <= colNum; i++) {
+ var colName = $(".layui-table-header").find("tr").eq(0).find("th").eq(i).text();
+ if (colName != "" && colName != null) {
+ arr.push(200); //榛樿瀹藉害200
+ }
+ }
+ arr.unshift(40); //棣栦綅杩藉姞
+ $.ajax({
+ url: GetWEBURL() + '/tb_CellWidth/GetMouldScrapInHouseCellWidth',
+ async: false,
+ type: "POST",
+ dataType: "json",
+ data: { "myMap": JSON.stringify(arr), "Name": Name },
+ success: function (data1) {
+ if (data1.count == 1) {
+ layer.alert(data1.Message, { icon: 1 });
+
+ } else {
+ layer.alert(data1.Message, { icon: 5 });
+ }
+ }, error: function (e) {
+ layer.alert(e.Message, { icon: 5 });
+ }
+ });
+ //璁剧疆璧嬪�煎垪瀹�
+ var colWidth = getColumnsWidth();
+ if (colWidth == "" || colWidth == []) {
+
+ }
+ else {
+ $.each(columns, function (x, m) {
+ m["width"] = colWidth[x];
+ });
+ }
+ get_FastQuery(table, option);
+ }
+
+ //澶嶅埗鍗曟嵁
+ function set_CopyBill() {
+
+ }
+ //鍏抽棴鍗曟嵁
+ function set_CloseBill() {
+
+ }
+ //鍙嶅叧闂崟鎹�
+ function set_CancelCloseBill() {
+
+ }
+ //浣滃簾鍗曟嵁
+ function set_CancelltionBill() {
+
+ }
+ //鍙嶄綔搴�
+ function set_AbandonCancelltion() {
+
+ }
+ //鍒嗛厤
+ function set_Distribut() {
+ var hmainid='';
+ var checkStatus = table.checkStatus('mainTable'),
+ data = checkStatus.data;
+ if (checkStatus.data.length == 0) {
+ //var InterID = data[0].hmainid.toString();
+ return layer.msg('璇烽�夋嫨鏁版嵁');
+ }
+ for (var i = 0; i < data.length; i++) {
+ hmainid += data[i]["hmainid"] + ',';
+ if (data[i]["涓氬姟鐘舵��"] == "宸插彂甯�") {
+ return layer.msg('鍗曟嵁鍙凤細' + data[i]["鍗曟嵁鍙�"]+'宸插彂甯�');
+ }
+ }
+ hmainid = hmainid.substring(0, hmainid.length-1)
+ var HSupplierId='';
+ layer.open({
+ type: 2,
+ skin: 'layui-layer-rim', //鍔犱笂杈规
+ title: '閲囪喘鍛樺垪琛�',
+ closeBtn: 1,
+ shift: 2,
+ area: ['80%', '80%'],
+ maxmin: true,
+ content: ['../../PublicPage/UserInformation.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('璇烽�夋嫨鏁版嵁');
+ }
+ HSupplierId = checkStatus.data[0].HItemID.toString();
+
+ $.ajax({
+ url: GetWEBURL() + '/Cg_POOrderBill/distribut',
+ async: false,
+ type: "GET",
+ dataType: "json",
+ data: { "Hmainid": hmainid, "HSupplierId": HSupplierId },
+ success: function (data1) {
+ if (data1.Message.indexOf("鎴愬姛") > 0) {
+ layer.msg("鍙戝竷鎴愬姛", { time: 3 * 1000, icon: 1 }, function () {
+ var index = layer.getFrameIndex(window.name);
+ //鍏抽棴褰撳墠frame
+ layer.close(index);
+ //淇敼涓哄姛鍚庡埛鏂扮晫闈�
+ window.location.reload();
+ });
+ } else {
+ layer.alert(data1.Message, { icon: 5 });
+ }
+ }, error: function (e) {
+ layer.alert(data1.Message, { icon: 5 });
+ }
+ });
+ layer.close(layer.index); //瀹冭幏鍙栫殑濮嬬粓鏄渶鏂板脊鍑虹殑鏌愪釜灞傦紝鍊兼槸鐢眑ayer鍐呴儴鍔ㄦ�侀�掑璁$畻鐨�
+ }
+ , btn2: function (index, layero) {
+ //鎸夐挳銆愭寜閽簩銆戠殑鍥炶皟
+ //return false 寮�鍚浠g爜鍙姝㈢偣鍑昏鎸夐挳鍏抽棴
+ },
+ end: function () {
+ },
+ success: function (layero, index) {
+
+ }
+ });
+
+
+ }
+ //鍙戝竷
+ function set_Release() {
+ var hmainid = '';
+ var checkStatus = table.checkStatus('mainTable'),
+ data = checkStatus.data;
+ if (checkStatus.data.length == 0) {
+ //var InterID = data[0].hmainid.toString();
+ return layer.msg('璇烽�夋嫨鏁版嵁');
+ }
+ for (var i = 0; i < data.length; i++) {
+ hmainid += data[i]["hmainid"] + ',';
+ if (data[i]["涓氬姟鐘舵��"] == "鏈垎閰�" || data[i]["涓氬姟鐘舵��"] == "" ) {
+ return layer.msg('鍗曟嵁鍙凤細' + data[i]["鍗曟嵁鍙�"] + '鏈垎閰�');
+ }
+ }
+ hmainid = hmainid.substring(0, hmainid.length - 1)
+ $.ajax({
+ url: GetWEBURL() + '/Cg_POOrderBill/release',
+ async: false,
+ type: "GET",
+ dataType: "json",
+ data: { "Hmainid": hmainid},
+ success: function (data1) {
+ if (data1.Message.indexOf("鎴愬姛") > 0) {
+ layer.msg("鍙戝竷鎴愬姛", { time: 1 * 1000, icon: 1 }, function () {
+ //淇敼涓哄姛鍚庡埛鏂扮晫闈�
+ window.location.reload();
+ });
+ } else {
+ layer.alert(data1.Message, { icon: 5 });
+ }
+ }, error: function (e) {
+ layer.alert(data1.Message, { icon: 5 });
+ }
+ });
+ }
+ //蹇�熻繃婊�
+ function get_FastQuery(table, option) {
+ var HStatus = $("select[name='HStatus']").val();//鐘舵��
+ var HBeginDate = $("#HBeginDate").val();//寮�濮嬫棩鏈�
+ var HEndDate = $("#HEndDate").val();//缁撴潫鏃ユ湡
+ var HBillNo = $("#HBillNo").val(); //鍗曟嵁鍙�
+ var HSupID = $("#HSupID").val(); //渚涘簲鍟嗕俊鎭�
+ if (HStatus) {
+ switch (HStatus) {
+ case '-1': //鍏ㄩ儴
+ sWhere += "";
+ break;
+ case '1': //鏈垎閰�
+ sWhere += " and 涓氬姟鐘舵��='鏈垎閰�'";
+ break;
+ case '2': //宸插鏍�
+ sWhere += " and 涓氬姟鐘舵��='宸插垎閰�'";
+ break;
+ case '3': //宸插叧闂�
+ sWhere += " and 涓氬姟鐘舵��='宸插彂甯�'";
+ default:
+
+ }
+ }
+ if (HBeginDate) {
+ sWhere += " and CONVERT(varchar(100),鏃ユ湡, 23) >= '" + HBeginDate + "'";
+ }
+ if (HEndDate) {
+ sWhere += " and CONVERT(varchar(100),鏃ユ湡, 23) <= '" + HEndDate + "'";
+ }
+ if (HBillNo) {
+ sWhere += " and 鍗曟嵁鍙� like '%" + HBillNo + "%'";
+ }
+ if (HSupID) {
+ sWhere += " and HSupID = '" + HSupID + "'";
+ }
+ var index = layer.load(0);
+ get_Display(sWhere);
+ //璋冪敤鎺ュ彛鍚庢竻绌簊Where缂撳瓨
+ sWhere = "";
+ }
+ //閲嶇疆杩囨护鏉′欢
+ function set_ClearQuery() {
+ $('#HStatus').find("option[value='-1']").attr("selected", true);
+ $("#HBeginDate").val(Format(new Date(new Date() - 1000 * 60 * 60 * 24 * 30), "yyyy-MM-dd"));
+ $("#HEndDate").val(Format(new Date(), "yyyy-MM-dd"));
+ $("#HBillNo").val("");
+ $("#HSupName").val("");
+ $("#HSupID").val("");
+ sWhere = "";
+ get_Display(sWhere);
+ }
+ //#endregion
+ //鍒锋柊
+ function set_Refresh() {
+ $("#btnSearch").click();
+ }
+
+ //浠ヤ笂鏄痩ayui妯″潡
});
</script>
</body>
-</html>
+</html>
\ No newline at end of file
diff --git "a/WebTM/views/\351\207\207\350\264\255\347\256\241\347\220\206/\351\207\207\350\264\255\350\256\242\345\215\225/Cg_POOrderBillList1111.html" "b/WebTM/views/\351\207\207\350\264\255\347\256\241\347\220\206/\351\207\207\350\264\255\350\256\242\345\215\225/Cg_POOrderBillList1111.html"
deleted file mode 100644
index 7aae28f..0000000
--- "a/WebTM/views/\351\207\207\350\264\255\347\256\241\347\220\206/\351\207\207\350\264\255\350\256\242\345\215\225/Cg_POOrderBillList1111.html"
+++ /dev/null
@@ -1,780 +0,0 @@
-锘�<!DOCTYPE html>
-<html>
-<head>
- <meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
- <title>閲囪喘璁㈠崟鍒楄〃</title>
- <meta name="renderer" content="webkit">
- <meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1">
- <meta name="viewport" content="width=device-width, initial-scale=1, maximum-scale=1">
- <link rel="stylesheet" href="../../../layuiadmin/layui/css/layui.css" media="all">
- <link rel="stylesheet" href="../../../layuiadmin/style/admin.css" media="all">
- <script src="../../../layuiadmin/layui/layui.js"></script>
- <script src="../../../layuiadmin/layui/layui.js"></script>
- <script src="../../../layuiadmin/Scripts/json2.js"></script>
- <script src="../../../layuiadmin/Scripts/jquery-1.4.1.js"></script>
- <script src="../../../layuiadmin/Scripts/webConfig.js"></script>
- <script src="../../../layuiadmin/PubCustom.js"></script>
- <script src="../../../layuiadmin/zgqCustom/zgqCustom.js"></script>
-</head>
-<body>
- <div class="layui-fluid">
- <div class="layui-col-md12">
- <div class="layui-card" style="padding: 1px">
- <div class="layui-card-body" style="padding: 1px;">
- <form class="layui-form" action="" lay-filter="component-form-group">
- <div class="layui-collapse">
- <div class="layui-colla-item">
- <div class="layui-colla-title layui-inline">
- <div class="layui-inline">
- <span>鏇村</span>
- </div>
- </div>
- <div class="layui-inline">
- <label class="layui-form-label">鐘舵��</label>
- <div class="layui-input-block">
- <select name="HStatus" lay-filter="HStatus" style="width:190px;">
- <option value="-1" selected="selected">鍏ㄩ儴</option>
- <option value="0">鏈鏍�</option>
- <option value="1">宸插鏍�</option>
- <option value="2">宸插叧闂�</option>
- </select>
- </div>
- </div>
- <div class="layui-inline">
- <label class="layui-form-label">寮�濮嬫棩鏈�</label>
- <div class="layui-input-block">
- <input type="date" class="layui-input" id="HBeginDate" style="width:190px;">
- </div>
- </div>
- <div class="layui-inline">
- <label class="layui-form-label">缁撴潫鏃ユ湡</label>
- <div class="layui-input-block">
- <input type="date" class="layui-input" id="HEndDate" style="width:190px;">
- </div>
- </div>
-
- <button class="layui-btn layuiadmin-btn-order" type="button" lay-submit="" lay-filter="btnSearch" id="btnSearch">
- <i class="layui-icon layui-icon-search layuiadmin-button-btn"></i>
- </button>
- <button class="layui-btn layuiadmin-btn-order" type="button" lay-submit="" lay-filter="btnReSearch" id="btnReSearch" style="padding:0 5px">閲嶇疆</button>
- <div class="layui-colla-content">
- <div class="layui-inline">
- <div class="layui-inline">
- <span>鍏朵粬鏉′欢></span>
- </div>
- </div>
- <div class="layui-inline">
- <label class="layui-form-label">鍗曟嵁鍙�</label>
- <div class="layui-input-block">
- <input type="text" class="layui-input" name="HBillNo" id="HBillNo" style="width:190px;">
- </div>
- </div>
- <div class="layui-inline">
- <label class="layui-form-label">閮ㄩ棬淇℃伅</label>
- <div class="layui-input-block">
- <input type="text" class="layui-input" name="HDept" id="HDept" style="width:190px;">
- </div>
- </div>
- </div>
- </div>
- </div>
- <table class="" id="mainTable" lay-filter="mainTable"></table>
- <script type="text/html" id="toolbarDemo">
- <div class="layui-btn-container">
- <!--<button type="button" class="layui-btn layui-btn-sm" lay-event="btn-Add"><i class="layui-icon layui-icon-file-b"></i>鏂板</button>
- <button type="button" class="layui-btn layui-btn-sm" lay-event="btn-Edit"><i class="layui-icon layui-icon-form"></i>缂栬緫</button>
- <button type="button" class="layui-btn layui-btn-sm" lay-event="btn-Delete"><i class="layui-icon layui-icon-delete"></i>鍒犻櫎</button>-->
- <button type="button" class="layui-btn layui-btn-sm" lay-event="btn-fp"><i class="layui-icon layui-icon-tips"></i>鍒嗛厤</button>
- <button type="button" class="layui-btn layui-btn-sm" lay-event="btn-fb"><i class="layui-icon layui-icon-tips"></i>鍙戝竷</button>
-
- <button type="button" class="layui-btn layui-btn-sm" lay-event="btn-view"><i class="layui-icon layui-icon-tips"></i>棰勮</button>
- <button type="button" class="layui-btn layui-btn-sm" lay-event="btn-print"><i class="layui-icon layui-icon-print"></i>鎵撳嵃</button>
- <button type="button" class="layui-btn layui-btn-sm" lay-event="get_Refresh"><i class="layui-icon layui-icon-refresh-3"></i>鍒锋柊</button>
- <button type="button" class="layui-btn layui-btn-sm" lay-event="get_Exit"><i class="layui-icon layui-icon-logout"></i>閫�鍑�</button>
- </div>
- </script>
- </form>
- </div>
- </div>
- </div>
- </div>
- <script type="text/javascript">
- layui.config({
- base: '../../../layuiadmin/' //闈欐�佽祫婧愭墍鍦ㄨ矾寰�
- }).extend({
- index: 'lib/index', //涓诲叆鍙fā鍧�
- }).use(['index', 'form', 'table', 'element', 'laypage', 'laydate'], function () {
- //#region 鍏叡鍙橀噺
- var $ = layui.$
- , admin = layui.admin
- , layer = layui.layer
- , table = layui.table
- , form = layui.form
- , element = layui.element
- , laypage = layui.laypage
- , laydate = layui.laydate
- , util = layui.util
- //鏌ヨ鏉′欢
- var sWhere = "";
- var option = [];
- var Name = "MouldProdInHouseCellWidth";
- //#endregion
-
- //#region 杩涘叆椤甸潰鏃㈠姞杞�
- //鍒濆鍖栬〃鏍�
- set_InitGrid();
- //鍔犺浇鏁版嵁鍒扮綉鏍�
- get_Display(sWhere);
- //#endregion
-
- //#region 鐐瑰嚮浜嬩欢鍖呮嫭on form浜嬩欢绛�
- //澶村伐鍏锋爮浜嬩欢
- table.on('toolbar(mainTable)', function (obj) {
- switch (obj.event) {
- //鏂板鎸夐挳
- case 'btn-Add': set_AddNew();
- break;
- //缂栬緫鎸夐挳
- case 'btn-Edit': set_ShowBill();
- break;
- //鍒犻櫎鎸夐挳
- case 'btn-Delete': set_DeleteBill();
- break;
- //娴忚
- case 'btn-view': get_ViewReport();
- break;
- //鎵撳嵃
- case 'btn-print': get_PrintReport();
- break;
- //鍒锋柊
- case 'get_Refresh': set_Refresh();
- break;
-
- //閫�鍑�
- case 'get_Exit': Pub_Close(2);
- break;
- //鍒嗛厤
- case 'btn-fp': set_Distribut();
- break;
- //鍙戝竷
- case 'btn-fb': set_Release();
- break;
- };
- });
-
-
- //閲嶇疆鎸夐挳
- form.on('submit(btnReSearch)', function (data) {
- set_ClearQuery();
- });
-
- //鏌ヨ鎸夐挳
- form.on('submit(btnSearch)', function (data) {
- get_FastQuery(table, option);
- });
- //#endregion
-
-
- //#region 姝ら〉闈㈡墍鏈夋柟娉�
- //鍒濆鍖栬〃鏍�
- function set_InitGrid() {
- $("#HBeginDate").val(Format(new Date(new Date() - 1000 * 60 * 60 * 24 * 30), "yyyy-MM-dd"));
- $("#HEndDate").val(Format(new Date(), "yyyy-MM-dd"));
- var columns = [
- { type: 'checkbox', fixed: 'left', totalRowText: '鍚堣' }
- ,{ field: 'hmainid', title: 'hmainid', sort: true, hide: true }
- , { field: '鏃ユ湡', title: '鏃ユ湡', width: 120, templet: "<div>{{d.鏃ユ湡 ==null ?'':layui.util.toDateString(d.鏃ユ湡, 'yyyy-MM-dd')}}</div>" }
- , { field: '鍗曟嵁鍙�', title: '鍗曟嵁鍙�', width: 150 }
- , { field: 'HBillType', title: 'HBillType', hide: true }
- , { field: 'HSupID', title: 'HSupID', hide: true }
- , { field: '涓氬姟鐘舵��', title: '涓氬姟鐘舵��', width: 100 }
- , { field: '渚涘簲鍟嗕唬鐮�', title: '渚涘簲鍟嗕唬鐮�', width: 100}
- , { field: '渚涘簲鍟�', title: '渚涘簲鍟�', width: 100 }
- , { field: '涓氬姟鍛樹唬鐮�', title: '涓氬姟鍛樹唬鐮�', width: 100 }
- , { field: '涓氬姟鍛�', title: '涓氬姟鍛�', width: 100 }
- , { field: '浜よ揣鍦扮偣', title: '浜よ揣鍦扮偣', width: 100}
- , { field: 'HPSStyleID', title: 'HPSStyleID', hide: true }
- , { field: '閲囪喘鏂瑰紡浠g爜', title: '閲囪喘鏂瑰紡浠g爜', width: 100}
- , { field: '閲囪喘鏂瑰紡', title: '閲囪喘鏂瑰紡', width: 100}
- , { field: 'HSSID', title: 'HSSID', hide: true }
- , { field: '缁撶畻鏂瑰紡浠g爜', title: '缁撶畻鏂瑰紡浠g爜', width: 100}
- , { field: '缁撶畻鏂瑰紡', title: '缁撶畻鏂瑰紡', width: 100}
- , { field: '缁撶畻鏃ユ湡', title: '缁撶畻鏃ユ湡', width: 120, templet: "<div>{{d.鏃ユ湡 ==null ?'':layui.util.toDateString(d.缁撶畻鏃ユ湡, 'yyyy-MM-dd')}}</div>" }
- , { field: 'HCurID', title: 'HCurID', hide: true }
- , { field: '甯佸埆浠g爜', title: '甯佸埆浠g爜', width: 100}
- , { field: '甯佸埆', title: '甯佸埆', width: 100}
- , { field: '姹囩巼', title: '姹囩巼', width: 100}
- , { field: 'HDeptID', title: 'HDeptID', hide: true }
- , { field: '閮ㄩ棬浠g爜', title: '閮ㄩ棬浠g爜', width: 100}
- , { field: '閮ㄩ棬', title: '閮ㄩ棬', width: 100}
- , { field: 'HManagerID', title: 'HManagerID', hide: true }
- , { field: '涓荤浠g爜', title: '涓荤浠g爜', width: 100}
- , { field: '涓荤', title: '涓荤', width: 100}
- , { field: 'HEmpID', title: 'HEmpID', hide: true }
- , { field: '鎽樿', title: '鎽樿', width: 100}
- , { field: '琛ㄥご澶囨敞', title: '琛ㄥご澶囨敞', width: 100}
- , { field: 'hsubid', title: 'hsubid', hide: true }
- , { field: 'HMaterID', title: 'HMaterID', hide: true }
- , { field: '鐗╂枡浠g爜', title: '鐗╂枡浠g爜', width: 100}
- , { field: '鐗╂枡鍚嶇О', title: '鐗╂枡鍚嶇О', width: 100}
- , { field: '瑙勬牸鍨嬪彿', title: '瑙勬牸鍨嬪彿', width: 100}
- , { field: '鎵瑰彿', title: '鎵瑰彿', width: 100}
- , { field: 'HUnitID', title: 'HUnitID', hide: true }
- , { field: '璁¢噺鍗曚綅浠g爜', title: '璁¢噺鍗曚綅浠g爜', width: 100}
- , { field: '璁¢噺鍗曚綅', title: '璁¢噺鍗曚綅', width: 100}
- , { field: '鏁伴噺', title: '鏁伴噺', width: 100}
- , { field: '鍗曚环', title: '鍗曚环', width: 100}
- , { field: '閲戦', title: '閲戦', width: 100}
- , { field: '绋庣巼', title: '绋庣巼', width: 100}
- , { field: '绋庨', title: '绋庨', width: 100}
- , { field: '浠风◣鍚堣', title: '浠风◣鍚堣', width: 100}
- , { field: '浜よ揣鏃ユ湡', title: '浜よ揣鏃ユ湡', width: 120, templet: "<div>{{d.鏃ユ湡 ==null ?'':layui.util.toDateString(d.浜よ揣鏃ユ湡, 'yyyy-MM-dd')}}</div>" }
- , { field: '婧愬崟鍗曞彿', title: '婧愬崟鍗曞彿', width: 100}
- , { field: '璁″垝璺熻釜鍙�', title: '璁″垝璺熻釜鍙�', width: 100}
- , { field: '琛ㄤ綋澶囨敞', title: '琛ㄤ綋澶囨敞', width: 100}
- , { field: '鍒跺崟浜�', title: '鍒跺崟浜�', width: 100}
- , { field: '鍒跺崟鏃ユ湡', title: '鍒跺崟鏃ユ湡', width: 120, templet: "<div>{{d.鏃ユ湡 ==null ?'':layui.util.toDateString(d.鍒跺崟鏃ユ湡, 'yyyy-MM-dd')}}</div>" }
- , { field: '瀹℃牳浜�', title: '瀹℃牳浜�', width: 100}
- , { field: '瀹℃牳鏃ユ湡', title: '瀹℃牳鏃ユ湡', width: 120, templet: "<div>{{d.鏃ユ湡 ==null ?'':layui.util.toDateString(d.瀹℃牳鏃ユ湡, 'yyyy-MM-dd')}}</div>" }
- , { field: '淇敼浜�', title: '淇敼浜�', width: 100}
- , { field: '淇敼鏃ユ湡', title: '淇敼鏃ユ湡', width: 120, templet: "<div>{{d.鏃ユ湡 ==null ?'':layui.util.toDateString(d.淇敼鏃ユ湡, 'yyyy-MM-dd')}}</div>" }
- , { field: '鍏抽棴浜�', title: '鍏抽棴浜�', width: 100}
- , { field: '鍏抽棴鏃ユ湡', title: '鍏抽棴鏃ユ湡', width: 120, templet: "<div>{{d.鏃ユ湡 ==null ?'':layui.util.toDateString(d.鍏抽棴鏃ユ湡, 'yyyy-MM-dd')}}</div>" }
- , { field: '浣滃簾浜�', title: '浣滃簾浜�', width: 100}
- , { field: '浣滃簾鏃ユ湡', title: '浣滃簾鏃ユ湡', width: 120, templet: "<div>{{d.鏃ユ湡 ==null ?'':layui.util.toDateString(d.浣滃簾鏃ユ湡, 'yyyy-MM-dd')}}</div>" }
-
- ];
- option = {
- elem: '#mainTable'
- , toolbar: '#toolbarDemo'
- , page: true
- , cellMinWidth: 120
- , totalRow: true
- , limit: 10
- , height: 'full-50'
- , cols: [columns]
- , limits: [50, 500, 1000, 5000]
- , done: function (res, curr, count) {
-
- }
- };
- ////璁剧疆鍒楀
- //var colWidth = getColumnsWidth();
- //if (colWidth == "" || colWidth == []) {
-
- //}
- //else {
- // $.each(columns, function (x, m) {
- // m["width"] = colWidth[x];
- // });
- //}
- }
- //鍔犺浇缃戞牸
- 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() + '/Cg_POOrderBill/list',
- type: "GET",
- data: { "sWhere": sWhere},
- success: function (data1) {
- if (data1.count == 1) {
- DataList = data1.data;
- option.data = data1.data;
- table.render(option);
- layer.close(wait);
- } else {
- layer.close(wait);
- layer.alert(data1.Message, { icon: 5 });
- }
- }, error: function () {
- layer.close(wait);
- layer.alert("鎺ュ彛璇锋眰澶辫触!", { icon: 5 });
- }
- });
- }
- //鏂板
- function set_AddNew() {
- layer.open({
- type: 2,
- skin: 'layui-layer-rim', //鍔犱笂杈规
- title: '鏂板鍣ㄥ叿閲囪喘鍏ュ簱鍗�',
- closeBtn: 1,
- shift: 2,
- area: ['100%', '100%'],
- maxmin: true,
- content: '../妯℃不鍏蜂粨搴撶鐞�/Sc_MouldProdInBillEdit.html?OperationType=1&linterid=&HSouceBillType=0&closeType=1',
- end: function () {
- //鍒锋柊椤甸潰,
- get_FastQuery(table, option);
- },
- success: function (layero, index) {
-
- }
- });
- }
- //缂栬緫鍗曟嵁
- function set_ShowBill() {
- var checkStatus = table.checkStatus('mainTable')
- , data = checkStatus.data;
- if (checkStatus.data.length === 1) {
- var linterid = data[0].hmainid.toString();
- //if (AllowLoadData(sSubStr) != false) {//闈炵┖楠岃瘉
- layer.open({
- type: 2
- , area: ['100%', '100%']
- , title: '缂栬緫鍣ㄥ叿閲囪喘鍏ュ簱鍗�'
- , closeBtn: 1
- , shade: 0.6 //閬僵閫忔槑搴�
- , maxmin: true //鍏佽鍏ㄥ睆鏈�灏忓寲
- , anim: 0 //0-6鐨勫姩鐢诲舰寮忥紝-1涓嶅紑鍚�
- , content: '../妯℃不鍏蜂粨搴撶鐞�/Sc_MouldProdInBillEdit.html?OperationType=3&linterid=' + linterid + '&HSouceBillType=0&closeType=1'
- , resize: false,
- end: function () {
- get_FastQuery(table, option);
- }
- , cancel: function () {
- //$(".layui-btn").removeClass("layui-btn-disabled");
- }
- })
- } else {
- layer.msg('璇烽�夋嫨涓�琛屾暟鎹紪杈戯紒');
- }
- }
- //鍒犻櫎
- function set_DeleteBill() {
- var checkStatus = table.checkStatus('mainTable')
- , data = checkStatus.data;
- if (checkStatus.data.length === 1) {
- var InterID = data[0].hmainid.toString();
- //閫昏緫鍒犻櫎鏂规硶
- layer.confirm("纭瑕佸垹闄ゅ悧锛屽垹闄ゅ悗涓嶈兘鎭㈠", { title: "鍒犻櫎纭" }, function (index) {
- var wait = layer.load();
- $.ajax({
- type: "GET",
- url: GetWEBURL() + "/Sc_MouldProdInBill/set_DeleteBill", //鏂规硶鎵�鍦ㄩ〉闈㈠拰鏂规硶鍚�
- data: { "HInterID": InterID, "user": sessionStorage["HUserName"] },
- success: function (result) {
- if (result.count == 1) {
- layer.msg(result.Message, { time: 1 * 1000, icon: 1 }, function () {
- // 寰楀埌frame绱㈠紩
- var index = layer.getFrameIndex(window.name);
- //鍏抽棴褰撳墠frame
- layer.close(index);
- //淇敼涓哄姛鍚庡埛鏂扮晫闈�
- window.location.reload();
- });
-
- } else {
- layer.alert(result.code + result.Message, { icon: 5 });
- }
- layer.close(wait);
- }, error: function () {
- layer.close(wait);
- layer.alert("鎺ュ彛璇锋眰澶辫触!", { icon: 5 });
- }
- });
- })
- }
- else {
- layer.msg('璇烽�夋嫨涓�琛屾暟鎹垹闄わ紒');
- }
- }
-
- //棰勮
- function get_ViewReport() {
- var checkStatus = table.checkStatus('mainTable')
- , data = checkStatus.data;
- if (checkStatus.data.length === 1) {
- layer.open({
- type: 2
- , area: ['50%', '50%']
- , title: '鎵撳嵃妯$増閫夋嫨'
- , shade: 0.6 //閬僵閫忔槑搴�
- , maxmin: false //鍏佽鍏ㄥ睆鏈�灏忓寲
- , anim: 0 //0-6鐨勫姩鐢诲舰寮忥紝-1涓嶅紑鍚�
- , content: ['../../BaseSet/SRM_OpenTmpList.html?linterid=' + data[0].hmainid.toString() + '&MyMsg=' + data[0].hmainid.toString() + '&Type=HMouldProdInBill', 'yes']
- , resize: false
- })
- }
- else {
- layer.msg('璇烽�夋嫨涓�琛屾暟鎹墦鍗帮紒');
- }
- }
-
- //鎵撳嵃
- function get_PrintReport() {
- var checkStatus = table.checkStatus('mainTable')
- , data = checkStatus.data;
- if (checkStatus.data.length === 1) {
- layer.open({
- type: 2
- , area: ['50%', '50%']
- , title: '鎵撳嵃妯$増閫夋嫨'
- , shade: 0.6 //閬僵閫忔槑搴�
- , maxmin: false //鍏佽鍏ㄥ睆鏈�灏忓寲
- , anim: 0 //0-6鐨勫姩鐢诲舰寮忥紝-1涓嶅紑鍚�
- , content: ['../../BaseSet/SRM_OpenTmpList.html?linterid=' + data[0].hmainid.toString() + '&MyMsg=' + data[0].hmainid.toString() + '&Type=HMouldProdInBill', 'yes']
- , resize: false
- })
- }
- else {
- layer.msg('璇烽�夋嫨涓�琛屾暟鎹墦鍗帮紒');
- }
- }
-
- //瀹℃牳
- function set_CheckBill() {
- var checkStatus = table.checkStatus('mainTable')
- , data = checkStatus.data;
- if (checkStatus.data.length === 1) {
- var InterID = data[0].hmainid.toString();
- //閫昏緫瀹℃牳鏂规硶
- var wait = layer.load();
- $.ajax({
- type: "GET",
- url: GetWEBURL() + "/Sc_MouldProdInBill/set_CheckBill", //鏂规硶鎵�鍦ㄩ〉闈㈠拰鏂规硶鍚�
- data: { "HInterID": InterID, "CurUserName": sessionStorage["HUserName"] },
- success: function (result) {
- if (result.count == 1) {
- layer.msg(result.Message, { time: 1 * 1000, icon: 1 }, function () {
- // 寰楀埌frame绱㈠紩
- var index = layer.getFrameIndex(window.name);
- //鍏抽棴褰撳墠frame
- layer.close(index);
- //淇敼涓哄姛鍚庡埛鏂扮晫闈�
- get_FastQuery(table, option);
- });
- } else {
- layer.alert(result.Message, { icon: 5 });
- }
- layer.close(wait);
- }, error: function () {
- layer.close(wait);
- layer.alert("鎺ュ彛璇锋眰澶辫触!", { icon: 5 });
- }
- });
- }
- else {
- layer.msg('璇烽�夋嫨涓�琛屾暟鎹鏍革紒');
- }
- }
- //鍙嶅鏍�
- function set_AbandonCheck() {
- var checkStatus = table.checkStatus('mainTable')
- , data = checkStatus.data;
- if (checkStatus.data.length === 1) {
- var InterID = data[0].hmainid.toString();
- //閫昏緫瀹℃牳鏂规硶
- var wait = layer.load();
- $.ajax({
- type: "GET",
- url: GetWEBURL() + "/Sc_MouldProdInBill/set_AbandonCheck", //鏂规硶鎵�鍦ㄩ〉闈㈠拰鏂规硶鍚�
- data: { "HInterID": InterID, "CurUserName": sessionStorage["HUserName"] },
- success: function (result) {
- if (result.count == 1) {
- layer.msg(result.Message, { time: 1 * 1000, icon: 1 }, function () {
- // 寰楀埌frame绱㈠紩
- var index = layer.getFrameIndex(window.name);
- //鍏抽棴褰撳墠frame
- layer.close(index);
- //淇敼涓哄姛鍚庡埛鏂扮晫闈�
- get_FastQuery(table, option);
- });
-
- } else {
- layer.alert(result.code + result.Message, { icon: 5 });
- }
- layer.close(wait);
- }, error: function () {
- layer.close(wait);
- layer.alert("鎺ュ彛璇锋眰澶辫触!", { icon: 5 });
- }
- });
- }
- else {
- layer.msg('璇烽�夋嫨涓�琛屾暟鎹弽瀹℃牳锛�');
- }
-
- }
-
-
- //鑾峰彇鍒楀
- function getColumnsWidth() {
- var result = [];
- var colNum = $(".layui-table-header").find("tr").eq(0).find("th").length;
- //鑾峰彇鍒楀
- $.ajax({
- url: GetWEBURL() + '/Cg_POOrderBill/list',
- async: false,
- type: "Get",
- dataType: "json",
- data: { "colNum": colNum, "Name": Name },
- success: function (data1) {
- if (data1.code == 1) {
- result = data1.data;
- }
- else if (data1.code == -1) {
-
- }
- else {
- layer.alert(data1.Message, { icon: 5 });
- }
- }, error: function (e) {
- layer.alert(e.Message, { icon: 5 });
- }
- });
-
- return result;
- }
- //淇濆瓨鍒楀
- function set_SaveGridColWidth() {
- var arr = [];
- // 鍒楁暟
- var colNum = $(".layui-table-header").find("tr").eq(0).find("th").length;
- for (var i = 0; i <= colNum; i++) {
- var colName = $(".layui-table-header").find("tr").eq(0).find("th").eq(i).text();
- var colWidth = $(".layui-table-header").find("tr").eq(0).find("th").eq(i).width();
- if (colName != "" && colName != null) {
- arr.push(colWidth == -1 ? 200 : colWidth);
- }
- }
- arr.unshift(40); //棣栦綅杩藉姞
- $.ajax({
- url: GetWEBURL() + '/tb_CellWidth/GetMouldScrapInHouseCellWidth',
- async: false,
- type: "POST",
- dataType: "json",
- data: { "myMap": JSON.stringify(arr), "Name": Name },
- success: function (data1) {
- if (data1.count == 1) {
- layer.alert(data1.Message, { icon: 1 });
- } else {
- layer.alert(data1.Message, { icon: 5 });
- }
- }, error: function (e) {
- layer.alert(e.Message, { icon: 5 });
- }
- });
- //璁剧疆璧嬪�煎垪瀹�
- var colWidth = getColumnsWidth();
- if (colWidth == "" || colWidth == []) {
-
- }
- else {
- $.each(columns, function (x, m) {
- m["width"] = colWidth[x];
- });
- }
- get_FastQuery(table, option);
- }
- //榛樿鍒楀
- function set_DefaultGridColWidth() {
- var arr = [];
- // 鍒楁暟
- var colNum = $(".layui-table-header").find("tr").eq(0).find("th").length;
- for (var i = 0; i <= colNum; i++) {
- var colName = $(".layui-table-header").find("tr").eq(0).find("th").eq(i).text();
- if (colName != "" && colName != null) {
- arr.push(200); //榛樿瀹藉害200
- }
- }
- arr.unshift(40); //棣栦綅杩藉姞
- $.ajax({
- url: GetWEBURL() + '/tb_CellWidth/GetMouldScrapInHouseCellWidth',
- async: false,
- type: "POST",
- dataType: "json",
- data: { "myMap": JSON.stringify(arr), "Name": Name },
- success: function (data1) {
- if (data1.count == 1) {
- layer.alert(data1.Message, { icon: 1 });
-
- } else {
- layer.alert(data1.Message, { icon: 5 });
- }
- }, error: function (e) {
- layer.alert(e.Message, { icon: 5 });
- }
- });
- //璁剧疆璧嬪�煎垪瀹�
- var colWidth = getColumnsWidth();
- if (colWidth == "" || colWidth == []) {
-
- }
- else {
- $.each(columns, function (x, m) {
- m["width"] = colWidth[x];
- });
- }
- get_FastQuery(table, option);
- }
-
- //澶嶅埗鍗曟嵁
- function set_CopyBill() {
-
- }
- //鍏抽棴鍗曟嵁
- function set_CloseBill() {
-
- }
- //鍙嶅叧闂崟鎹�
- function set_CancelCloseBill() {
-
- }
- //浣滃簾鍗曟嵁
- function set_CancelltionBill() {
-
- }
- //鍙嶄綔搴�
- function set_AbandonCancelltion() {
-
- }
- //鍒嗛厤
- function set_Distribut() {
- var hmainid='';
- var checkStatus = table.checkStatus('mainTable'),
- data = checkStatus.data;
- if (checkStatus.data.length == 0) {
- //var InterID = data[0].hmainid.toString();
- return layer.msg('璇烽�夋嫨鏁版嵁');
- }
- for (var i = 0; i < data.length; i++) {
- hmainid += data[i]["hmainid"] + ',';
- if (data[i]["涓氬姟鐘舵��"] == "3") {
- return layer.msg('鍗曟嵁鍙凤細' + data[i]["鍗曟嵁鍙�"]+'宸插彂甯�');
- }
- }
- hmainid = hmainid.substring(0, hmainid.length-1)
- var HSupplierId='';
- layer.open({
- type: 2,
- skin: 'layui-layer-rim', //鍔犱笂杈规
- title: '閲囪喘鍛樺垪琛�',
- closeBtn: 1,
- shift: 2,
- area: ['80%', '80%'],
- maxmin: true,
- content: ['../../PublicPage/UserInformation.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('璇烽�夋嫨鏁版嵁');
- }
- HSupplierId = checkStatus.data[0].HItemID.toString();
-
- $.ajax({
- url: GetWEBURL() + '/Cg_POOrderBill/distribut',
- async: false,
- type: "POST",
- //dataType: "json",
- data: { "Hmainid": hmainid, "HSupplierId": HSupplierId },
- success: function (data1) {
- if (data.Message.indexOf("鎴愬姛") > 0) {
- layer.msg(data.Message, { icon: 1 })
-
- } else {
- layer.alert(data1.Message, { icon: 5 });
- }
- }, error: function (e) {
- layer.alert(e.Message, { icon: 5 });
- }
- });
-
- layer.close(layer.index); //瀹冭幏鍙栫殑濮嬬粓鏄渶鏂板脊鍑虹殑鏌愪釜灞傦紝鍊兼槸鐢眑ayer鍐呴儴鍔ㄦ�侀�掑璁$畻鐨�
- }
- , btn2: function (index, layero) {
- //鎸夐挳銆愭寜閽簩銆戠殑鍥炶皟
- //return false 寮�鍚浠g爜鍙姝㈢偣鍑昏鎸夐挳鍏抽棴
- },
- end: function () {
-
- },
- success: function (layero, index) {
-
- }
- });
-
-
- }
- //鍙戝竷
- function set_Release() {
- var checkStatus = table.checkStatus('mainTable')
- , data = checkStatus.data;
- if (checkStatus.data.length === 1) {
- var InterID = data[0].hmainid.toString();
- }
- }
- //蹇�熻繃婊�
- function get_FastQuery(table, option) {
- var HStatus = $("select[name='HStatus']").val();//鐘舵��
- var HBeginDate = $("#HBeginDate").val();//寮�濮嬫棩鏈�
- var HEndDate = $("#HEndDate").val();//缁撴潫鏃ユ湡
- var HBillNo = $("#HBillNo").val(); //鍗曟嵁鍙�
- var HDept = $("#HDept").val(); //閮ㄩ棬淇℃伅
- if (HStatus) {
- switch (HStatus) {
- case '-1': //鍏ㄩ儴
- sWhere += "";
- break;
- case '0': //鏈鏍�
- sWhere += " and 瀹℃牳浜�=''";
- break;
- case '1': //宸插鏍�
- sWhere += " and 瀹℃牳浜�<>''";
- break;
- case '2': //宸插叧闂�
- sWhere += " and 鍏抽棴浜�<>''";
- default:
-
- }
- }
- if (HBeginDate) {
- sWhere += " and CONVERT(varchar(100),鏃ユ湡, 23) >= '" + HBeginDate + "'";
- }
- if (HEndDate) {
- sWhere += " and CONVERT(varchar(100),鏃ユ湡, 23) <= '" + HEndDate + "'";
- }
- if (HBillNo) {
- sWhere += " and 鍗曟嵁鍙� like '%" + HBillNo + "%'";
- }
- if (HDept) {
- sWhere += " and 閮ㄩ棬鍚嶇О like '%" + HDept + "%'";
- }
- var index = layer.load(0);
- get_Display(sWhere);
- //璋冪敤鎺ュ彛鍚庢竻绌簊Where缂撳瓨
- sWhere = "";
- }
- //閲嶇疆杩囨护鏉′欢
- function set_ClearQuery() {
- $('#HStatus').find("option[value='-1']").attr("selected", true);
- $("#HBeginDate").val(Format(new Date(new Date() - 1000 * 60 * 60 * 24 * 30), "yyyy-MM-dd"));
- $("#HEndDate").val(Format(new Date(), "yyyy-MM-dd"));
- $("#HBillNo").val("");
- $("#HDept").val("");
- sWhere = "";
- get_Display(sWhere);
- }
- //#endregion
- //鍒锋柊
- function set_Refresh() {
- $("#btnSearch").click();
- }
-
- //浠ヤ笂鏄痩ayui妯″潡
- });
- </script>
-</body>
-</html>
\ No newline at end of file
--
Gitblit v1.9.1