|
@@ -50,12 +50,15 @@ public class ClinicalFacade {
|
|
|
sData.setLisArr(processLis(sData.getLisArr()));
|
|
|
|
|
|
Response<ResponseData> res = aiServiceClient.bayesPageData(sData);
|
|
|
+ if (res == null || res.getData() == null) {
|
|
|
+ throw new CommonException(CommonErrorCode.SERVER_IS_ERROR, "AI没有返回结果");
|
|
|
+ }
|
|
|
|
|
|
return res.getData();
|
|
|
}
|
|
|
|
|
|
private List<LisResult> processLis(List<LisResult> lisArr) {
|
|
|
- if(ListUtil.isEmpty(lisArr)){
|
|
|
+ if (ListUtil.isEmpty(lisArr)) {
|
|
|
return lisArr;
|
|
|
}
|
|
|
|
|
@@ -69,8 +72,7 @@ public class ClinicalFacade {
|
|
|
|
|
|
if (Otherval.indexOf(pos) >= 0 || Otherval.indexOf(neg) >= 0) {
|
|
|
lisres.setOtherValue(lisres.getDetailName() + Otherval);
|
|
|
- }
|
|
|
- else {
|
|
|
+ } else {
|
|
|
Otherval = (Otherval.trim().length() > 0) ? Otherval.trim() + "\n" : "";
|
|
|
|
|
|
if (lisres.getMaxValue() != null && lisres.getValue() > lisres.getMaxValue()) {
|
|
@@ -113,4 +115,4 @@ public class ClinicalFacade {
|
|
|
}
|
|
|
return response.getData();
|
|
|
}
|
|
|
-}
|
|
|
+}
|