1
wtt
2025-12-08 81d1261b908d586b1d078a5d712fcbefddf1cfbf
WebTM/views/Éú²ú¹ÜÀí/Éú²ú¼Æ»®Æ½Ì¨/JIT_DayPlanPlatForm.html
@@ -26,10 +26,13 @@
                            <button class="layui-btn layui-btn-normal" style="margin-left: 0px" type="button" lay-submit="" lay-filter="btnUnlock" id="btnUnlock">解锁</button>
                            <button class="layui-btn layui-btn-normal" style="margin-left: 0px" type="button" lay-submit="" lay-filter="btnCompleteSetAnalysis" id="btnCompleteSetAnalysis">齐套分析</button>
                            <button class="layui-btn layui-btn-normal" style="margin-left: 0px" type="button" lay-submit="" lay-filter="btnTLYS" id="btnTLYS">提料运算</button>
                            <button class="layui-btn layui-btn-normal" style="margin-left: 0px" type="button" lay-submit="" lay-filter="btnYLYS" id="btnYLYS">要料运算</button>
                            <button class="layui-btn layui-btn-normal" style="margin-left: 0px" type="button" lay-submit="" lay-filter="btnICMOBill" id="btnICMOBill">生产订单选单</button>
                            <button class="layui-btn layui-btn-normal" style="margin-left: 0px" type="button" lay-submit="" lay-filter="btnReady" id="btnReady">准备</button>
                            <button class="layui-btn layui-btn-normal" style="margin-left: 0px" type="button" lay-submit="" lay-filter="btnProPC" id="btnProPC">排产</button>
                            <button class="layui-btn layui-btn-normal" style="margin-left: 0px" type="button" lay-submit="" lay-filter="btnRoutEdit" id="btnRoutEdit">工艺路线</button>
                            <button class="layui-btn layui-btn-normal" style="margin-left: 0px" type="button" lay-submit="" lay-filter="btnLockOrder" id="btnLockOrder">锁定工单</button>
                            <button class="layui-btn layui-btn-normal" style="margin-left: 0px" type="button" lay-submit="" lay-filter="btnUnlockOrder" id="btnUnlockOrder">解锁工单</button>
                        </div>
                        <div class="layui-collapse resizable-container">
                            <div class="layui-colla-item">
@@ -699,6 +702,11 @@
            get_btnTLYS();
        })
        //要料运算
        form.on('submit(btnYLYS)', function (data) {
            get_btnYLYS();
        })
        //生产订单选单
        form.on('submit(btnICMOBill)', function (data) {
            get_btnICMOBill();
@@ -784,6 +792,16 @@
            }
        })
        //锁定工单
        form.on('submit(btnLockOrder)', function (data) {
            get_btnLockOrder();
        })
        //解锁工单
        form.on('submit(btnUnlockOrder)', function (data) {
            get_btnUnlockOrder();
        })
        //#endregion
        //#region æœ¬é¡µé¢è¢«è°ƒç”¨çš„æ‰€æœ‰æ–¹æ³•
@@ -803,9 +821,10 @@
            //初始化表格
            set_InitGrid();
            get_FastQuery(1);
            get_FastQuery_ICMO();//查询带排产订单
            //隐藏勾选字段
            DisPlay_HideColumn();
            get_Display2(sWhere_ICMO);
        }
        //#endregion
@@ -838,7 +857,7 @@
            var oneday = 1000 * 60 * 60 * 24;
            columns.push({ type: 'checkbox', fixed: 'left', sort: true });
            columns.push({ type: 'numbers', title: '序号', sort: true });
            columns.push({ type: 'numbers', field: '序号', title: '序号', sort: true });
            columns.push({ field: '单据号', title: '单据号', hide: true, sort: true });
            columns.push({ field: '销售订单号', title: '销售订单号', width: 150, sort: true });
            columns.push({ field: '生产订单号', title: '生产订单号', width: 150, style: 'background-color: #f9f9f9;', sort: true });
