资源清单过滤
This commit is contained in:
parent
2d22fd11a1
commit
e0c6e8ab2e
|
@ -60,7 +60,7 @@ public class ContractFilterPlugin extends AbstractBillPlugIn implements Plugin,
|
|||
//设置F7列表左树的过滤条件
|
||||
showParameter.getTreeFilterParameter().getQFilters().add(treeFilter);
|
||||
} else if (name1.equals("treeresourceitem")) {
|
||||
FormShowParameter showParameter = beforeF7SelectEvent.getFormShowParameter();
|
||||
ListShowParameter showParameter =(ListShowParameter) beforeF7SelectEvent.getFormShowParameter();
|
||||
Object contType = this.getModel().getValue("contracttype");
|
||||
if(contType!=null){
|
||||
DynamicObject contractType = (DynamicObject)contType;
|
||||
|
|
|
@ -10,12 +10,21 @@ public class ResourceFilterExtPlugin extends ResourceFilterPlugin {
|
|||
@Override
|
||||
public void afterBindData(EventObject e) {
|
||||
super.afterBindData(e);
|
||||
FormShowParameter formShowParameter = this.getView().getParentView().getFormShowParameter();
|
||||
FormShowParameter formShowParameter = this.getView().getFormShowParameter();
|
||||
Map<String, Object> customParams = formShowParameter.getCustomParams();
|
||||
FormShowParameter formShowParameter1 = this.getView().getParentView().getParentView().getFormShowParameter();
|
||||
Map<String, Object> customParams1 = formShowParameter.getCustomParams();
|
||||
|
||||
// customParams.get("contractType")
|
||||
Object contractType = customParams.get("contractType");
|
||||
if (contractType != null) {
|
||||
if (contractType.toString().equals("wzcg")) {//物资采购
|
||||
this.getView().setVisible(true, new String[]{"flexpanelmaterial"});
|
||||
this.getView().setVisible(false, new String[]{"flexpanelsub", "flexpanellabour", "flexpanelcomposite", "flexpanelequipment", "flexpanelturnover","flexpanelother"});
|
||||
} else if (contractType.toString().equals("sbcg")) {//设备采购
|
||||
this.getView().setVisible(true, new String[]{"flexpanelequipment"});
|
||||
this.getView().setVisible(false, new String[]{"flexpanelsub", "flexpanellabour", "flexpanelcomposite", "flexpanelmaterial", "flexpanelturnover","flexpanelother"});
|
||||
}else if (contractType.toString().equals("qtcc") || contractType.toString().equals("lwlcc")) {//产出物
|
||||
this.getView().setVisible(true, new String[]{"flexpanelturnover"});
|
||||
this.getView().setVisible(false, new String[]{"flexpanelsub", "flexpanellabour", "flexpanelcomposite", "flexpanelequipment", "flexpanelmaterial","flexpanelother"});
|
||||
}
|
||||
}
|
||||
System.out.println();
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue