|
@@ -10,6 +10,7 @@ import com.diagbot.biz.push.enums.FeatureTypeEnum;
|
|
|
import com.diagbot.client.TranServiceClient;
|
|
|
import com.diagbot.client.bean.CalculateData;
|
|
|
import com.diagbot.client.bean.HosCodeVO;
|
|
|
+import com.diagbot.config.CryptConfiguer;
|
|
|
import com.diagbot.dto.ConceptPushDTO;
|
|
|
import com.diagbot.dto.PushDTO;
|
|
|
import com.diagbot.dto.RespDTO;
|
|
@@ -18,6 +19,7 @@ import com.diagbot.enums.ConceptTypeEnum;
|
|
|
import com.diagbot.enums.LexiconTypeEnum;
|
|
|
import com.diagbot.facade.ClinicalFacade;
|
|
|
import com.diagbot.facade.ConceptFacade;
|
|
|
+import com.diagbot.util.CryptUtil;
|
|
|
import com.diagbot.util.EntityUtil;
|
|
|
import com.diagbot.util.FastJsonUtils;
|
|
|
import com.diagbot.util.ListUtil;
|
|
@@ -54,6 +56,8 @@ public class PushItemAggregate {
|
|
|
private TranServiceClient tranServiceClient;
|
|
|
@Autowired
|
|
|
private ClinicalFacade clinicalFacade;
|
|
|
+ @Autowired
|
|
|
+ CryptConfiguer cryptConfiguer;
|
|
|
|
|
|
@DataProvider("setAll")
|
|
|
public PushDTO setAll(
|
|
@@ -111,14 +115,25 @@ public class PushItemAggregate {
|
|
|
//没有推送信息时,默认取全科模板
|
|
|
if (StringUtil.isBlank(deptName)) {
|
|
|
deptName = "全科";
|
|
|
+ if (cryptConfiguer.cryptFlag) {
|
|
|
+ deptName = CryptUtil.encrypt_char(deptName);
|
|
|
+ }
|
|
|
}
|
|
|
ConceptBaseVO conceptBaseVO = new ConceptBaseVO();
|
|
|
conceptBaseVO.setName(deptName);
|
|
|
conceptBaseVO.setLibType(LexiconTypeEnum.DEPARTMENT.getKey());
|
|
|
ConceptPushDTO deptDTO = new ConceptPushDTO();
|
|
|
Concept dept = conceptFacade.getConcept(conceptBaseVO);
|
|
|
- if (dept == null && deptName.equals("全科") == false) {
|
|
|
- deptName = "全科";
|
|
|
+ if (dept == null) {
|
|
|
+ if (cryptConfiguer.cryptFlag) {
|
|
|
+ if (deptName.equals(CryptUtil.encrypt_char("全科")) == false) {
|
|
|
+ deptName = CryptUtil.encrypt_char("全科");
|
|
|
+ }
|
|
|
+ } else {
|
|
|
+ if (deptName.equals("全科") == false) {
|
|
|
+ deptName = "全科";
|
|
|
+ }
|
|
|
+ }
|
|
|
conceptBaseVO.setName(deptName);
|
|
|
dept = conceptFacade.getConcept(conceptBaseVO);
|
|
|
}
|
|
@@ -310,6 +325,9 @@ public class PushItemAggregate {
|
|
|
JSONObject scaleJson = detail.getContent();
|
|
|
if (null != scaleJson.get("name")) {
|
|
|
String scaleName = scaleJson.get("name").toString();
|
|
|
+ if(cryptConfiguer.cryptFlag) {
|
|
|
+ scaleName = CryptUtil.encrypt_char(scaleName);
|
|
|
+ }
|
|
|
conceptBaseVO.setName(scaleName);
|
|
|
conceptBaseVO.setLibType(LexiconTypeEnum.GAUGE.getKey());
|
|
|
Concept scaleConcept = conceptFacade.getConcept(conceptBaseVO);
|
|
@@ -386,6 +404,9 @@ public class PushItemAggregate {
|
|
|
.stream()
|
|
|
.map(concept -> concept.getName())
|
|
|
.collect(Collectors.toList());
|
|
|
+ if(cryptConfiguer.cryptFlag) {
|
|
|
+ CryptUtil.encryptList(uniqueNameList);
|
|
|
+ }
|
|
|
lisConfigVO.setUniqueNameList(uniqueNameList);
|
|
|
if (type.equals(ConceptTypeEnum.Lis.getKey())) {
|
|
|
RespDTO<Map<String, List<String>>> lisRes
|