|
|
|
|
@ -1093,6 +1093,44 @@ public class EntrustController extends BladeController { |
|
|
|
|
} |
|
|
|
|
examineResult.setPath(path); |
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
// 1.先拿到批次号
|
|
|
|
|
String batchNos = examineResult.getBatchNos(); |
|
|
|
|
if (batchNos != null && !"".equals(batchNos)) { |
|
|
|
|
String[] split3 = batchNos.split(","); |
|
|
|
|
Map<String, List<String>> tempListMap = new HashMap(); |
|
|
|
|
for (String batch : split3) { |
|
|
|
|
String reagenId = batch.split("-")[0]; |
|
|
|
|
String realBatch = batch.split("-")[1]; |
|
|
|
|
List<String> list = tempListMap.get(reagenId); |
|
|
|
|
if (CollectionUtils.isNotEmpty(list)) { |
|
|
|
|
list.add(realBatch); |
|
|
|
|
} else { |
|
|
|
|
List<String> temp = new ArrayList<>(); |
|
|
|
|
temp.add(realBatch); |
|
|
|
|
tempListMap.put(reagenId, temp); |
|
|
|
|
} |
|
|
|
|
} |
|
|
|
|
String resultBatchStr = ""; |
|
|
|
|
// 遍历处理批号
|
|
|
|
|
Set<String> strings = tempListMap.keySet(); |
|
|
|
|
for (String reagenId : strings) { |
|
|
|
|
// 根据试剂名称查询厂家名称
|
|
|
|
|
Reagent reagent = reagentService.getById(reagenId); |
|
|
|
|
String manufacturerName = reagent.getManufacturer(); |
|
|
|
|
List<String> list = tempListMap.get(reagenId); |
|
|
|
|
resultBatchStr += manufacturerName + ":批号("; |
|
|
|
|
for (int i = 0; i < list.size(); i++) { |
|
|
|
|
String realBatch = list.get(i); |
|
|
|
|
resultBatchStr += realBatch; |
|
|
|
|
if (i != list.size() - 1) { |
|
|
|
|
resultBatchStr += "、"; |
|
|
|
|
} |
|
|
|
|
} |
|
|
|
|
resultBatchStr += ")"; |
|
|
|
|
} |
|
|
|
|
examineResult.setBatchNos(resultBatchStr); |
|
|
|
|
} |
|
|
|
|
examine.setExamineResult(examineResult); |
|
|
|
|
} |
|
|
|
|
} |
|
|
|
|
|