From 71383b569601fe205b1abff2412e0bbd6d220f14 Mon Sep 17 00:00:00 2001
From: 仲国强 <519541279@qq.com>
Date: 星期三, 08 九月 2021 14:30:47 +0800
Subject: [PATCH] 工序检验单列表优化sz
---
WebTM/views/质量管理/工序检验单/QC_ProcessCheckBillList.html | 606 ++++++++++++++++++++++++++++++++++++------------------
1 files changed, 398 insertions(+), 208 deletions(-)
diff --git "a/WebTM/views/\350\264\250\351\207\217\347\256\241\347\220\206/\345\267\245\345\272\217\346\243\200\351\252\214\345\215\225/QC_ProcessCheckBillList.html" "b/WebTM/views/\350\264\250\351\207\217\347\256\241\347\220\206/\345\267\245\345\272\217\346\243\200\351\252\214\345\215\225/QC_ProcessCheckBillList.html"
index 3b2dc44..138f3cd 100644
--- "a/WebTM/views/\350\264\250\351\207\217\347\256\241\347\220\206/\345\267\245\345\272\217\346\243\200\351\252\214\345\215\225/QC_ProcessCheckBillList.html"
+++ "b/WebTM/views/\350\264\250\351\207\217\347\256\241\347\220\206/\345\267\245\345\272\217\346\243\200\351\252\214\345\215\225/QC_ProcessCheckBillList.html"
@@ -1,19 +1,24 @@
锘�<!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 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>
- <style type="text/css">
+ <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">
input.layui-input.layui-unselect {
padding-right: 0;
}
- </style>
+ </style>-->
</head>
<body>
<div class="layui-fluid">
@@ -23,33 +28,47 @@
<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 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="HBillNo" id="HBillNo">
</div>
</div>
-
- <div style="padding: 10px;">
- <button type="button" lay-submit="" class="layui-btn layui-btn-radius" lay-filter="btnReSearch" style="padding:0 5px">閲嶇疆</button>
- <button type="button" lay-submit="" class="layui-btn layui-btn-radius" lay-filter="btndelete" style="padding:0 5px">鍒犻櫎</button>
- <!--<button type="button" lay-submit="" class="layui-btn layui-btn-radius" lay-filter="btnAdd" style="padding:0 5px">鏂板</button>-->
- <button type="button" lay-submit="" class="layui-btn layui-btn-radius" lay-filter="btnModify" style="padding:0 5px">淇敼</button>
- <button type="button" lay-submit="" class="layui-btn layui-btn-radius" lay-filter="btnJY" style="padding:0 5px">绂佺敤</button>
- <button type="button" lay-submit="" class="layui-btn layui-btn-radius" lay-filter="btnFJY" style="padding:0 5px">鍙嶇鐢�</button>
- </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="get_Exit"><i class="layui-icon layui-icon-logout"></i>閫�鍑�</button>
+ </div>
+ </script>
+ <!--<div style="padding: 10px;">
+ <button type="button" lay-submit="" class="layui-btn layui-btn-radius" lay-filter="btnReSearch" style="padding:0 5px">閲嶇疆</button>
+ <button type="button" lay-submit="" class="layui-btn layui-btn-radius" lay-filter="btndelete" style="padding:0 5px">鍒犻櫎</button>-->
+ <!--<button type="button" lay-submit="" class="layui-btn layui-btn-radius" lay-filter="btnAdd" style="padding:0 5px">鏂板</button>-->
+ <!--<button type="button" lay-submit="" class="layui-btn layui-btn-radius" lay-filter="btnModify" style="padding:0 5px">淇敼</button>
+ <button type="button" lay-submit="" class="layui-btn layui-btn-radius" lay-filter="btnJY" style="padding:0 5px">绂佺敤</button>
+ <button type="button" lay-submit="" class="layui-btn layui-btn-radius" lay-filter="btnFJY" style="padding:0 5px">鍙嶇鐢�</button>
+
+ </div>-->
+
</form>
</div>
</div>
</div>
</div>
- <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/Scripts/webConfig.js"></script>-->
<script>
layui.config({
base: '../../../layuiadmin/' //闈欐�佽祫婧愭墍鍦ㄨ矾寰�
@@ -65,219 +84,390 @@
, laypage = layui.laypage
, laydate = layui.laydate
, util = layui.util
+ var option = [];
//鏌ヨ鏉′欢
var sWhere = "";
- var option = {
- elem: '#mainTable'
- //, toolbar: '#toolbarDemo'
- , height: 'full-50'
- , page: true
- , cellMinWidth: 90
- , cols: [[
- { type: 'radio', fixed: 'left' }
- , { field: 'hmainid', title: '鍗曟嵁ID', hide: true }
- , { field: '鏃ユ湡', title: '鏃ユ湡', width: 160 }
- , { field: '鍗曟嵁鍙�', title: '鍗曟嵁鍙�', width: 160 }
- , { field: '琛ㄥご澶囨敞', title: '琛ㄥご澶囨敞', width: 160, hide: true }
- , { field: '鐗╂枡', title: '鐗╂枡', width: 200, hide: true }
- , { field: '鐗╂枡浠g爜', title: '鐗╂枡浠g爜', width: 200 }
- , { field: '鐗╂枡鍚嶇О', title: '鐗╂枡鍚嶇О', width: 200 }
- , { field: '宸ュ簭浠g爜', title: '宸ュ簭浠g爜', width: 200 }
- , { field: '宸ュ簭鍚嶇О', title: '宸ュ簭鍚嶇О', width: 200 }
- , { field: '鐢熶骇璧勬簮浠g爜', title: '鐢熶骇璧勬簮浠g爜', width: 200 }
- , { field: '鐢熶骇璧勬簮', title: '鐢熶骇璧勬簮', width: 200 }
- , { field: '鐢熶骇浜哄憳浠g爜', title: '鐢熶骇浜哄憳浠g爜', width: 160 }
- , { field: '鐢熶骇浜哄憳', title: '鐢熶骇浜哄憳', width: 160 }
- , { field: '妫�楠屽憳浠g爜', title: '妫�楠屽憳浠g爜', width: 160 }
- , { field: '妫�楠屽憳', title: '妫�楠屽憳', width: 200 }
- , { field: '閮ㄩ棬浠g爜', title: '閮ㄩ棬浠g爜', width: 200 }
- , { field: '閮ㄩ棬鍚嶇О', title: '閮ㄩ棬鍚嶇О', width: 200 }
- , { field: '瀹㈡埛浠g爜', title: '瀹㈡埛浠g爜', width: 200 }
- , { field: '瀹㈡埛', title: '瀹㈡埛', width: 200 }
- , { field: '浜у湴浠g爜', title: '浜у湴浠g爜', width: 200 }
- , { field: '浜у湴', title: '浜у湴', width: 200 }
- , { field: '鍔犲伐绫诲瀷浠g爜', title: '鍔犲伐绫诲瀷浠g爜', width: 115 }
- , { field: '鍔犲伐绫诲瀷', title: '鍔犲伐绫诲瀷', width: 115 }
- , { field: '閰嶆柟鍙�', title: '閰嶆柟鍙�', width: 200 }
- , { field: '閰嶆柟鍚嶇О', title: '閰嶆柟鍚嶇О', width: 200 }
- , { field: '鎷変笣鏂瑰悜', title: '鎷変笣鏂瑰悜', width: 115 }
- , { field: '鍖呰鏂瑰紡浠g爜', title: '鍖呰鏂瑰紡浠g爜', width: 200 }
- , { field: '鍖呰鏂瑰紡', title: '鍖呰鏂瑰紡', width: 200 }
- , { field: '鍒跺崟浜�', title: '鍒跺崟浜�', width: 200 }
- , { field: '鍒跺崟鏃ユ湡', title: '鍒跺崟鏃ユ湡', width: 200 }
- , { field: '瀹℃牳浜�', title: '瀹℃牳浜�', width: 115 }
- , { field: '瀹℃牳鏃ユ湡', title: '瀹℃牳鏃ユ湡', width: 200 }
- , { field: '淇敼浜�', title: '淇敼浜�', width: 200 }
- , { field: '淇敼鏃ユ湡', title: '淇敼鏃ユ湡', width: 200 }
- , { field: '鍏抽棴浜�', title: '鍏抽棴浜�', width: 115 }
- , { field: '鍏抽棴鏃ユ湡', title: '鍏抽棴鏃ユ湡', width: 200 }
- , { field: '浣滃簾浜�', title: '浣滃簾浜�', width: 200 }
- , { field: '浣滃簾鏃ユ湡', title: '浣滃簾鏃ユ湡', width: 200 }
- , { field: '鍗曟嵁绫诲瀷', title: '鍗曟嵁绫诲瀷', width: 200 }
- , { field: 'hsubid', title: 'hsubid', width: 115, hide: true }
- ]]
- };
+ //鍒濆鍖栫晫闈�
+ set_ClearBill();
- var index = layer.load(0);
- //杩涘叆椤甸潰鏄剧ず鐨勭紦瀛樺垪琛�
- $.ajax({
- //url: "http://61.130.49.162:9090/WMSAPI///Web/GetMAXNum",
- url: GetWEBURL() + '/QC_ProcessCheckBill/GetProcessCheckBillList',
- type: "GET",
- data: { "sWhere": sWhere},
- success: function (data1) {
- if (data1.count == 1) {
- option.data = data1.data;
- table.render(option);
- layer.close(index);
- } else {
- layer.close(index);
- layer.alert(data1.code + data1.Message, { icon: 5 });
- }
- }, error: function () {
- layer.close(index);
- layer.alert("鎺ュ彛璇锋眰澶辫触!", { icon: 5 });
- }
+ //#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 'get_Exit': Pub_Close(2);
+ break;
+ };
});
+ //#endregion
- //淇敼鎸夐挳
- form.on('submit(btnModify)', function (data) {
- var checkStatus = table.checkStatus('mainTable')
- , data = checkStatus.data;
- layer.open({
- type: 2
- , area: ['100%', '100%']
- , title: '宸ュ簭妫�楠屽崟'
- , shade: 0.6 //閬僵閫忔槑搴�
- , maxmin: false //鍏佽鍏ㄥ睆鏈�灏忓寲
- , anim: 0 //0-6鐨勫姩鐢诲舰寮忥紝-1涓嶅紑鍚�
- , content: ['QC_ProcessCheckBill.html?HInterID=' + data[0].hmainid + '&HType=Modify', 'yes']
- , resize: false
- })
+ //#region 閲嶇疆鎸夐挳
+ form.on('submit(btnReSearch)', function (data) {
+ set_ClearQuery();
});
+ //#endregion
-
- //鍒犻櫎
- form.on('submit(btndelete)', function (obj) {
- //var checkStatus = table.checkStatus('mainTable')
- // , data = checkStatus.data;
- ////console.log(checkStatus.data[0].HBillStatus);
- //if (data.length == 0) {
- // layer.msg("鍏堥�夋嫨瑕佸垹闄よ鍗曟嵁鍚楋紵");
- // return;
- //}
- //if (checkStatus.data[0].HBillStatus == '宸插鏍�') {
- // layer.msg("璇ュ崟鎹凡瀹℃牳鏃犳硶鍒犻櫎锛岃鍏堝弽瀹℃牳锛�");
- // return;
- //}
-
- var data = obj.data //鑾峰緱褰撳墠琛屾暟鎹�
- , layEvent = obj.event; //鑾峰緱 lay-event 瀵瑰簲鐨勫��
- layer.confirm('鎮ㄧ‘瀹氳鍒犻櫎鍚楋紵', {
- btn: ['Yes', 'No'] //鎸夐挳
- , yes: function (index, layero) {
- var checkStatus = table.checkStatus('mainTable');
- var layEvent = checkStatus.event;
- $.ajax({
- //url: GetWEBURL() + '/QC_ProcessCheckBill/Delete_Json',
- url: "http://localhost:12761/QC_ProcessCheckBill/Delete_Json",
- type: "GET",
- //async: true,
- data: { "HItemID": checkStatus.data[0].hmainid},
- success: function (result) {
- if (result.count == 1) {
- $("#btnSearch").click();
- layer.msg(result.Message, { icon: 1 });
-
- }
- else {
- layer.msg(result.Message, { icon: 5 });
- }
- }
- })
-
- //$.ajax({
- // //url: "http://61.130.49.162:9090/WMSAPI///Web/GetMAXNum",
- // url: GetWEBURL() + '/Sc_ProcessMangement/MES_QC_NoPassProdCheckBill_Json',
- // 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 });
- // }
- //});
-
- layer.close(index); //鍏抽棴寮瑰眰
- }
- });
+ //#region 鏌ヨ鎸夐挳
+ form.on('submit(btnSearch)', function (data) {
+ get_FastQuery();
});
+ //#endregion
-
-
- //鏌ヨ鎸夐挳
- form.on('submit(btnSearch)', function (data) {//閫夋嫨浠撲綅
- //var HBillType = $("#HBillType").val();//鍗曟嵁绫诲瀷
- //var HBillNo = $("#HBillNo").val();//鍗曟嵁鍙�
- //var HCreateBy = $("#HCreateBy").val();//鍒跺崟浜�
- //var BenginHCreateDate = $("#BenginHCreateDate").val();//寮�濮嬪埗鍗曟椂闂�
- //var EndHCreateDate = $("#EndHCreateDate").val();//缁撴潫鍒跺崟鏃堕棿
- //if (HBillNo) {
- // sWhere += " and HBillNo like '%" + HBillNo + "%'";
- //}
- //if (HCreateBy) {
- // sWhere += " and HCreateBy like '%" + HCreateBy + "%'";
- //}
- //if (BenginHCreateDate) {
- // sWhere += " and CONVERT(varchar(100),HCreateDate, 23) >= '" + BenginHCreateDate + "'";
- //}
- //if (EndHCreateDate) {
- // sWhere += " and CONVERT(varchar(100),HCreateDate, 23) <= '" + EndHCreateDate + "'";
- //}
- var index = layer.load(0);
+ //#region 鍒濆鍖栫晫闈�
+ function set_ClearBill() {
+ //鍒濆鍖栬〃鏍�
+ set_InitGrid();
+ //鏌ヨ
+ get_Display(sWhere);
+ }
+ //#endregion
+ //#region 鍒濆鍖栬〃鏍兼柟娉�
+ function set_InitGrid() {
+ option = {
+ elem: '#mainTable'
+ , toolbar: '#toolbarDemo'
+ , height: 'full-50'
+ , page: true
+ , cellMinWidth: 90
+ , cols: [[
+ { type: 'checkbox', fixed: 'left' }
+ , { field: '鍗曟嵁ID', title: '鍗曟嵁ID', hide: true }
+ , { field: '鏃ユ湡', title: '鏃ユ湡', width: 160 }
+ , { field: '鍗曟嵁鍙�', title: '鍗曟嵁鍙�', width: 160 }
+ , { field: '琛ㄥご澶囨敞', title: '琛ㄥご澶囨敞', width: 160, hide: true }
+ , { field: '鐗╂枡', title: '鐗╂枡', width: 200, hide: true }
+ , { field: '鐗╂枡浠g爜', title: '鐗╂枡浠g爜', width: 200 }
+ , { field: '鐗╂枡鍚嶇О', title: '鐗╂枡鍚嶇О', width: 200 }
+ , { field: '宸ュ簭浠g爜', title: '宸ュ簭浠g爜', width: 200 }
+ , { field: '宸ュ簭鍚嶇О', title: '宸ュ簭鍚嶇О', width: 200 }
+ , { field: '鐢熶骇璧勬簮浠g爜', title: '鐢熶骇璧勬簮浠g爜', width: 200 }
+ , { field: '鐢熶骇璧勬簮', title: '鐢熶骇璧勬簮', width: 200 }
+ , { field: '鐢熶骇浜哄憳浠g爜', title: '鐢熶骇浜哄憳浠g爜', width: 160 }
+ , { field: '鐢熶骇浜哄憳', title: '鐢熶骇浜哄憳', width: 160 }
+ , { field: '妫�楠屽憳浠g爜', title: '妫�楠屽憳浠g爜', width: 160 }
+ , { field: '妫�楠屽憳', title: '妫�楠屽憳', width: 200 }
+ , { field: '閮ㄩ棬浠g爜', title: '閮ㄩ棬浠g爜', width: 200 }
+ , { field: '閮ㄩ棬鍚嶇О', title: '閮ㄩ棬鍚嶇О', width: 200 }
+ , { field: '瀹㈡埛浠g爜', title: '瀹㈡埛浠g爜', width: 200 }
+ , { field: '瀹㈡埛', title: '瀹㈡埛', width: 200 }
+ , { field: '浜у湴浠g爜', title: '浜у湴浠g爜', width: 200 }
+ , { field: '浜у湴', title: '浜у湴', width: 200 }
+ , { field: '鍔犲伐绫诲瀷浠g爜', title: '鍔犲伐绫诲瀷浠g爜', width: 115 }
+ , { field: '鍔犲伐绫诲瀷', title: '鍔犲伐绫诲瀷', width: 115 }
+ , { field: '閰嶆柟鍙�', title: '閰嶆柟鍙�', width: 200 }
+ , { field: '閰嶆柟鍚嶇О', title: '閰嶆柟鍚嶇О', width: 200 }
+ , { field: '鎷変笣鏂瑰悜', title: '鎷変笣鏂瑰悜', width: 115 }
+ , { field: '鍖呰鏂瑰紡浠g爜', title: '鍖呰鏂瑰紡浠g爜', width: 200 }
+ , { field: '鍖呰鏂瑰紡', title: '鍖呰鏂瑰紡', width: 200 }
+ , { field: '鍒跺崟浜�', title: '鍒跺崟浜�', width: 200 }
+ , { field: '鍒跺崟鏃ユ湡', title: '鍒跺崟鏃ユ湡', width: 200 }
+ , { field: '瀹℃牳浜�', title: '瀹℃牳浜�', width: 115 }
+ , { field: '瀹℃牳鏃ユ湡', title: '瀹℃牳鏃ユ湡', width: 200 }
+ , { field: '淇敼浜�', title: '淇敼浜�', width: 200 }
+ , { field: '淇敼鏃ユ湡', title: '淇敼鏃ユ湡', width: 200 }
+ , { field: '鍏抽棴浜�', title: '鍏抽棴浜�', width: 115 }
+ , { field: '鍏抽棴鏃ユ湡', title: '鍏抽棴鏃ユ湡', width: 200 }
+ , { field: '浣滃簾浜�', title: '浣滃簾浜�', width: 200 }
+ , { field: '浣滃簾鏃ユ湡', title: '浣滃簾鏃ユ湡', width: 200 }
+ , { field: '鍗曟嵁绫诲瀷', title: '鍗曟嵁绫诲瀷', width: 200 }
+ , { field: 'hsubid', title: 'hsubid', width: 115, hide: true }
+ ]]
+ };
+ }
+ //#region 鏌ヨ
+ function get_Display(sWhere) {
+ var ajaxLoad = layer.load();
$.ajax({
//url: "http://61.130.49.162:9090/WMSAPI///Web/GetMAXNum",
- url: GetWEBURL1() + '/QC_ProcessCheckBill/GetProcessCheckBillList',
+ url: GetWEBURL() + '/QC_ProcessCheckBill/GetProcessCheckBillList',
type: "GET",
- data: { "sWhere": sWhere},
+ data: { "sWhere": sWhere },
success: function (data1) {
if (data1.count == 1) {
option.data = data1.data;
table.render(option);
- layer.close(index);
- layer.alert("鏌ヨ鎴愬姛", { icon: 1 });
+ layer.close(ajaxLoad);
+ //layer.alert("鏌ヨ鎴愬姛", { icon: 1 });
} else {
- layer.close(index);
+ layer.close(ajaxLoad);
layer.alert(data1.code + data1.Message, { icon: 5 });
}
}, error: function () {
- layer.close(index);
- layer.alert("鎺ュ彛澶辨晥!", { icon: 5 });
+ layer.close(ajaxLoad);
+ layer.alert("鎺ュ彛璇锋眰澶辫触!", { icon: 5 });
}
});
- //璋冪敤鎺ュ彛鍚庢竻绌簊Where缂撳瓨
- sWhere = "";
- //$("#HBillType").val("");//鍗曟嵁绫诲瀷
- //$("#HBillNo").val("");//鍗曟嵁鍙�
- //$("#HSourceBillNo").val("");//婧愬崟鍙�
- //$("#HCreateBy").val("");//鍒跺崟浜�
- //$("#BenginHCreateDate").val("");//寮�濮嬪埗鍗曟椂闂�
- //$("#EndHCreateDate").val("");//缁撴潫鍒跺崟鏃堕棿
- });
- //鐩戝惉琛屽弻鍑讳簨浠�
- table.on('rowDouble(mainTable)', function (obj) {
- layer.alert("鍙屽嚮浜嬩欢", { icon: 1 });
- });
+ }
+ //#endregion
+
+ ////杩涘叆椤甸潰鏄剧ず鐨勭紦瀛樺垪琛�
+ //$.ajax({
+ // //url: "http://61.130.49.162:9090/WMSAPI///Web/GetMAXNum",
+ // url: GetWEBURL() + '/QC_ProcessCheckBill/GetProcessCheckBillList',
+ // type: "GET",
+ // data: { "sWhere": sWhere},
+ // success: function (data1) {
+ // if (data1.count == 1) {
+ // option.data = data1.data;
+ // table.render(option);
+ // layer.close(index);
+ // } else {
+ // layer.close(index);
+ // layer.alert(data1.code + data1.Message, { icon: 5 });
+ // }
+ // }, error: function () {
+ // layer.close(index);
+ // layer.alert("鎺ュ彛璇锋眰澶辫触!", { icon: 5 });
+ // }
+ //});
+ //#region 蹇�熻繃婊�
+ function get_FastQuery() {
+ var HBillNo = $("#HBillNo").val();//鍗曟嵁鍙�
+
+ get_Display(sWhere);
+ sWhere = "";//璋冪敤鎺ュ彛鍚庢竻绌簊Where缂撳瓨
+ }
+ //#endregion
+
+ //#region 閲嶇疆杩囨护鏉′欢鏂规硶
+ function set_ClearQuery() {
+ $("#HBillNo").val("");
+ sWhere = "";
+ }
+ //#endregion
+
+ //#region 鏂板
+ function set_AddNew() {
+ layer.open({
+ type: 2
+ , skin: 'layui-layer-rim' //鍔犱笂杈规
+ , area: ['100%', '100%']
+ , title: '宸ュ簭妫�楠屽崟-鏂板'
+ , shift: 0//寮瑰嚭鍔ㄧ敾
+ , content: '../宸ュ簭妫�楠屽崟/QC_ProcessCheckBill.html?OperationType=1&linterid=&HSouceBillType='
+ })
+ }
+ //#endregion
+
+ ////淇敼鎸夐挳
+ //form.on('submit(btnModify)', function (data) {
+ // var checkStatus = table.checkStatus('mainTable')
+ // , data = checkStatus.data;
+ // layer.open({
+ // type: 2
+ // , area: ['100%', '100%']
+ // , title: '宸ュ簭妫�楠屽崟'
+ // , shade: 0.6 //閬僵閫忔槑搴�
+ // , maxmin: false //鍏佽鍏ㄥ睆鏈�灏忓寲
+ // , anim: 0 //0-6鐨勫姩鐢诲舰寮忥紝-1涓嶅紑鍚�
+ // , content: ['QC_ProcessCheckBill.html?HInterID=' + data[0].hmainid + '&HType=Modify', 'yes']
+ // , resize: false
+ // })
+ //});
+ //#region 缂栬緫
+ function set_ShowBill() {
+ var checkStatus = table.checkStatus('mainTable')
+ , data = checkStatus.data;
+ if (checkStatus.data.length === 1) {
+ var linterid = data[0].hmainid;
+ //if (AllowLoadData(sSubStr) != false) {//闈炵┖楠岃瘉
+ layer.open({
+ type: 2
+ , area: ['100%', '100%']
+ , title: '宸ュ簭妫�楠屽崟-缂栬緫'
+ , shift: 0//寮瑰嚭鍔ㄧ敾
+ , content: '../宸ュ簭妫�楠屽崟/QC_ProcessCheckBill.html?OperationType=3&linterid=' + linterid + '&HSouceBillType='
+ })
+ } else {
+ layer.msg('璇烽�夋嫨涓�琛屾暟鎹紪杈戯紒');
+ }
+ }
+ //#endregion
+
+ //#region 鍒犻櫎
+ function set_DeleteBill() {
+ var checkStatus = table.checkStatus('mainTable')
+ , data = checkStatus.data;
+ if (checkStatus.data.length === 1) {
+ var ItemID = data[0];
+ layer.confirm("纭瑕佸垹闄ゅ悧锛屽垹闄ゅ悗涓嶈兘鎭㈠", { title: "鍒犻櫎纭" }, function (index) {
+ var wait = layer.load();
+ //閫昏緫鍒犻櫎鏂规硶
+ $.ajax({
+
+ url: GetWEBURL() + '/QC_ProcessCheckBill/Delete_Json',
+ type: "GET",
+ data: { "HItemID": ItemID },
+ success: function (result) {
+ console.log('gouba' + result);
+ if (result.count == 1) {
+ layer.msg(result.Message, { icon: 1 }, function () {
+ // 寰楀埌frame绱㈠紩
+ var index = layer.getFrameIndex(window.name);
+ //鍏抽棴褰撳墠frame
+ layer.close(wait);
+ //淇敼涓哄姛鍚庡埛鏂扮晫闈�
+ window.location.reload();
+ });
+ } else {
+ layer.alert(result.code + result.Message, { icon: 5 });
+ layer.close(wait);
+ }
+ }, error: function () {
+ layer.alert("鎺ュ彛璇锋眰澶辫触!", { icon: 5 });
+ layer.close(wait);
+ }
+ });
+ })
+ }
+ else {
+ layer.msg('璇烽�夋嫨涓�琛屾暟鎹垹闄わ紒');
+ }
+
+ }
+ //#endregion
+
+ ////鍒犻櫎
+ //form.on('submit(set_DeleteBill)', function (obj) {
+ // //var checkStatus = table.checkStatus('mainTable')
+ // // , data = checkStatus.data;
+ // ////console.log(checkStatus.data[0].HBillStatus);
+ // //if (data.length == 0) {
+ // // layer.msg("鍏堥�夋嫨瑕佸垹闄よ鍗曟嵁鍚楋紵");
+ // // return;
+ // //}
+ // //if (checkStatus.data[0].HBillStatus == '宸插鏍�') {
+ // // layer.msg("璇ュ崟鎹凡瀹℃牳鏃犳硶鍒犻櫎锛岃鍏堝弽瀹℃牳锛�");
+ // // return;
+ // //}
+
+ // var data = obj.data //鑾峰緱褰撳墠琛屾暟鎹�
+ // , layEvent = obj.event; //鑾峰緱 lay-event 瀵瑰簲鐨勫��
+ // layer.confirm('鎮ㄧ‘瀹氳鍒犻櫎鍚楋紵', {
+ // btn: ['Yes', 'No'] //鎸夐挳
+ // , yes: function (index, layero) {
+ // var checkStatus = table.checkStatus('mainTable');
+ // var layEvent = checkStatus.event;
+ // $.ajax({
+ // //url: GetWEBURL() + '/QC_ProcessCheckBill/Delete_Json',
+ // url: "http://localhost:12761/QC_ProcessCheckBill/Delete_Json",
+ // type: "GET",
+ // //async: true,
+ // data: { "HItemID": checkStatus.data[0].hmainid},
+ // success: function (result) {
+ // if (result.count == 1) {
+ // $("#btnSearch").click();
+ // layer.msg(result.Message, { icon: 1 });
+
+ // }
+ // else {
+ // layer.msg(result.Message, { icon: 5 });
+ // }
+ // }
+ // })
+
+ // //$.ajax({
+ // // //url: "http://61.130.49.162:9090/WMSAPI///Web/GetMAXNum",
+ // // url: GetWEBURL() + '/Sc_ProcessMangement/MES_QC_NoPassProdCheckBill_Json',
+ // // 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 });
+ // // }
+ // //});
+
+ // layer.close(index); //鍏抽棴寮瑰眰
+ // }
+ // });
+ //});
+
+ //#region 鍒锋柊
+ function get_Refresh() {
+ set_ClearQuery();
+ get_Display(sWhere);
+ }
+ //#endregion
+
+ ////鏌ヨ鎸夐挳
+ //form.on('submit(btnSearch)', function (data) {//閫夋嫨浠撲綅
+ // //var HBillType = $("#HBillType").val();//鍗曟嵁绫诲瀷
+ // //var HBillNo = $("#HBillNo").val();//鍗曟嵁鍙�
+ // //var HCreateBy = $("#HCreateBy").val();//鍒跺崟浜�
+ // //var BenginHCreateDate = $("#BenginHCreateDate").val();//寮�濮嬪埗鍗曟椂闂�
+ // //var EndHCreateDate = $("#EndHCreateDate").val();//缁撴潫鍒跺崟鏃堕棿
+ // //if (HBillNo) {
+ // // sWhere += " and HBillNo like '%" + HBillNo + "%'";
+ // //}
+ // //if (HCreateBy) {
+ // // sWhere += " and HCreateBy like '%" + HCreateBy + "%'";
+ // //}
+ // //if (BenginHCreateDate) {
+ // // sWhere += " and CONVERT(varchar(100),HCreateDate, 23) >= '" + BenginHCreateDate + "'";
+ // //}
+ // //if (EndHCreateDate) {
+ // // sWhere += " and CONVERT(varchar(100),HCreateDate, 23) <= '" + EndHCreateDate + "'";
+ // //}
+ // var index = layer.load(0);
+ // $.ajax({
+ // //url: "http://61.130.49.162:9090/WMSAPI///Web/GetMAXNum",
+ // url: GetWEBURL1() + '/QC_ProcessCheckBill/GetProcessCheckBillList',
+ // type: "GET",
+ // data: { "sWhere": sWhere},
+ // success: function (data1) {
+ // if (data1.count == 1) {
+ // option.data = data1.data;
+ // table.render(option);
+ // layer.close(index);
+ // layer.alert("鏌ヨ鎴愬姛", { icon: 1 });
+ // } else {
+ // layer.close(index);
+ // layer.alert(data1.code + data1.Message, { icon: 5 });
+ // }
+ // }, error: function () {
+ // layer.close(index);
+ // layer.alert("鎺ュ彛澶辨晥!", { icon: 5 });
+ // }
+ // });
+ // //璋冪敤鎺ュ彛鍚庢竻绌簊Where缂撳瓨
+ // sWhere = "";
+ // //$("#HBillType").val("");//鍗曟嵁绫诲瀷
+ // //$("#HBillNo").val("");//鍗曟嵁鍙�
+ // //$("#HSourceBillNo").val("");//婧愬崟鍙�
+ // //$("#HCreateBy").val("");//鍒跺崟浜�
+ // //$("#BenginHCreateDate").val("");//寮�濮嬪埗鍗曟椂闂�
+ // //$("#EndHCreateDate").val("");//缁撴潫鍒跺崟鏃堕棿
+ //});
+
+ ////鐩戝惉琛屽弻鍑讳簨浠�
+ //table.on('rowDouble(mainTable)', function (obj) {
+ // layer.alert("鍙屽嚮浜嬩欢", { icon: 1 });
+ //});
//laydate.render({
--
Gitblit v1.9.1