From d74e1672af99afd7e6a24327deb22b308dd5fc88 Mon Sep 17 00:00:00 2001 From: yuxc <653031404@qq.com> Date: 星期一, 04 十二月 2023 08:38:44 +0800 Subject: [PATCH] Merge remote-tracking branch 'origin/master' --- Source/UBCS/ubcs-service/ubcs-code/src/main/java/com/vci/ubcs/code/service/impl/MdmEngineServiceImpl.java | 11 ++++++----- 1 files changed, 6 insertions(+), 5 deletions(-) diff --git a/Source/UBCS/ubcs-service/ubcs-code/src/main/java/com/vci/ubcs/code/service/impl/MdmEngineServiceImpl.java b/Source/UBCS/ubcs-service/ubcs-code/src/main/java/com/vci/ubcs/code/service/impl/MdmEngineServiceImpl.java index 2dd56b5..2ddc23a 100644 --- a/Source/UBCS/ubcs-service/ubcs-code/src/main/java/com/vci/ubcs/code/service/impl/MdmEngineServiceImpl.java +++ b/Source/UBCS/ubcs-service/ubcs-code/src/main/java/com/vci/ubcs/code/service/impl/MdmEngineServiceImpl.java @@ -44,6 +44,7 @@ import com.vci.ubcs.starter.revision.service.RevisionModelUtil; import com.vci.ubcs.starter.util.MdmBtmTypeConstant; import com.vci.ubcs.starter.util.SaveLogUtil; +import com.vci.ubcs.starter.util.SpecialCharacterConverter; import com.vci.ubcs.starter.util.UBCSSqlKeyword; import com.vci.ubcs.starter.web.constant.QueryOptionConstant; import com.vci.ubcs.starter.web.constant.RegExpConstant; @@ -464,7 +465,7 @@ ); }catch (Exception e){ // 鎻掑叆鏇存敼鏃ュ織璁板綍 - saveLogUtil.operateLog(CodeDefaultLC.getTextByValue(baseModelDTO.getLcStatus()),true,e.getMessage()); + saveLogUtil.operateLog(CodeDefaultLC.getTextByValue(baseModelDTO.getLcStatus()),true,e.toString()); throw e; } } @@ -791,6 +792,7 @@ sql[0] += " and oid != '" + orderDTO.getCopyFromVersion() + "'"; } sql[0] += " and lastR = '1' and lastV = '1' "; + // 鑾峰彇涓嶅弬涓庢牎楠岀殑鍒嗙被oid String isParticipateCheckOids = classifyService.selectLeafByParentClassifyOid(classifyFullInfo.getTopClassifyVO().getOid(), classifyFullInfo.getCurrentClassifyVO().getOid()); if(Func.isNotEmpty(isParticipateCheckOids)){ sql[0] += " and codeclsfid not in(" + isParticipateCheckOids + ")"; @@ -1193,12 +1195,12 @@ temp = "%s"; } queryKey = String.format(temp, "nvl("+ "t." + attrId +",'/')"); - queryValue = String.format(temp, "'" + (trim ? value.trim() : value) + "'"); + queryValue = String.format(temp, "'" + (trim ? SpecialCharacterConverter.escapeSpecialCharacters(value.trim()):SpecialCharacterConverter.escapeSpecialCharacters(value)) + "'"); conditionMap.put(queryKey, queryValue); } else { if(StringUtils.isNotBlank(value)) { //涓虹┖鐨勬椂鍊欎笉浠h〃涓嶆牎楠岋紝鍙槸涓嶅幓闄ょ浉鍏崇殑淇℃伅 - conditionMap.put("nvl("+ "t." + attrId+",'/')", "'" + value + "'"); + conditionMap.put("nvl("+ "t." + attrId+",'/')", "'" + SpecialCharacterConverter.escapeSpecialCharacters(value) + "'"); }else{ conditionMap.put("t." + attrId, QueryOptionConstant.ISNULL); } @@ -2472,7 +2474,6 @@ return getSqlByValue(key, value, attrVOMap,btmType); } }*/ - } /** @@ -3112,7 +3113,7 @@ saveLogUtil.operateLog("鏁版嵁鏇存敼",false, StringUtil.format("{}\n淇敼涓�:\n{}",JSON.toJSONString(Collections.singletonList(oldCbo)),JSON.toJSONString(Collections.singletonList(cbo)))); } catch (Exception vciError) { // 璁板綍鏁版嵁鏇存敼鎶ラ敊鏃剁殑鏃ュ織 - saveLogUtil.operateLog("鏁版嵁鏇存敼",true,vciError.getMessage()); + saveLogUtil.operateLog("鏁版嵁鏇存敼",true,vciError.toString()); throw new VciBaseException("鏁版嵁鏇存敼淇濆瓨鍑洪敊浜�", new String[0], vciError); } -- Gitblit v1.9.3