智云srmLayUi(安瑞和瑞琪)(通用版本)
pzy
2024-09-30 5d3b1302000fb9372fa4f0dfe7f839eb68c3871c
WebSRM/layuiAdmin.std-v1.2.1/src/views/SRM/SRM_POOrderBillList.html
@@ -136,6 +136,14 @@
                                            </select>
                                        </div>
                                    </div>
                                    <div class="layui-inline">
                                        <label class="layui-form-label">供应商名称</label>
                                        <div class="layui-input-block" style="width:130px;">
                                            <input type="text" class="layui-input" name="HSupName" id="HSupName">
                                        </div>
                                    </div>
                                    <div class="layui-inline">
                                        <button class="layui-btn layuiadmin-btn-order" type="button" lay-submit="" lay-filter="btnSearch">
                                            <i class="layui-icon layui-icon-search layuiadmin-button-btn"></i>
@@ -258,7 +266,7 @@
            });
            //不需要显示的字段 可扩展
            var titleData = ["HItemID", "HParentID", "单据号", "日期", "数量", "状态", "单位", "金额"];
            var titleData = ["HItemID", "HParentID", "单位", "金额"];
            var option = [];
            var HModName = "SRM_POOrderBillList";
            var sqlWhere = "";
@@ -568,6 +576,8 @@
                    sqlWhere += " and 旧物料编码 like ^^%" + $("#HOldMaterNumber").val() + "%^^";
                if ($("#HNumber").val() != "")
                    sqlWhere += " and 物料代码 like ^^%" + $("#HNumber").val() + "%^^";
                if ($("#HSupName").val() != "")
                    sqlWhere += " and 供应商 like ^^%" + $("#HSupName").val() + "%^^";
                if ($("#HName").val() != "")
                    sqlWhere += " and 物料名称 like ^^%" + $("#HName").val() + "%^^";
                if ($("#HModel").val() != "")
@@ -805,22 +815,31 @@
                        break;
                    case 'btn-generate':
                        var checkStatus = table.checkStatus('mainTable')
                            , data = checkStatus.data;
                            , data = checkStatus.data;
                        if (data.length == 0) {
                            layer.alert("请选择数据", { icon: 5 });
                            return;
                        }
                        if (data[0].完成状态 == "已完成") {
                            return layer.msg('订单已完成!')
                        }
                        }
                        ajaxLabelData = data;
                        //根据选中的采购订单,重新从金蝶云同步采购订单关联数量过来。考虑采购订单删除和关闭状态,同步状态
                        var ids = "";
                        var entryids = "";
                        var HBillType = data[0].订单类型
                        var HErr = "";
                        $.each(data, function (obj) {
                            ids += data[obj].hmainid + ",";
                            entryids += data[obj].hsubid + ",";
                            if (HBillType != data[obj].订单类型) {
                                HErr += data[obj].订单类型;
                            }
                        })
                        if (HErr != "") {
                            return layer.msg('采购订单订单类型不同,不允许合并下推生成送货单!')
                        }
                        ids = ids.substring(0, ids.length - 1);
                        entryids = entryids.substring(0, entryids.length - 1);
                        var hasPrivileage = true;