|
@@ -6,6 +6,9 @@ import com.lantone.qc.pub.model.OutputInfo;
|
|
import com.lantone.qc.pub.model.doc.BeHospitalizedDoc;
|
|
import com.lantone.qc.pub.model.doc.BeHospitalizedDoc;
|
|
import com.lantone.qc.pub.model.entity.General;
|
|
import com.lantone.qc.pub.model.entity.General;
|
|
import com.lantone.qc.pub.model.entity.GeneralDesc;
|
|
import com.lantone.qc.pub.model.entity.GeneralDesc;
|
|
|
|
+import com.lantone.qc.pub.model.label.PresentLabel;
|
|
|
|
+import com.lantone.qc.pub.util.ListUtil;
|
|
|
|
+import com.lantone.qc.pub.util.StringUtil;
|
|
import org.springframework.stereotype.Component;
|
|
import org.springframework.stereotype.Component;
|
|
|
|
|
|
import java.util.List;
|
|
import java.util.List;
|
|
@@ -20,21 +23,34 @@ import java.util.List;
|
|
@Component
|
|
@Component
|
|
public class BEH0443 extends QCCatalogue {
|
|
public class BEH0443 extends QCCatalogue {
|
|
public void start(InputInfo inputInfo, OutputInfo outputInfo) {
|
|
public void start(InputInfo inputInfo, OutputInfo outputInfo) {
|
|
- List<GeneralDesc> generals = inputInfo.getBeHospitalizedDoc().getPresentLabel().getGenerals();
|
|
|
|
- if(generals.size() > 0 || generals != null){
|
|
|
|
- for (GeneralDesc general:generals) {
|
|
|
|
- if(general.getName().contains("体重")){
|
|
|
|
- status.set("0");
|
|
|
|
- break;
|
|
|
|
|
|
+ BeHospitalizedDoc beHospitalizedDoc = inputInfo.getBeHospitalizedDoc();
|
|
|
|
+ if (beHospitalizedDoc == null) {
|
|
|
|
+ status.set("0");
|
|
|
|
+ return;
|
|
|
|
+ }
|
|
|
|
+ PresentLabel presentLabel = beHospitalizedDoc.getPresentLabel();
|
|
|
|
+ if (presentLabel != null) {
|
|
|
|
+ String presentLabelText = presentLabel.getText();
|
|
|
|
+ if (StringUtil.isNotBlank(presentLabelText) && presentLabelText.contains("体重")) {
|
|
|
|
+ status.set("0");
|
|
|
|
+ return;
|
|
|
|
+ }
|
|
|
|
+ List<GeneralDesc> generals = presentLabel.getGenerals();
|
|
|
|
+ if (ListUtil.isNotEmpty(generals)) {
|
|
|
|
+ for (GeneralDesc general : generals) {
|
|
|
|
+ if (general.getName().contains("体重")) {
|
|
|
|
+ status.set("0");
|
|
|
|
+ break;
|
|
|
|
+ }
|
|
}
|
|
}
|
|
}
|
|
}
|
|
- }
|
|
|
|
- List<General> gens = inputInfo.getBeHospitalizedDoc().getPresentLabel().getGens();
|
|
|
|
- if(gens.size() > 0 || gens != null){
|
|
|
|
- for (General general:gens) {
|
|
|
|
- if(general.getName().contains("体重")){
|
|
|
|
- status.set("0");
|
|
|
|
- break;
|
|
|
|
|
|
+ List<General> gens = presentLabel.getGens();
|
|
|
|
+ if (ListUtil.isNotEmpty(gens)) {
|
|
|
|
+ for (General general : gens) {
|
|
|
|
+ if (general.getName().contains("体重")) {
|
|
|
|
+ status.set("0");
|
|
|
|
+ break;
|
|
|
|
+ }
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|
|
}
|