From 0b8990b4a3cfa8126287a594f0d3810ec97b2e15 Mon Sep 17 00:00:00 2001
From: wangting <675591594@qq.com>
Date: 星期五, 14 七月 2023 16:00:08 +0800
Subject: [PATCH] 弹窗展示
---
Source/UBCS/ubcs-service/ubcs-code/src/main/java/com/vci/ubcs/code/service/impl/MdmIOServiceImpl.java | 55 +++++++++++++++++++++++++++++++------------------------
1 files changed, 31 insertions(+), 24 deletions(-)
diff --git a/Source/UBCS/ubcs-service/ubcs-code/src/main/java/com/vci/ubcs/code/service/impl/MdmIOServiceImpl.java b/Source/UBCS/ubcs-service/ubcs-code/src/main/java/com/vci/ubcs/code/service/impl/MdmIOServiceImpl.java
index dca96e7..5cfa714 100644
--- a/Source/UBCS/ubcs-service/ubcs-code/src/main/java/com/vci/ubcs/code/service/impl/MdmIOServiceImpl.java
+++ b/Source/UBCS/ubcs-service/ubcs-code/src/main/java/com/vci/ubcs/code/service/impl/MdmIOServiceImpl.java
@@ -51,6 +51,7 @@
import org.apache.poi.ss.usermodel.Font;
import org.apache.poi.ss.usermodel.RichTextString;
import org.apache.poi.ss.usermodel.Workbook;
+import org.springblade.core.cache.utils.CacheUtil;
import org.springblade.core.redis.cache.BladeRedis;
import org.springblade.core.tool.api.R;
import org.springframework.beans.BeanUtils;
@@ -360,16 +361,23 @@
//鍙傜収鐨勮嚜琛岃緭鍏ュ悕绉�
//鍒嗙被娉ㄥ叆鐨勪笉鐢紝閮芥槸瀵煎叆鍚庤嚜鍔ㄥ鐞嗙殑
//缂栫爜锛岀姸鎬佺瓑瀛楁涓嶅鍏�
- List<CodeClassifyTemplateAttrVO> templateAttrVOS = codeClassifyTemplateVO.getAttributes().stream().filter(s ->
+ List<CodeClassifyTemplateAttrVO> codeClassifyTemplateAttrVOList=codeClassifyTemplateVO.getAttributes();
+ if(!CollectionUtils.isEmpty(codeClassifyTemplateAttrVOList)) {
+ if (CollectionUtils.isEmpty(codeClassifyTemplateAttrVOList)) {
+ throw new VciBaseException("妯℃澘娌℃湁閰嶇疆灞炴��");
+ }
+ }
+ List<CodeClassifyTemplateAttrVO> templateAttrVOS = codeClassifyTemplateAttrVOList.stream().filter(s ->
!DEFAULT_ATTR_LIST.contains(s.getId())
&& StringUtils.isBlank(s.getComponentRule())
&& StringUtils.isBlank(s.getClassifyInvokeAttr())
&& (isHistory || VciBaseUtil.getBoolean(s.getFormDisplayFlag()))
).collect(Collectors.toList());
- if(CollectionUtils.isEmpty(templateAttrVOS)){
- throw new VciBaseException("妯℃澘娌℃湁閰嶇疆浠讳綍銆愯〃鍗曟樉绀恒�戜负銆愭槸銆戠殑灞炴��");
- }
+ if (CollectionUtils.isEmpty(templateAttrVOS)) {
+ throw new VciBaseException("妯℃澘娌℃湁閰嶇疆浠讳綍銆愯〃鍗曟樉绀恒�戜负銆愭槸銆戠殑灞炴��");
+ }
+
List<CodeClassifyTemplateAttrVO> idAttrVOList = codeClassifyTemplateVO.getAttributes().stream().filter(s -> s.getId().equalsIgnoreCase(CODE_FIELD)).collect(Collectors.toList());
LinkedList<WriteExcelData> excelDataList = new LinkedList<>();
Workbook workbook = new HSSFWorkbook();
@@ -672,7 +680,7 @@
//鐩镐技鏍¢獙
Map<String,String>resembleMap=new HashMap<>();
List<DataResembleVO> dataResembleVOS=new ArrayList<>();
- String btmtypeid= classifyFullInfo.getTopClassifyVO().getBtmtypeid();
+ String btmtypeid= classifyFullInfo.getTopClassifyVO().getBtmTypeId();
bathcResembleQuery(codeClassifyOid,templateVO,needSaveCboList,resembleMap,btmtypeid,dataResembleVOS);
if(resembleMap.size()>0) {
if(!CollectionUtils.isEmpty(dataResembleVOS)) {
@@ -972,7 +980,7 @@
//鐩镐技鏍¢獙
Map<String, String> resembleMap = new HashMap<>();
List<DataResembleVO> dataResembleVOS = new ArrayList<>();
- String btmtypeid = classifyFullInfo.getTopClassifyVO().getBtmtypeid();
+ String btmtypeid = classifyFullInfo.getTopClassifyVO().getBtmTypeId();
bathcResembleQuery(templateVO.getCodeclassifyoid(), templateVO, needSaveCboList, resembleMap, btmtypeid, dataResembleVOS);
if (resembleMap.size() > 0) {
if (!CollectionUtils.isEmpty(dataResembleVOS)) {
@@ -1312,7 +1320,7 @@
//鐩镐技鏍¢獙
Map<String,String>resembleMap=new HashMap<>();
List<DataResembleVO> dataResembleVOS=new ArrayList<>();
- String btmtypeid= classifyFullInfo.getTopClassifyVO().getBtmtypeid();
+ String btmtypeid= classifyFullInfo.getTopClassifyVO().getBtmTypeId();
bathcResembleQuery(orderDTO.getCodeClassifyOid(),templateVO,needSaveCboList,resembleMap,btmtypeid,dataResembleVOS);
if(resembleMap.size()>0) {
isCreateUUid=true;
@@ -1376,8 +1384,7 @@
public List<CodeImportTemplateVO> gridclassifys(String redisOid) {
List<CodeImportTemplateVO> codeImportTemplateVOs=new ArrayList<>();
VciBaseUtil.alertNotNull(redisOid,"鍒嗙被",redisOid,"鍒嗙被缂撳瓨涓婚敭");
-
- List<CodeImportTemplateVO> redisServiceCacheObjects=bladeRedis.lRange(redisOid,0,-1);
+ List<CodeImportTemplateVO> redisServiceCacheObjects=bladeRedis.get(redisOid);
if(redisServiceCacheObjects!=null){
codeImportTemplateVOs= redisServiceCacheObjects;
}
@@ -1393,7 +1400,7 @@
@Override
public DataGrid<Map<String, String>> gridDatas(String codeClssifyOid, String redisOid) {
VciBaseUtil.alertNotNull(redisOid,"瀵煎叆鐩镐技鏁版嵁",redisOid,"鏁版嵁缂撳瓨涓婚敭");
- List<CodeImprotDataVO> codeImprotDataVOs = bladeRedis.lRange(redisOid+"-"+codeClssifyOid,0,-1);
+ List<CodeImprotDataVO> codeImprotDataVOs = bladeRedis.get(redisOid+"-"+codeClssifyOid);
// redisService.getCacheList(redisOid+"-"+codeClssifyOid);
CodeImprotDataVO codeImprotDataVO=new CodeImprotDataVO();
if(!CollectionUtils.isEmpty(codeImprotDataVOs)){
@@ -1427,7 +1434,7 @@
@Override
public DataGrid<Map<String,String>> gridRowResemble(String oid,String redisOid){
VciBaseUtil.alertNotNull(redisOid,"瀵煎叆鐩镐技鏁版嵁",redisOid,"鏁版嵁缂撳瓨涓婚敭");
- List<DataResembleVO> codeImprotDataVOs = bladeRedis.lRange(redisOid,0,-1);;
+ List<DataResembleVO> codeImprotDataVOs = bladeRedis.get(redisOid);;
DataGrid<Map<String, String>> dataGrid = new DataGrid<>();
List<Map<String, String>> dataList = new ArrayList<>();
@@ -1825,7 +1832,7 @@
});
//鍏抽敭鐔熸倝鏇存敼
if (!CollectionUtils.isEmpty(editBoList)) {
- engineService.updateBatchByBaseModel(classifyFullInfo.getTopClassifyVO().getBtmtypeid(),editBoList);//淇濆瓨鏁版嵁
+ engineService.updateBatchByBaseModel(classifyFullInfo.getTopClassifyVO().getBtmTypeId(),editBoList);//淇濆瓨鏁版嵁
}
errorMap.putAll(errorKeyMap);
}
@@ -2121,7 +2128,7 @@
}else {
//瀛樺偍鏁版嵁
try {
- engineService.updateBatchByBaseModel(classifyFullInfo.getTopClassifyVO().getBtmtypeid(),updateList);
+ engineService.updateBatchByBaseModel(classifyFullInfo.getTopClassifyVO().getBtmTypeId(),updateList);
codeAllCodeService.saveBatch(codeAllCodeList);
if(deleteList.size()>0) {
commonsMapper.deleteByTaleAndOid(tableName, VciBaseUtil.array2String(deleteList.toArray(new String[]{})));
@@ -2248,7 +2255,7 @@
//娌℃湁闄愬埗鍒嗙被锛屼絾鏄竴涓ā鏉垮彧鍙兘鍦ㄤ竴涓笟鍔$被鍨嬮噷闈紝鎵�浠ョ洿鎺ユ煡璇㈣繖涓笟鍔$被鍨嬪嵆鍙�
if (!CollectionUtils.isEmpty(conditionMap)) {
- final String[] sql = {"select count(*) from " + VciBaseUtil.getTableName(classifyFullInfo.getTopClassifyVO().getBtmtypeid()) + " where 1 = 1 "};
+ final String[] sql = {"select count(*) from " + VciBaseUtil.getTableName(classifyFullInfo.getTopClassifyVO().getBtmTypeId()) + " where 1 = 1 "};
conditionMap.forEach((key, value) -> {
sql[0] += " and " + key + " = " + value;
});
@@ -2588,7 +2595,7 @@
String oid=rowData.getOid();
String rowNumber=rowData.getRowIndex();
ClientBusinessObject cbo = new ClientBusinessObject();
- DefaultAttrAssimtUtil.addDefaultAttrAssimt(cbo, classifyFullInfo.getTopClassifyVO().getBtmtypeid());
+ DefaultAttrAssimtUtil.addDefaultAttrAssimt(cbo, classifyFullInfo.getTopClassifyVO().getBtmTypeId());
rowData.getData().forEach((index,value)->{
String field = fieldIndexMap.get(index);
if(StringUtils.isBlank(field)){
@@ -2693,7 +2700,7 @@
String fullPath = getFullPath(classifyFullInfo);
codeImprotDataVO.getDatas().stream().forEach(rowData -> {
ClientBusinessObject cbo=new ClientBusinessObject();
- DefaultAttrAssimtUtil.addDefaultAttrAssimt(cbo, classifyFullInfo.getTopClassifyVO().getBtmtypeid());
+ DefaultAttrAssimtUtil.addDefaultAttrAssimt(cbo, classifyFullInfo.getTopClassifyVO().getBtmTypeId());
rowData.forEach((field,value)->{
try {
cbo.setAttributeValueWithNoCheck(field,value);
@@ -2745,7 +2752,7 @@
String fullPath,boolean newCode){
rowDataList.stream().forEach(rowData -> {
ClientBusinessObject cbo=new ClientBusinessObject();
- DefaultAttrAssimtUtil.addDefaultAttrAssimt(cbo, classifyFullInfo.getTopClassifyVO().getBtmtypeid());
+ DefaultAttrAssimtUtil.addDefaultAttrAssimt(cbo, classifyFullInfo.getTopClassifyVO().getBtmTypeId());
rowData.getData().forEach((index,value)->{
String field = fieldIndexMap.get(index);
if (StringUtils.isBlank(field)) {
@@ -3409,7 +3416,7 @@
engineService.wrapperKeyAttrConditionMap(value, keyRuleVO, attrId, trim, ignoreCase, ignoreWidth, trimAll, conditionMap);
});
if (!CollectionUtils.isEmpty(ketAttrMap)) {
- CodeTemplateAttrSqlBO sqlBO = engineService.getSqlByTemplateVO(classifyFullInfo.getTopClassifyVO().getBtmtypeid(), templateVO, conditionMap, null);
+ CodeTemplateAttrSqlBO sqlBO = engineService.getSqlByTemplateVO(classifyFullInfo.getTopClassifyVO().getBtmTypeId(), templateVO, conditionMap, null);
boolean isKeyCheck= commonsMapper.queryCountBySql(sqlBO.getSqlCount()) > 0;
if(isKeyCheck){
List<Map<String,String>> newDataList= commonsMapper.queryByOnlySqlForMap(sqlBO.getSqlUnPage());
@@ -3478,12 +3485,12 @@
List<String> unExistRuleClassifyOidList ){
if(!CollectionUtils.isEmpty(classifyVOMap)){
classifyVOMap.values().parallelStream().forEach(classifyVO->{
- if(StringUtils.isNotBlank(classifyVO.getCoderuleoid())){
- ruleOidMap.put(classifyVO.getOid(),classifyVO.getCoderuleoid());
+ if(StringUtils.isNotBlank(classifyVO.getCodeRuleOid())){
+ ruleOidMap.put(classifyVO.getOid(),classifyVO.getCodeRuleOid());
}else{
//閫掑綊鎵句笂绾�
List<String> ruleOidList = new ArrayList<>();
- recursionRule(classifyVOMap,classifyVO.getParentcodeclassifyoid(),ruleOidList);
+ recursionRule(classifyVOMap,classifyVO.getParentCodeClassifyOid(),ruleOidList);
if(!CollectionUtils.isEmpty(ruleOidList)){
ruleOidMap.put(classifyVO.getOid(),ruleOidList.get(0));
}else{
@@ -3503,11 +3510,11 @@
private void recursionRule(Map<String, CodeClassifyVO> classifyVOMap,String classifyOid,List<String> ruleOidList){
if(classifyVOMap.containsKey(classifyOid)){
CodeClassifyVO classifyVO = classifyVOMap.get(classifyOid);
- if(StringUtils.isNotBlank(classifyVO.getCoderuleoid())){
- ruleOidList.add(classifyVO.getCoderuleoid());
+ if(StringUtils.isNotBlank(classifyVO.getCodeRuleOid())){
+ ruleOidList.add(classifyVO.getCodeRuleOid());
return;
}else{
- recursionRule(classifyVOMap,classifyVO.getParentcodeclassifyoid(),ruleOidList);
+ recursionRule(classifyVOMap,classifyVO.getParentCodeClassifyOid(),ruleOidList);
}
}else{
Map<String, CodeClassifyVO> parentClassifyVOMap=new HashMap<>();
--
Gitblit v1.9.3