1、接口返回值-检查、检验申请单增加开立时间

2、检查、检验申请单没有进行合并处理
master
leijx 5 years ago
parent 37dd215553
commit cd22cb1ab9

@ -42,7 +42,7 @@ public class TestController {
Object[] objects = new Object[0];
// invoke("方法名",参数1,参数2,参数3....);
try {
objects = client.invoke("CheckData", "a3a93afa-6e7e-43fd-99af-18cb7437bc4c");
objects = client.invoke("CheckData", "8b033ba1-5ab7-457e-94d3-c5660c1261ab");
} catch (Exception e) {
e.printStackTrace();
}

@ -11,4 +11,6 @@ public class ExamApplyDto {
private String name;
private String reportType;
private String authorReportTime;
}

@ -94,12 +94,12 @@ public interface ArchiveDetailRepository extends JpaRepository<ArchiveDetail, St
@Query(value = " select e.apply_id as applyId,e.name,e.report_type as reportType from exam_apply e " +
@Query(value = " select e.apply_id as applyId,e.name,e.report_type as reportType,e.author_report_time as authorReportTime from exam_apply e " +
" where e.report_type in ?1 and e.is_valid = 0 and e.is_open_his = 'E' and e.is_open_other = 'E' " +
" and exists " +
" (select 1 from archive_master m where m.inp_no = e.inp_no and m.visit_id = e.visit_id " +
" and m.patient_id = e.patient_id " +
" and m.ID = ?2) order by e.report_type ",nativeQuery = true)
" and m.ID = ?2) order by e.report_type,e.name,e.author_report_time ",nativeQuery = true)
List<Map<Object, Object>> getAllInspectionApply(List<String> type, String masterId);
}

@ -60,25 +60,34 @@ public class ArchiveDetailServiceImpl implements ArchiveDetailService {
}
}
}
// 4、统计集合里元素相同的名称及数量
Map<String, Integer> map = new HashMap<String, Integer>();
for(ExamApplyDto examApplyDto:
resultList){
String name = examApplyDto.getName() ==null ? (Objects.equals(examApplyDto.getReportType(),"10") ? "检验报告" : "检查报告"):examApplyDto.getName();
if(map.containsKey(name)){
map.put(name, map.get(name).intValue() + 1);
}else{
map.put(name, new Integer(1));
StringBuffer sb=new StringBuffer();
for (ExamApplyDto examApplyDto:
resultList) {
String authorReportTime = examApplyDto.getAuthorReportTime();
if(authorReportTime != null && authorReportTime.lastIndexOf(".") != -1){
authorReportTime = authorReportTime.substring(0,authorReportTime.lastIndexOf("."));
}
sb.append("缺失"+examApplyDto.getName() +"("+authorReportTime+")");
}
// // 4、统计集合里元素相同的名称及数量
// Map<String, Integer> map = new HashMap<String, Integer>();
// for(ExamApplyDto examApplyDto:
// resultList){
// String name = examApplyDto.getName() ==null ? (Objects.equals(examApplyDto.getReportType(),"10") ? "检验报告" : "检查报告"):examApplyDto.getName();
// if(map.containsKey(name)){
// map.put(name, map.get(name).intValue() + 1);
// }else{
// map.put(name, new Integer(1));
// }
// }
// 5、开始拼装
Iterator<String> keys = map.keySet().iterator();
StringBuffer sb=new StringBuffer();
while(keys.hasNext()){
String key = keys.next();
int i = map.get(key).intValue();
sb.append(key + "缺失" + map.get(key).intValue() + "份,");
}
// Iterator<String> keys = map.keySet().iterator();
// while(keys.hasNext()){
// String key = keys.next();
// int i = map.get(key).intValue();
// sb.append(key + "缺失" + map.get(key).intValue() + "份,");
// }
if(sb.length() > 0){
result = sb.substring(0,sb.length()-1);
}

@ -1,17 +1,18 @@
spring:
datasource:
# url: jdbc:mysql://localhost:3306/test?serverTimezone=UTC&characterEncoding=utf8&useUnicode=true&useSSL=false
# # url: jdbc:mysql://10.6.1.127:3306/test
# username: root
# password: 123456
# driver-class-name: com.mysql.jdbc.Driver
# jpa:
# database: mysql
# show-sql: false
# hibernate:
# ddl-auto: update
# database-platform: org.hibernate.dialect.MySQL5InnoDBDialect
# url: jdbc:mysql://localhost:3306/test?serverTimezone=UTC&characterEncoding=utf8&useUnicode=true&useSSL=false
# # url: jdbc:mysql://10.6.1.127:3306/test
# username: root
# password: 123456
# driver-class-name: com.mysql.jdbc.Driver
# jpa:
# database: mysql
# show-sql: false
# hibernate:
# ddl-auto: update
# database-platform: org.hibernate.dialect.MySQL5InnoDBDialect
url: jdbc:sqlserver://10.6.1.127:1433;DatabaseName=DB_PrivilegeManagement_GYFY
# url: jdbc:sqlserver://120.27.212.36:1433;DatabaseName=emr_record
username: sa
password: docus@702
driver-class-name: com.microsoft.sqlserver.jdbc.SQLServerDriver

Loading…
Cancel
Save