|
@@ -19,6 +19,64 @@ public class PacsSubNameNode {
|
|
|
NodeInfo nodeInfo;
|
|
|
|
|
|
|
|
|
+ Gender gender = pacs.getGender();
|
|
|
+ if (gender != null) {
|
|
|
+ nodeInfo = new NodeInfo();
|
|
|
+ nodeInfo.setName(gender.getName());
|
|
|
+ nodeInfo.setTypeval(Constants.gender);
|
|
|
+ pacsBillNeoDTO.setGender(NeoUtil.updateNodeInfo(nodeInfo));
|
|
|
+ }
|
|
|
+
|
|
|
+
|
|
|
+ Set<ClinicalFinding> clinicalfindings = pacs.getClinicalfindings();
|
|
|
+ for (ClinicalFinding clinicalfinding : clinicalfindings) {
|
|
|
+ nodeInfo = new NodeInfo();
|
|
|
+ nodeInfo.setName(clinicalfinding.getName());
|
|
|
+ nodeInfo.setMinval(NeoUtil.DoubletoBigDecimal(clinicalfinding.getMinval()));
|
|
|
+ nodeInfo.setMaxval(NeoUtil.DoubletoBigDecimal(clinicalfinding.getMaxval()));
|
|
|
+ nodeInfo.setUnit(clinicalfinding.getUnit());
|
|
|
+ nodeInfo.setRange(clinicalfinding.getRange());
|
|
|
+ nodeInfo.setTypeval(Constants.clinicalfinding);
|
|
|
+ pacsBillNeoDTO.getClinicfindings().add(NeoUtil.updateNodeInfo(nodeInfo));
|
|
|
+ }
|
|
|
+
|
|
|
+
|
|
|
+ Set<Vital> vitals = pacs.getVitals();
|
|
|
+ for (Vital vital : vitals) {
|
|
|
+ nodeInfo = new NodeInfo();
|
|
|
+ String name = vital.getName();
|
|
|
+ nodeInfo.setName(name);
|
|
|
+ nodeInfo.setMinval(NeoUtil.DoubletoBigDecimal(vital.getMinval()));
|
|
|
+ nodeInfo.setMaxval(NeoUtil.DoubletoBigDecimal(vital.getMaxval()));
|
|
|
+ nodeInfo.setUnit(vital.getUnit());
|
|
|
+ nodeInfo.setRange(vital.getRange());
|
|
|
+ nodeInfo.setTypeval(Constants.vital);
|
|
|
+ pacsBillNeoDTO.getVitals().add(NeoUtil.updateNodeInfo(nodeInfo));
|
|
|
+ }
|
|
|
+
|
|
|
+
|
|
|
+ Set<Lis> liss = pacs.getLis();
|
|
|
+ for (Lis lis : liss) {
|
|
|
+ nodeInfo = new NodeInfo();
|
|
|
+ nodeInfo.setName(lis.getName());
|
|
|
+ nodeInfo.setMinval(NeoUtil.DoubletoBigDecimal(lis.getMinval()));
|
|
|
+ nodeInfo.setMaxval(NeoUtil.DoubletoBigDecimal(lis.getMaxval()));
|
|
|
+ nodeInfo.setUnit(lis.getUnit());
|
|
|
+ nodeInfo.setRange(lis.getRange());
|
|
|
+ nodeInfo.setTypeval(Constants.lis);
|
|
|
+ pacsBillNeoDTO.getLis().add(NeoUtil.updateNodeInfo(nodeInfo));
|
|
|
+ }
|
|
|
+
|
|
|
+
|
|
|
+ Set<PacsDescribe> conflict_pacsdesc = pacs.getPacsdescribes();
|
|
|
+ for (PacsDescribe pacsdesc : conflict_pacsdesc) {
|
|
|
+ nodeInfo = new NodeInfo();
|
|
|
+ nodeInfo.setName(pacsdesc.getName());
|
|
|
+ nodeInfo.setTypeval(Constants.pacsdesc);
|
|
|
+ pacsBillNeoDTO.getPacsDesc().add(NeoUtil.updateNodeInfo(nodeInfo));
|
|
|
+ }
|
|
|
+
|
|
|
+
|
|
|
Set<Group> groups = pacs.getGroups();
|
|
|
for (Group group : groups) {
|
|
|
nodeInfo = new NodeInfo();
|
|
@@ -28,6 +86,15 @@ public class PacsSubNameNode {
|
|
|
}
|
|
|
|
|
|
|
|
|
+ Set<OralMedicine> conflict_medicines = pacs.getOralmedicines();
|
|
|
+ for (OralMedicine conflict_medicine : conflict_medicines) {
|
|
|
+ nodeInfo = new NodeInfo();
|
|
|
+ nodeInfo.setName(conflict_medicine.getName());
|
|
|
+ nodeInfo.setTypeval(Constants.yaoping);
|
|
|
+ pacsBillNeoDTO.getOralmeds().add(NeoUtil.updateNodeInfo(nodeInfo));
|
|
|
+ }
|
|
|
+
|
|
|
+
|
|
|
Set<Disease> diseases = pacs.getDiseases();
|
|
|
for (Disease disease : diseases) {
|
|
|
nodeInfo = new NodeInfo();
|
|
@@ -46,14 +113,32 @@ public class PacsSubNameNode {
|
|
|
}
|
|
|
|
|
|
|
|
|
+ Set<Allergen> allergens = pacs.getAllergens();
|
|
|
+ for (Allergen allergen : allergens) {
|
|
|
+ nodeInfo = new NodeInfo();
|
|
|
+ nodeInfo.setName(allergen.getName());
|
|
|
+ nodeInfo.setTypeval(Constants.yaoping); // 过敏原归类成药物过敏原,与模型提取匹配
|
|
|
+ pacsBillNeoDTO.getAllergicmeds().add(NeoUtil.updateNodeInfo(nodeInfo));
|
|
|
+ }
|
|
|
+
|
|
|
+
|
|
|
+ Set<ConflictDevice> conflictDevices = pacs.getConflictdevices();
|
|
|
+ for (ConflictDevice conflictDevice : conflictDevices) {
|
|
|
+ nodeInfo = new NodeInfo();
|
|
|
+ nodeInfo.setName(conflictDevice.getName());
|
|
|
+ nodeInfo.setTypeval(Constants.conflictdevice);
|
|
|
+ pacsBillNeoDTO.getMeddevice().add(NeoUtil.updateNodeInfo(nodeInfo));
|
|
|
+ }
|
|
|
+
|
|
|
+
|
|
|
return pacsBillNeoDTO;
|
|
|
}
|
|
|
|
|
|
|
|
|
/**
|
|
|
- * 处理辅检开单合理性
|
|
|
+ * 处理辅检子项目开单合理性
|
|
|
*/
|
|
|
- public List<BillNeoDTO> getPacsBill(Map<String, String> pacsterm, PacsSubNameRepository pacsRepository) {
|
|
|
+ public List<BillNeoDTO> getSubPacsBill(List<Map<String, String>> pacslist, PacsSubNameRepository pacsSubRepository) {
|
|
|
List<BillNeoDTO> billNeoDTOs = new ArrayList<>();
|
|
|
BillNeoDTO billNeoDTO;
|
|
|
|
|
@@ -62,23 +147,25 @@ public class PacsSubNameNode {
|
|
|
List<PacsSubName> pacslt;
|
|
|
String pacsname;
|
|
|
|
|
|
- for (String term : pacsterm.keySet()) {
|
|
|
- billNeoDTO = new BillNeoDTO();
|
|
|
- pacsname = pacsterm.get(term);
|
|
|
- billNeoDTO.setName(term);
|
|
|
- billNeoDTO.setStandname(pacsname);
|
|
|
+ for (Map<String, String> pacsterm : pacslist) {
|
|
|
+ for (String term : pacsterm.keySet()) {
|
|
|
+ billNeoDTO = new BillNeoDTO();
|
|
|
+ pacsname = pacsterm.get(term);
|
|
|
+ billNeoDTO.setName(term);
|
|
|
+ billNeoDTO.setStandname(pacsname);
|
|
|
|
|
|
- pacsBillNeoDTO = new PacsBillNeoDTO();
|
|
|
+ pacsBillNeoDTO = new PacsBillNeoDTO();
|
|
|
|
|
|
- pacslt = pacsRepository.findByNameIs(pacsname);
|
|
|
+ pacslt = pacsSubRepository.findByNameIs(pacsname);
|
|
|
|
|
|
- if (pacslt != null && pacslt.size()>0) {
|
|
|
- pacsBillNeoDTO = PacstoPACSDTO(pacslt.get(0));
|
|
|
- }
|
|
|
+ if (pacslt != null && pacslt.size() > 0) {
|
|
|
+ pacsBillNeoDTO = PacstoPACSDTO(pacslt.get(0));
|
|
|
+ }
|
|
|
|
|
|
- billNeoDTO.setPacsBillNeoDTO(pacsBillNeoDTO);
|
|
|
+ billNeoDTO.setPacsBillNeoDTO(pacsBillNeoDTO);
|
|
|
|
|
|
- billNeoDTOs.add(billNeoDTO);
|
|
|
+ billNeoDTOs.add(billNeoDTO);
|
|
|
+ }
|
|
|
}
|
|
|
|
|
|
return billNeoDTOs;
|