| | |
| | | queryFieldList.add("creator_name"); |
| | | queryFieldList.add("lastmodifier_name"); |
| | | //我们在后台查询业务数据 |
| | | Map<String, String> replaceMap = wrapperReplaceMap( dataGridQuery.getSourceData()); |
| | | Map<String, String> replaceMap = wrapperReplaceMap(dataGridQuery.getSourceData()); |
| | | |
| | | if(dataGridQuery.isLinkTypeFlag()){ |
| | | UILinkTypeDataQuery linkTypeDataQuery = new UILinkTypeDataQuery(); |
| | |
| | | if(treeQuery.getExtandParamsMap() != null){ |
| | | treeQuery.getConditionMap().putAll(treeQuery.getExtandParamsMap()); |
| | | } |
| | | String parentFieldName = treeQuery.getParentFieldName(); |
| | | String parentFieldName = treeQuery.getParentFieldName(); |
| | | if(parentFieldName.contains(",")){ |
| | | parentFieldName = parentFieldName.split(",")[0]; |
| | | } |
| | | //TODO: 这儿为啥要将根节点显示表达式放到查询条件中去,这样就会导致这个节点被当成查询条件去查询 |
| | | if(StringUtils.isNotBlank(parentFieldName)){ |
| | | if(StringUtils.isNotBlank(treeQuery.getParentOid())){ |
| | | treeQuery.getConditionMap().put(parentFieldName,treeQuery.getParentOid()); |
| | |
| | | if(StringUtils.isBlank(parentFieldNameAndValue) || !parentFieldNameAndValue.contains(",")){ |
| | | throw new VciBaseException("配置的信息有误。在没有在菜单或者来源数据设置根节点的查询模板时,请在树的【参照树】上设置上级字段的名称和根节点的查询的值。比如xxxx,yyy。其中xxxx是上级字段英文名称"); |
| | | } |
| | | parentFieldName= parentFieldNameAndValue.split(",")[0]; |
| | | parentFieldName = parentFieldNameAndValue.split(",")[0]; |
| | | String rootQueryValue = parentFieldNameAndValue.split(",")[1]; |
| | | treeQuery.getConditionMap().put(parentFieldName,rootQueryValue); |
| | | replaceMap.put(parentFieldName,rootQueryValue); |
| | |
| | | Map<String,String> cbo2Map = boService.cbo2Map(cbo); |
| | | if(!CollectionUtils.isEmpty(cbo2Map)){ |
| | | cbo2Map.forEach((key,value)->{ |
| | | cloMap.put(parentFieldName + "." + key,value); |
| | | //TODO: 这儿为啥要拼接上parentFieldName,导致后面freemarker表达式无法正确替换 |
| | | cloMap.put(/*parentFieldName + "." +*/ key,value); |
| | | }); |
| | | } |
| | | tree.setOid(getValueByExpressForBOAndLO(cloMap,cbo2Map,valueField)); |