| | |
| | | import com.vci.ubcs.starter.web.util.VciDateUtil; |
| | | import com.vci.ubcs.system.entity.DictBiz; |
| | | import com.vci.ubcs.system.feign.IDictBizClient; |
| | | import org.springblade.core.log.exception.ServiceException; |
| | | import com.vci.ubcs.core.log.exception.ServiceException; |
| | | import org.springblade.core.mp.support.Condition; |
| | | import org.springblade.core.mp.support.Query; |
| | | import org.springblade.core.tool.api.R; |
| | |
| | | throw new VciBaseException("{0}{1}属性的时间格式不符合要求",new String[]{codeClassifyTemplateAttrDO.getId(),codeClassifyTemplateAttrDO.getName()}); |
| | | } |
| | | //如果是组合规则,里面使用的属性不能缺失,也都得显示 |
| | | String componentrule = codeClassifyTemplateAttrDTO.getComponentrule(); |
| | | String componentrule = codeClassifyTemplateAttrDTO.getComponentRule(); |
| | | boolean isContainsDynamicParameter = PatternUtil.isContainsDynamicParameter(componentrule); |
| | | if(isContainsDynamicParameter){ |
| | | List<String> userdAttrList = PatternUtil.getKeyListByContent(componentrule);//包含的所有${xxx}中的xxx |
| | |
| | | } |
| | | //要看看表单是否显示 |
| | | String unFormDisplayAttr = userdAttrList.stream().filter(s -> !VciBaseUtil.getBoolean(attrDTOMap.getOrDefault(s.toLowerCase(Locale.ROOT), |
| | | new CodeClassifyTemplateAttrDTO()).getFormdisplayflag())).collect(Collectors.joining(",")); |
| | | new CodeClassifyTemplateAttrDTO()).getFormDisplayFlag())).collect(Collectors.joining(",")); |
| | | if(StringUtils.isNotBlank(unFormDisplayAttr)){ |
| | | throw new VciBaseException("{0}属性是组合规则,但是规则里包含的属性[{1}]在当前模板中没有设置 表单显示 ",new String[]{codeClassifyTemplateAttrDO.getName(),unFormDisplayAttr}); |
| | | } |
| | |
| | | } |
| | | |
| | | if(CLASSIFYTEMPLATEOID==null){ |
| | | CLASSIFYTEMPLATEOID = codeClassifyTemplateAttrDTO.getClassifytemplateoid(); |
| | | CLASSIFYTEMPLATEOID = codeClassifyTemplateAttrDTO.getClassifyTemplateOid(); |
| | | } |
| | | |
| | | } |
| | |
| | | } |
| | | // BatchCBO batchCBOTemplateDelete = new BatchCBO(); |
| | | if(!CollectionUtils.isEmpty(oids)){ |
| | | baseMapper.deleteBatchIds(oids); |
| | | this.removeBatchByIds(oids); |
| | | } |
| | | |
| | | //再新增 |
| | |
| | | } |
| | | |
| | | //判断传过来的参照配置是否是json格式 |
| | | if(StringUtils.isNotBlank(codeClassifyTemplateAttrDTO.getReferbtmid())&&!checkKVObj(codeClassifyTemplateAttrDTO.getReferbtmid())){ |
| | | if(StringUtils.isNotBlank(codeClassifyTemplateAttrDTO.getReferBtmId())&&!checkKVObj(codeClassifyTemplateAttrDTO.getReferBtmId())){ |
| | | throw new VciBaseException("枚举注入数据格式错误!"); |
| | | } |
| | | |