diff --git a/lc123/cloud/app/plugin/form/ap/ApHandSettleFormPlugin.java b/lc123/cloud/app/plugin/form/ap/ApHandSettleFormPlugin.java index e9d23cf..6cd9504 100644 --- a/lc123/cloud/app/plugin/form/ap/ApHandSettleFormPlugin.java +++ b/lc123/cloud/app/plugin/form/ap/ApHandSettleFormPlugin.java @@ -38,7 +38,9 @@ public class ApHandSettleFormPlugin extends AbstractBillPlugIn implements Plugin bos_org = BusinessDataServiceHelper.loadSingle("bos_org", new QFilter[]{new QFilter("number", QCP.equals, number1)}); this.getModel().setValue("org", bos_org); this.getModel().setValue("asstactvalue", supplier); + this.getModel().setValue("settlerelation", "apself"); + this.getModel().setValue("pagedisplay", "entry"); + } - this.getModel().setValue("settlerelation", "apself"); } } \ No newline at end of file diff --git a/lc123/cloud/app/plugin/form/conm/RebateRulesBillPlugin.java b/lc123/cloud/app/plugin/form/conm/RebateRulesBillPlugin.java index 0e15f91..a84f16d 100644 --- a/lc123/cloud/app/plugin/form/conm/RebateRulesBillPlugin.java +++ b/lc123/cloud/app/plugin/form/conm/RebateRulesBillPlugin.java @@ -39,21 +39,34 @@ public class RebateRulesBillPlugin extends AbstractBillPlugIn implements Plugin // 获取自定义参数 String billno = (String) formShowParameter.getCustomParam("purcontract_billno"); JSONObject purcontract_supplier = formShowParameter.getCustomParam("purcontract_supplier"); + JSONObject purcontract_tqq9_dxpp = formShowParameter.getCustomParam("purcontract_tqq9_dxpp"); DynamicObject supplier = null; + DynamicObject tqq9_dxpp = null; if (purcontract_supplier != null) { String number = purcontract_supplier.get("number").toString(); supplier = BusinessDataServiceHelper.loadSingle("bd_supplier", new QFilter[]{new QFilter("number", QCP.equals, number)}); } + if (purcontract_tqq9_dxpp != null) { + String number = purcontract_tqq9_dxpp.get("number").toString(); + tqq9_dxpp = BusinessDataServiceHelper.loadSingle("tqq9_brand", new QFilter[]{new QFilter("number", QCP.equals, number)}); + } // 把参数值赋值到页面文本字段上 DynamicObject purcontract = BusinessDataServiceHelper.loadSingle("conm_purcontract", new QFilter[]{new QFilter("billno", QCP.equals, billno)}); DynamicObjectCollection tqq9_supplier = this.getModel().getDataEntity().getDynamicObjectCollection("tqq9_supplier"); + DynamicObjectCollection tqq9_rebatebrand = this.getModel().getDataEntity().getDynamicObjectCollection("tqq9_rebatebrand"); DynamicObject newsupplier = new DynamicObject(tqq9_supplier.getDynamicObjectType()); + DynamicObject newbrand = new DynamicObject(tqq9_rebatebrand.getDynamicObjectType()); if (supplier != null) { newsupplier.set("fbasedataId", supplier); tqq9_supplier.add(newsupplier); this.getModel().setValue("tqq9_supplier", tqq9_supplier); } + if (tqq9_dxpp != null) { + newbrand.set("fbasedataId", tqq9_dxpp); + tqq9_rebatebrand.add(newbrand); + this.getModel().setValue("tqq9_rebatebrand", tqq9_rebatebrand); + } this.getModel().setValue("tqq9_conm_purcontract", purcontract); } diff --git a/lc123/cloud/app/plugin/form/conm/purconmAddRebateRulesPlugin.java b/lc123/cloud/app/plugin/form/conm/purconmAddRebateRulesPlugin.java index c1d793d..3d2cb6a 100644 --- a/lc123/cloud/app/plugin/form/conm/purconmAddRebateRulesPlugin.java +++ b/lc123/cloud/app/plugin/form/conm/purconmAddRebateRulesPlugin.java @@ -60,7 +60,8 @@ public class purconmAddRebateRulesPlugin extends AbstractFormPlugin implements P BillShowParameter param = new BillShowParameter(); param.setFormId("tqq9_pur_rebate"); param.setCustomParam("purcontract_billno", this.getModel().getValue("billno")); - param.setCustomParam("purcontract_supplier", (DynamicObject) this.getModel().getValue("supplier")); + param.setCustomParam("purcontract_supplier", this.getModel().getValue("supplier")); + param.setCustomParam("purcontract_tqq9_dxpp", this.getModel().getValue("tqq9_dxpp")); param.setCloseCallBack(new CloseCallBack(this, "entry_rebateSync")); param.getOpenStyle().setShowType(ShowType.Modal); this.getView().showForm(param);