@@ -858,8 +877,7 @@
            columns.push({ field: '昨日数量', title: '昨日数量' });
            columns.push({ field: '优先级', title: '优先级', width: 150, edit: 'text', sort: true });
            columns.push({ field: '生产资源', title: '生产资源', width: 150, edit: 'text', event: "HSourceID" });
            columns.push({ field: '操作工', title: '操作工', width: 150, edit: 'text', event: "HEmpID" });
            columns.push({ field: '使用工装', title: '使用工装', width: 150 });
            columns.push({
                field: Format(myDate.getTime() + 0 * oneday, 'yyyy-MM-dd'), title: Format(myDate.getTime() + 0 * oneday, 'MM.dd'), edit: 'text', width: 70, templet: function (d) {
                    return DayColor(d[Format(myDate.getTime() + 0 * oneday, 'yyyy/MM/dd')], d[Format(myDate.getTime() + 0 * oneday, 'yyyy-MM-dd')], d, Format(myDate.getTime() + 0 * oneday, 'yyyy-MM-dd'));
@@ -1048,12 +1066,15 @@
            columns.push({ field: 'HProdORGID', title: 'HProdORGID', hide: true });
            columns.push({ field: 'HEmpID', title: 'HEmpID', hide: true });
            columns.push({ field: '拆单汇报数量', title: '拆单汇报数量', width: 150, edit: 'text', sort: true });
            columns.push({ field: '锁定工单', title: '锁定工单', width: 150, sort: true, filter: true });//0
            columns.push({ field: 'HMouldID', title: 'HMouldID', width: 150, hide: true });
            columns.push({ field: '操作工', title: '操作工', width: 150, edit: 'text', event: "HEmpID" });
            columns.push({ fixed: 'right', title: '操作', toolbar: '#barDemo' });
            option_columns = columns;
            option = {
                elem: '#mainTable'
                , toolbar: '#toolbarDemo'
                , height: 'full-120'
                , height: 600
                , page: false
                , cellMinWidth: 90
                , cols: [columns]
@@ -1062,14 +1083,16 @@
                    soulTable.render(this);
                    $('.layui-table thead').on('click', 'th', function () {
                        // èŽ·å–ç‚¹å‡»çš„è¡¨å¤´çš„ field å€¼
                        var field = $(this).data('field');
                        set_InitGrid1(field);
                        sWhere = {
                            HORGID: sessionStorage["OrganizationID"]
                            , HBEGINDATE: field
                            , HENDDATE: field
                        }
                        get_Display_3(JSON.stringify(sWhere));
                        var field = $(this).data('field');
                        if (isDateField(field)) {
                            set_InitGrid1(field);
                            sWhere = {
                                HORGID: sessionStorage["OrganizationID"],
                                HBEGINDATE: field,
                                HENDDATE: field
                            };
                            get_Display_3(JSON.stringify(sWhere));
                        }
                    });
                    //res.data.forEach(function (item, index) {
                    //    if (data1.data.DataColor != undefined) {
@@ -1377,7 +1400,7 @@
                , area: ['90%', '90%']//大小
                , title: '生产车间列表'//标题
                , shift: 2//弹出动画
                , content: ['../../基础资料/公用基础资料/Gy_DepartmentList.html', 'yes']
                , content: ['../../基础资料/公用基础资料/Gy_DepartmentList.html?openType=2&HOrgName=' + sessionStorage["Organization"], 'yes']
                , btn: ['确定', '取消']
                , btn1: function (index, layero) {//按钮【按钮一】的回调
                    var iframeWindow = window['layui-layer-iframe' + index]  //获取弹框页面
@@ -1553,7 +1576,10 @@
            }
            if (HICMOBillNo_ICMO) {
                sWhere_ICMO += " and å•据号 like '%" + HICMOBillNo_ICMO + "%'";
            }
            }
            sWhere_ICMO += " and ç”Ÿäº§ç»„织 = '" + sessionStorage["Organization"] +"'";
            sWhere_ICMO += "    Order By æ—¥æœŸ  desc";
            get_Display2(sWhere_ICMO);
            sWhere_ICMO = ""//调用接口后清空sWhere缓存
@@ -1684,6 +1710,34 @@
            });
        }
        //要料运算
        function get_btnYLYS() {
            sWhere = {
                HProdORGID: $("#HProdORGID").val()
                , HWorkShopID: $("#HWorkShopID").val()
            }
            sWhere = JSON.stringify(sWhere);
            var ajaxLoad = layer.load();
            $.ajax({
                url: GetWEBURL() + '/JIT_DayPlanPlatFormBill/JIT_YLYS',
                type: "GET",
                data: { "sWhere": sWhere, "user": sessionStorage["HUserName"] },
                success: function (data1) {
                    if (data1.count == 1) {
                        get_FastQuery(2);
                        layer.msg(data1.Message);
                        layer.close(ajaxLoad);
                    } else {
                        layer.close(ajaxLoad);
                        layer.alert(data1.Message, { icon: 5 });
                    }
                }, error: function () {
                    layer.close(ajaxLoad);
                    layer.alert("接口请求失败!", { icon: 5 });
                }
            });
        }
        //生产订单选单
        function get_btnICMOBill() {
            var HDeptID = $("#HWorkShopID").val() == "" ? 0 : $("#HWorkShopID").val();
@@ -1693,7 +1747,7 @@
                , area: ['90%', '90%']//大小
                , title: '生产订单列表'//标题
                , shift: 2//弹出动画
                , content: ['../../生产管理/生产任务单/Sc_ICMOBillList.html?HDeptID=' + HDeptID, 'yes']
                , content: ['../../生产管理/生产任务单/Sc_ICMOBillList.html?openType =4&HDeptID=' + HDeptID, 'yes']
                , btn: ['确定', '取消']
                , btn1: function (index, layero) {//按钮【按钮一】的回调
                    var iframeWindow = window['layui-layer-iframe' + index]  //获取弹框页面
@@ -1854,6 +1908,7 @@
                    }
                });
            } else {
                layer.close(ajaxLoad); // å…³é—­æŒ‡å®šloading
                return layer.msg("请选择一条数据进行工艺路线编辑");
            }
        }
