chengyao 4 سال پیش
والد
کامیت
81db7b80d5
1فایلهای تغییر یافته به همراه10 افزوده شده و 2 حذف شده
  1. 10 2
      src/main/java/com/diagbot/facade/BehospitalInfoFacade.java

+ 10 - 2
src/main/java/com/diagbot/facade/BehospitalInfoFacade.java

@@ -301,8 +301,16 @@ public class BehospitalInfoFacade extends BehospitalInfoServiceImpl {
                 EncrypDES encrypDES = new EncrypDES();
                 for (RecordContentDTO recordContentDTO : recordContentDTOList) {
                     recTitle = recordContentDTO.getRecTitle();
-                    recordContentDTO.setXmlText(encrypDES.decryptor(recordContentDTO.getXmlText()));
-                    recordContentDTO.setHtmlText(encrypDES.decryptor(recordContentDTO.getHtmlText()));
+                    if(StringUtils.isNotEmpty(recordContentDTO.getXmlText())){
+                        recordContentDTO.setXmlText(encrypDES.decryptor(recordContentDTO.getXmlText()));
+                    }
+                    try {
+                        if(StringUtils.isNotEmpty(recordContentDTO.getHtmlText())){
+                            recordContentDTO.setHtmlText(encrypDES.decryptor(recordContentDTO.getHtmlText()));
+                        }
+                    } catch (Exception e) {
+                        recordContentDTO.setHtmlText(null);
+                    }
                 }
             } catch (Exception e) {
                 throw new CommonException(CommonErrorCode.SERVER_IS_ERROR,