智云SRM-LAYUI(夏宝服务器版本)
王 垚
2022-10-08 8196f90ec19a5f4cb881e6e39ba7d255abd31fad
WebSRM/layuiAdmin.std-v1.2.1/src/views/SRM/SRM_POOrderBillList.html
@@ -112,7 +112,6 @@
                                    <label class="layui-form-label">采购组织</label>
                                    <div class="layui-input-block">
                                        <select id="HPURCHASEORGID" name="HPURCHASEORGID" lay-filter="">
                                        </select>
                                    </div>
                                </div>
@@ -243,18 +242,23 @@
                    //{ checkbox: true, fixed: true }
                    { type: 'checkbox', fixed: 'left' }
                    //{ type: 'radio', fixed: true }
                    , { field: 'sorderid', title: '序号', width: 80/*, fixed: true */}
                    , { field: 'sorderid', title: '序号', width: 80/*, fixed: true */ }
                    , { field: 'hmainid', title: 'hmainid', sort: true, /*fixed: true,*/ hide: true }
                    , { field: 'hsubid', title: 'hsubid', sort: true, /*fixed: true,*/ hide: true }
                    , { field: '状态', title: '状态', sort: true/*, fixed: true */}
                    , { field: '反馈状态', title: '反馈状态', width: 100/*, fixed: true */}
                    , { field: '优先级', title: '优先级', width: 100/*, fixed: true */}
                    , { field: '单据号', title: '单据号', width: 180, sort: true/*, fixed: 'left' */}
                    , { field: '日期', title: '日期', width: 180, sort: true/*, fixed: 'left' */}
                    , { field: '状态', title: '状态', sort: true/*, fixed: true */ }
                    //, { field: '反馈状态', title: '反馈状态', width: 100/*, fixed: true */}
                    //, { field: '优先级', title: '优先级', width: 100/*, fixed: true */}
                    , { field: '单据号', title: '单据号', width: 150, sort: true/*, fixed: 'left' */ }
                    , { field: '日期', title: '日期', width: 120, sort: true/*, fixed: 'left' */ }
                    , { field: 'HSupID', title: 'HSupID', width: 180, hide: true }
                    , { field: '供应商', title: '供应商', width: 180, sort: true/*, fixed: 'left' */}
                    , { field: '供应商', title: '供应商', width: 180, sort: true/*, fixed: 'left' */ }
                    , { field: '计划跟踪单号', title: '计划跟踪单号', sort: true, hide: true }
                    , { field: '物料编码', title: '物料编码', width: 120, sort: true }
                    , { field: 'F_xbkf_Combo', title: '自定义标识', width: 120 }
                    , { field: 'FSHDD', title: '送货地点', width: 120 }
                    , { field: 'FStockInQty', title: '累计入库数量', width: 120 }
                    , { field: '包装标识', title: '包装标识', width: 120 }
                    , { field: 'FMRBQTY', title: '累计退料数量', width: 120 }
                    //, { field: '物料编码', title: '物料编码', width: 120, sort: true }
                    , { field: '物料代码', title: '物料代码', width: 120, sort: true }
                    , { field: '物料名称', title: '物料名称', width: 120, sort: true }
                    , { field: '规格型号', title: '规格型号', width: 120, sort: true }
@@ -278,7 +282,7 @@
                //, skin: 'row' //表格风格
                // , even: true
                , page: true //是否显示分页
                , limits: [10, 20, 50, 100]
                , limits: [10, 20, 50, 100,500,1000,5000,10000]
                , limit: 50 //每页默认显示的数量
                //, height: 500
                , done: function (res, curr, count) {
@@ -403,23 +407,39 @@
                            , data = checkStatus.data;
                        ajaxLabelData = data;
                        //根据选中的采购订单,重新从金蝶云同步采购订单关联数量过来。考虑采购订单删除和关闭状态,同步状态
                        var ids = [];
                        var ids = "";
                        var entryids = "";
                        $.each(data, function (obj) {
                            ids.push(data[obj].hmainid);
                            ids += data[obj].hmainid + ",";
                            entryids += data[obj].hsubid + ",";
                        })
                        ids = ids.substring(0, ids.length - 1);
                        entryids = entryids.substring(0, entryids.length - 1);
                        var hasPrivileage = true;
                        $.ajax({
                            url: GetWEBURL() + 'TestSaverPOInStock',
                            type: 'Post',
                            type: 'get',
                            async: false,
                            traditional: true,   // 重点
                            traditional: true,   //重点
                            data: {
                                "": ids      // 重点
                                "ids": ids,
                                "entryids": entryids //重点
                            },
                            success: function (data) {
                                if (data.code == "0") {
                                    layer.alert(data.Message, { icon: 5 });
                                    hasPrivileage = false;
                                    table.reload('mainTable', {
                                        data: ajaxReturnData
                                        , height: 'full-10'
                                        , page: {
                                            curr: _cur_page //必须从第 1 页开始
                                        }
                                        , loading: false
                                        , done: function (index, res) {
                                        }
                                    });
                                    return hasPrivileage;
                                }
                            },
@@ -464,7 +484,7 @@
                            })
                        }
                        break;
                    case 'btn-barcode':
                        var checkStatus = table.checkStatus('mainTable')
                            , data = checkStatus.data;
@@ -634,8 +654,8 @@
                    sqlWhere += " and 规格型号 like ^^%" + $("#HModel").val() + "%^^";
                if ($("#HClStatus").val() != "")
                    sqlWhere += " and 关闭状态 like ^^%" + $("#HClStatus").val() + "%^^";
                if ($("#HPURCHASEORGID").val() != "")
                    sqlWhere += " and 采购组织 like ^^%" + $("#HPURCHASEORGID").val() + "%^^";
                //if ($("#HPURCHASEORGID").val() != "")
                //    sqlWhere += " and 采购组织 like ^^%" + $("#HPURCHASEORGID").val() + "%^^";
                if ($("#HDate1").val() != "") {
                    sqlWhere += " and 日期 >= ^^" + $("#HDate1").val() + "^^";
                }