@@ -1899,6 +1954,7 @@
                }
                HinterID_S.push(option.data[i]["hmainid"]);
            }
            //获取计划锁定的天数
            $.ajax({
                url: GetWEBURL() + '/JIT_DayPlanPlatFormBill/JIT_DayPlanPlatFormBillHinterIDList',
                type: "GET",
@@ -1917,7 +1973,7 @@
            });
            //根据车间删除没有锁定的数据
            var sql = "delete from Sc_WorkBillSortBillSub  where  HMasterDate>=convert(varchar(10) ,DATEADD(DAY," + HPlanDay + ",GETDATE()),20)  and HInterID in(select  HInterID  from Sc_WorkBillSortBillMain where HWorkShopID=" + HWorkShopID + ")";
            var sql = "delete from Sc_WorkBillSortBillSub where HLockedSub != 1 and HInterID in (select HInterID from Sc_WorkBillSortBillMain where HWorkShopID=" + HWorkShopID + " and HLockOrder != 1 )";
            $.ajax({
                url: GetWEBURL() + '/Gy_SOPBillList/UpDelSQL',
                type: "GET",
@@ -1933,10 +1989,11 @@
                    layer.alert("接口请求失败!", { icon: 5 });
                }
            });
            //将表格数据加载到TableData里面
            get_HFData(0, 0);
            //初始化表格数据
            //清空锁定日期以外的数据
            for (var i = 0; i < option.data.length; i++) {
                for (var j = (22 + HPlanDay); j < 53; j++) {
                    if (option.data[i][option.cols[0][j].field] != null) {
@@ -1972,9 +2029,9 @@
                sWorkQty = option.data[i]["小时产能"];
                sYX = option.data[i]["优先级"];
                HReportQty = option.data[i]["拆单汇报数量"];
                //拆单数量减去汇报数量锁定数量
                if (SDSum > 0) {
                    sPlanQty = sPlanQty - SDSum - HReportQty;
                    sPlanQty = sPlanQty - SDSum;
                }
                //剩余需求工时
                iLeftQty = sPlanQty - HReportQty;
@@ -2000,6 +2057,8 @@
                        success: function (data1) {
                            if (data1.count == 1) {
                                ds = data1.data
                                option.data[i]["HMouldID"] = data1.data[0].HMouldID == undefined ? 0 : data1.data[0].HMouldID;
                                option.data[i]["使用工装"] = data1.data[0].使用工装;
                            } else {
                                layer.alert(data1.code + data1.Message, { icon: 5 });
                            }
@@ -2020,6 +2079,8 @@
                        success: function (data1) {
                            if (data1.count == 1) {
                                ds = data1.data
                                option.data[i]["HMouldID"] = data1.data[0].HMouldID == undefined ? 0 : data1.data[0].HMouldID;
                                option.data[i]["使用工装"] = data1.data[0].使用工装;
                            } else {
                                layer.alert(data1.code + data1.Message, { icon: 5 });
                            }
@@ -2472,17 +2533,18 @@
                        //剔除上方排产列表中已经加入的生产订单
                        var tables = [];
                        for (var i = 0; i < option2.data.length; i++) {
                            var temp = option2.data[i]["hmainid"] + "|" + option2.data[i]["HEntryID"];
                            if ($.inArray(temp, compareList) == -1) {
                                tables.push(option2.data[i]);
                        if (option2.data != undefined) {
                            for (var i = 0; i < option2.data.length; i++) {
                                var temp = option2.data[i]["hmainid"] + "|" + option2.data[i]["HEntryID"];
                                if ($.inArray(temp, compareList) == -1) {
                                    tables.push(option2.data[i]);
                                }
                            }
                        }
                        option2.data = tables;
                            option2.data = tables;
                        //重新渲染子表2
                        table.render(option2);
                            //重新渲染子表2
                            table.render(option2);
                        }
                        layer.close(ajaxLoad);
                    } else {
                        layer.close(ajaxLoad);
@@ -3051,6 +3113,80 @@
            }
        }
        //锁定工单
        function get_btnLockOrder() {
            var checkStatus = table.checkStatus('mainTable')
                , data = checkStatus.data;
            if (data.length > 0) {
                var HInterIDArr = [];
                for (var i = 0; i < data.length; i++) {
                    HInterIDArr.push(data[i].hmainid);
                }
                var ajaxLoad = layer.load();
                $.ajax({
                    url: GetWEBURL() + '/JIT_DayPlanPlatFormBill/JIT_DayPlanPlatFormBillHLockedOrder',
                    type: "GET",
                    data: { "HInterIDs": HInterIDArr.toString() },
                    success: function (data1) {
                        if (data1.count == 1) {
                            layer.msg("工单已锁定");
                            get_FastQuery(2);
                            layer.close(ajaxLoad);
                        } else {
                            layer.close(ajaxLoad);
                            layer.alert(data1.code + data1.Message, { icon: 5 });
                        }
                    }, error: function () {
                        layer.close(ajaxLoad);
                        layer.alert("接口请求失败!", { icon: 5 });
                    }
                });
            } else {
                layer.msg('请选择你要锁定的工单!');
            }
        }
        //解锁工单
        function get_btnUnlockOrder() {
            var checkStatus = table.checkStatus('mainTable')
                , data = checkStatus.data;
            if (data.length > 0) {
                var HInterIDArr = [];
                for (var i = 0; i < data.length; i++) {
                    HInterIDArr.push(data[i].hmainid);
                }
                var ajaxLoad = layer.load();
                $.ajax({
                    url: GetWEBURL() + '/JIT_DayPlanPlatFormBill/JIT_DayPlanPlatFormBillHUnlockOrder',
                    type: "GET",
                    data: { "HInterIDs": HInterIDArr.toString() },
                    success: function (data1) {
                        if (data1.count == 1) {
                            layer.msg("工单已解锁");
                            get_FastQuery(2);
                            layer.close(ajaxLoad);
                        } else {
                            layer.close(ajaxLoad);
                            layer.alert(data1.code + data1.Message, { icon: 5 });
                        }
                    }, error: function () {
                        layer.close(ajaxLoad);
                        layer.alert("接口请求失败!", { icon: 5 });
                    }
                });
            } else {
                layer.msg('请选择你要解锁的工单!');
            }
        }
        //查询未排产的生产订单
        function get_Display2(sWhere_ICMO) {
            var ajaxLoad = layer.load();
@@ -3145,6 +3281,7 @@
            var ajaxLoad = layer.load();
            if (checkStatus.data.length != 1) {
                layer.alert("请选择一条数据!");
                layer.close(ajaxLoad);
            } else {
                var TabData = checkStatus.data;
                var HMaterID = TabData[0].HMaterID;
@@ -3311,8 +3448,8 @@
        function get_HideColumn() {
            var colName = "";
            var contentUrl = "";
            for (var i = 1; i < option.cols[0].length - 1; i++) {
                colName += option.cols[0][i]["title"] + ",";
            for (var i = 1; i < option.cols[0].length; i++) {
                colName += option.cols[0][i]["field"] + ",";
            }
            var urlStr = window.document.location.pathname;//获取文件路径
            var urlLen = urlStr.split('/');
@@ -3321,7 +3458,7 @@
            }
            colName = encodeURI(colName.substring(0, colName.length - 1));//对 URI è¿›è¡Œç¼–码
            contentUrl += '基础资料/隐藏列设置/Gy_GridView_Hide.html?HModName=' + HModName + '&colName=' + colName;
            contentUrl += '基础资料/隐藏列设置/Gy_GridView_Hide_New.html?HModName=' + HModName + '&colName=' + colName;
            layer.open({
                type: 2
@@ -3350,71 +3487,82 @@
                data: { "HModName": HModName, "user": sessionStorage["HUserName"] },
                success: function (data1) {
                    if (data1.data.length != 0) {
                        titleData = [];
                        var dataCol = [];//数据库查询出的列数据
                        var titleData = ["单据号", "HProdORGID", "HMaterID", "HUnitID", "HWorkShopID", "HSourceID"];//不需要显示的字段 å¯æ‰©å±•
                        var newCols = [[]];//对应数据库列顺序col
                        newCols[0].push(option.cols[0][0]);//放入第一个checkbox
                        dataCol = data1.data[0].HGridString.split(',');
                        for (var i = 0; i < option.cols[0].length - 2; i++) {
                            if (dataCol[i]) {
                                var dataCols = dataCol[i].split('|');
                            }
                            //隐藏列
                            if (dataCols[1] == 1) {
                                option.cols[0][i + 1]["hide"] = true;
                            }
                            //设置列宽
                            if (dataCols[3] > 0) {
                                option.cols[0][i + 1]["width"] = dataCols[3];
                            }
                            //设置内容字体大小
                            if (data1.data[0].HFontSize != 0) {
                                option.cols[0][i + 1]["style"] += ";font-size:" + data1.data[0].HFontSize + "px;";
                            } else {
                                option.cols[0][i + 1]["style"] += ";font-size:100%";
                            }
                            //设置列宽
                            //if (data1.data[0].HColumnWidth != 0) {
                            //    option.cols[0][i + 1]["width"] = data1.data[0].HColumnWidth + "px;";
                            //} else {
                            //    option.cols[0][i + 1]["width"] = "";
                            //}
                            //显示列
                            if (dataCols[1] == 0 && $.inArray(option.cols[0][i + 1]["title"], titleData) == -1) {
                                option.cols[0][i + 1]["hide"] = false;
                            }
                            //字体所在位置(å·¦ å±…中 å³)
                            switch (dataCols[2]) {
                                case "L":
                                    option.cols[0][i + 1]["align"] = "left";
                                    break;
                                case "M":
                                    option.cols[0][i + 1]["align"] = "center";
                                    break;
                                case "R":
                                    option.cols[0][i + 1]["align"] = "right";
                                    break;
                            }
                        }
                        //取消冻结列
                        for (var i = 1; i < option.cols[0].length - 1; i++) {
                            if (option.cols[0][i]["fixed"] != null) {
                                option.cols[0][i]["fixed"] = null;
                            }
                            else {
                                break;
                            }
                        }
                        //冻结列
                        if (data1.data[0].HFixCols != 0) {
                            for (var i = 0; i < data1.data[0].HFixCols; i++) {
                                if ($.inArray(option.cols[0][i + 1]["title"], titleData) != -1) {
                                    data1.data[0].HFixCols += 1;
                        //列设置列数与页面列数是否一致
                        if (dataCol.length == option.cols[0].length - 1) {
                            //遍历寻找列设置对应列按顺序插入
                            for (var j = 0; j < option.cols[0].length - 1; j++) {
                                for (var i = 0; i < option.cols[0].length - 1; i++) {
                                    var dataCols = dataCol[j].split('|');
                                    //选择与datacols相应列进行修改
                                    if (option.cols[0][i + 1]["field"] == dataCols[5]) {
                                        //隐藏列
                                        if (dataCols[1] == 1) {
                                            option.cols[0][i + 1]["hide"] = true;
                                        }
                                        //设置列宽
                                        if (dataCols[3] > 0) {
                                            option.cols[0][i + 1]["width"] = dataCols[3];
                                        }
                                        //设置内容字体大小
                                        if (data1.data[0].HFontSize != 0) {
                                            option.cols[0][i + 1]["style"] = "font-size:" + data1.data[0].HFontSize + "px;";
                                        } else {
                                            option.cols[0][i + 1]["style"] = "font-size:100%";
                                        }
                                        //显示列
                                        if (dataCols[1] == 0 && $.inArray(option.cols[0][i + 1]["title"], titleData) == -1) {
                                            option.cols[0][i + 1]["hide"] = false;
                                        }
                                        //统计列
                                        if (dataCols[6] == 1) {
                                            option.cols[0][i + 1]["totalRow"] = true;
                                        }
                                        //字体所在位置(å·¦ å±…中 å³)
                                        switch (dataCols[2]) {
                                            case "L":
                                                option.cols[0][i + 1]["align"] = "left";
                                                break;
                                            case "M":
                                                option.cols[0][i + 1]["align"] = "center";
                                                break;
                                            case "R":
                                                option.cols[0][i + 1]["align"] = "right";
                                                break;
                                        }
                                        //设置表格title属性显示别名
                                        if (dataCols[4] != null && dataCols[4] != "") {
                                            option.cols[0][i + 1]["title"] = dataCols[4];
                                        }
                                        newCols[0].push(option.cols[0][i + 1]);
                                    }
                                }
                                option.cols[0][i + 1]["fixed"] = "left";
                            }
                            //遍历循环后判断对应列数是否一致
                            if (dataCol.length == newCols[0].length - 1) {
                                option.cols = newCols;
                                //取消冻结列
                                for (var i = 1; i < option.cols[0].length - 1; i++) {
                                    if (option.cols[0][i]["fixed"] != null) {
                                        option.cols[0][i]["fixed"] = null;
                                    }
                                    else {
                                        break;
                                    }
                                }
                                //冻结列
                                if (data1.data[0].HFixCols != 0) {
                                    for (var i = 0; i < data1.data[0].HFixCols; i++) {
                                        if ($.inArray(option.cols[0][i + 1]["title"], titleData) != -1) {
                                            data1.data[0].HFixCols += 1;
                                        }
                                        option.cols[0][i + 1]["fixed"] = "left";
                                    }
                                }
                            }
                        }
                        table.render(option);
@@ -3644,6 +3792,45 @@
            })
        }
        // åˆ¤æ–­è¡¨å¤´æ ‡é¢˜æ˜¯å¦ä¸ºæ—¥æœŸæ ¼å¼
        function isDateField(field) {
            // æ£€æŸ¥æ—¥æœŸæ ¼å¼
            var datePatterns = [
                /^\d{4}-\d{2}-\d{2}$/,           // YYYY-MM-DD
                /^\d{4}\/\d{2}\/\d{2}$/,         // YYYY/MM/DD
                /^\d{2}-\d{2}-\d{4}$/,           // DD-MM-YYYY
                /^\d{2}\/\d{2}\/\d{4}$/,         // DD/MM/YYYY
                /^\d{4}-\d{2}-\d{2} \d{2}:\d{2}:\d{2}$/, // YYYY-MM-DD HH:mm:ss
                /^\d{4}å¹´\d{2}月\d{2}日$/        // ä¸­æ–‡æ—¥æœŸ
            ];
            return datePatterns.some(pattern => pattern.test(field));
        }
        //页面排序
        table.on('sort(mainTable)', function (obj) { //注:sort æ˜¯å·¥å…·æ¡äº‹ä»¶åï¼Œtest æ˜¯ table åŽŸå§‹å®¹å™¨çš„å±žæ€§ lay-filter="对应的值"
            table.reload('mainTable', {
                initSort: obj //记录初始排序,如果不设的话,将无法标记表头的排序状态。 layui 2.1.1 æ–°å¢žå‚æ•°
                , where: { //请求参数(注意:这里面的参数可任意定义,并非下面固定的格式)
                    field: obj.field //排序字段   åœ¨æŽ¥å£ä½œä¸ºå‚数字段  field order
                    , order: obj.type //排序方式   åœ¨æŽ¥å£ä½œä¸ºå‚数字段  field order
                }
            });
            option.data = layui.table.cache["mainTable"];
            table.render(option);
        });
        table.on('sort(mainTable_ICMO)', function (obj) { //注:sort æ˜¯å·¥å…·æ¡äº‹ä»¶åï¼Œtest æ˜¯ table åŽŸå§‹å®¹å™¨çš„å±žæ€§ lay-filter="对应的值"
            table.reload('mainTable_ICMO', {
                initSort: obj //记录初始排序,如果不设的话,将无法标记表头的排序状态。 layui 2.1.1 æ–°å¢žå‚æ•°
                , where: { //请求参数(注意:这里面的参数可任意定义,并非下面固定的格式)
                    field: obj.field //排序字段   åœ¨æŽ¥å£ä½œä¸ºå‚数字段  field order
                    , order: obj.type //排序方式   åœ¨æŽ¥å£ä½œä¸ºå‚数字段  field order
                }
            });
            option2.data = layui.table.cache["mainTable_ICMO"];
            table.render(option);
        });
        //列明显示下拉框
        function ColFilter() {
            var Organization = '<option  value="0" selected="selected" ></option>';