Commit 100a284422fa686aa315e6fc6a0de137f2211d2c
1 parent
dfa146e08a
Exists in
dev
#fix:新增大同高危手册检查记录功能
Showing 5 changed files with 298 additions and 5 deletions
- platform-dal/src/main/java/com/lyms/platform/pojo/AntExHighRiskModel.java
- platform-dal/src/main/java/com/lyms/platform/query/DiagnoseConfigQuery.java
- platform-operate-api/src/main/java/com/lyms/platform/operate/web/controller/AntenatalExaminationController.java
- platform-operate-api/src/main/java/com/lyms/platform/operate/web/facade/AntenatalExaminationFacade.java
- platform-operate-api/src/main/java/com/lyms/platform/operate/web/facade/PatientFacade.java
platform-dal/src/main/java/com/lyms/platform/pojo/AntExHighRiskModel.java
View file @
100a284
| 1 | +package com.lyms.platform.pojo; | |
| 2 | + | |
| 3 | +import com.lyms.platform.beans.SerialIdEnum; | |
| 4 | +import org.codehaus.jackson.annotate.JsonIgnoreProperties; | |
| 5 | +import org.codehaus.jackson.annotate.JsonProperty; | |
| 6 | +import org.springframework.data.mongodb.core.mapping.Document; | |
| 7 | + | |
| 8 | +import java.util.Date; | |
| 9 | + | |
| 10 | +@Document(collection = "lyms_antexhighrisk") | |
| 11 | +@JsonIgnoreProperties(ignoreUnknown = true) | |
| 12 | +public class AntExHighRiskModel { | |
| 13 | + private static final long serialVersionUID = SerialIdEnum.Patients.getCid(); | |
| 14 | + private String id; | |
| 15 | + private String hospitalId; | |
| 16 | + private Integer yn; | |
| 17 | + | |
| 18 | + private String parentId; | |
| 19 | + //测量日期 | |
| 20 | + private String checkTime; | |
| 21 | + //盆骨测量情况(间距,cm) | |
| 22 | + private String pelvic; | |
| 23 | + //入口:骶耻外径 | |
| 24 | + @JsonProperty(value = "EC") | |
| 25 | + private String EC; | |
| 26 | + //出口:坐骨结节间经 | |
| 27 | + @JsonProperty(value = "TO") | |
| 28 | + private String TO; | |
| 29 | + //中骨盆坐骨棘 | |
| 30 | + private String ischialSpine; | |
| 31 | + //前后经 | |
| 32 | + private String qianhoujing; | |
| 33 | + //切迹宽 | |
| 34 | + private String qiejikuan; | |
| 35 | + //后失状径 | |
| 36 | + private String hszhuangjing; | |
| 37 | + //前后经 | |
| 38 | + private String qianhoujing2; | |
| 39 | + //耻骨弓 | |
| 40 | + private String chigugong; | |
| 41 | + //侧壁 | |
| 42 | + private String cebi; | |
| 43 | + //骶骨 | |
| 44 | + private String digu; | |
| 45 | + //其他 | |
| 46 | + private String other; | |
| 47 | + //诊断 | |
| 48 | + private String diagnose; | |
| 49 | + //诊断时间 | |
| 50 | + private String diagnoseTime; | |
| 51 | + //签名 | |
| 52 | + private String signature; | |
| 53 | + | |
| 54 | + private Date modified; | |
| 55 | + | |
| 56 | + private Date created; | |
| 57 | + | |
| 58 | + | |
| 59 | + public String getId() { | |
| 60 | + return id; | |
| 61 | + } | |
| 62 | + | |
| 63 | + public void setId(String id) { | |
| 64 | + this.id = id; | |
| 65 | + } | |
| 66 | + | |
| 67 | + public String getParentId() { | |
| 68 | + return parentId; | |
| 69 | + } | |
| 70 | + | |
| 71 | + public void setParentId(String parentId) { | |
| 72 | + this.parentId = parentId; | |
| 73 | + } | |
| 74 | + | |
| 75 | + public String getHospitalId() { | |
| 76 | + return hospitalId; | |
| 77 | + } | |
| 78 | + | |
| 79 | + public void setHospitalId(String hospitalId) { | |
| 80 | + this.hospitalId = hospitalId; | |
| 81 | + } | |
| 82 | + | |
| 83 | + public String getCheckTime() { | |
| 84 | + return checkTime; | |
| 85 | + } | |
| 86 | + | |
| 87 | + public void setCheckTime(String checkTime) { | |
| 88 | + this.checkTime = checkTime; | |
| 89 | + } | |
| 90 | + | |
| 91 | + public Integer getYn() { | |
| 92 | + return yn; | |
| 93 | + } | |
| 94 | + | |
| 95 | + public void setYn(Integer yn) { | |
| 96 | + this.yn = yn; | |
| 97 | + } | |
| 98 | + | |
| 99 | + public String getPelvic() { | |
| 100 | + return pelvic; | |
| 101 | + } | |
| 102 | + | |
| 103 | + public void setPelvic(String pelvic) { | |
| 104 | + this.pelvic = pelvic; | |
| 105 | + } | |
| 106 | + | |
| 107 | + public String getEC() { | |
| 108 | + return EC; | |
| 109 | + } | |
| 110 | + | |
| 111 | + public void setEC(String EC) { | |
| 112 | + this.EC = EC; | |
| 113 | + } | |
| 114 | + | |
| 115 | + public String getTO() { | |
| 116 | + return TO; | |
| 117 | + } | |
| 118 | + | |
| 119 | + public void setTO(String TO) { | |
| 120 | + this.TO = TO; | |
| 121 | + } | |
| 122 | + | |
| 123 | + public String getIschialSpine() { | |
| 124 | + return ischialSpine; | |
| 125 | + } | |
| 126 | + | |
| 127 | + public void setIschialSpine(String ischialSpine) { | |
| 128 | + this.ischialSpine = ischialSpine; | |
| 129 | + } | |
| 130 | + | |
| 131 | + public String getQianhoujing() { | |
| 132 | + return qianhoujing; | |
| 133 | + } | |
| 134 | + | |
| 135 | + public void setQianhoujing(String qianhoujing) { | |
| 136 | + this.qianhoujing = qianhoujing; | |
| 137 | + } | |
| 138 | + | |
| 139 | + public String getQiejikuan() { | |
| 140 | + return qiejikuan; | |
| 141 | + } | |
| 142 | + | |
| 143 | + public void setQiejikuan(String qiejikuan) { | |
| 144 | + this.qiejikuan = qiejikuan; | |
| 145 | + } | |
| 146 | + | |
| 147 | + public String getHszhuangjing() { | |
| 148 | + return hszhuangjing; | |
| 149 | + } | |
| 150 | + | |
| 151 | + public void setHszhuangjing(String hszhuangjing) { | |
| 152 | + this.hszhuangjing = hszhuangjing; | |
| 153 | + } | |
| 154 | + | |
| 155 | + public String getQianhoujing2() { | |
| 156 | + return qianhoujing2; | |
| 157 | + } | |
| 158 | + | |
| 159 | + public void setQianhoujing2(String qianhoujing2) { | |
| 160 | + this.qianhoujing2 = qianhoujing2; | |
| 161 | + } | |
| 162 | + | |
| 163 | + public String getChigugong() { | |
| 164 | + return chigugong; | |
| 165 | + } | |
| 166 | + | |
| 167 | + public void setChigugong(String chigugong) { | |
| 168 | + this.chigugong = chigugong; | |
| 169 | + } | |
| 170 | + | |
| 171 | + public String getCebi() { | |
| 172 | + return cebi; | |
| 173 | + } | |
| 174 | + | |
| 175 | + public void setCebi(String cebi) { | |
| 176 | + this.cebi = cebi; | |
| 177 | + } | |
| 178 | + | |
| 179 | + public String getDigu() { | |
| 180 | + return digu; | |
| 181 | + } | |
| 182 | + | |
| 183 | + public void setDigu(String digu) { | |
| 184 | + this.digu = digu; | |
| 185 | + } | |
| 186 | + | |
| 187 | + public String getOther() { | |
| 188 | + return other; | |
| 189 | + } | |
| 190 | + | |
| 191 | + public void setOther(String other) { | |
| 192 | + this.other = other; | |
| 193 | + } | |
| 194 | + | |
| 195 | + public String getDiagnose() { | |
| 196 | + return diagnose; | |
| 197 | + } | |
| 198 | + | |
| 199 | + public void setDiagnose(String diagnose) { | |
| 200 | + this.diagnose = diagnose; | |
| 201 | + } | |
| 202 | + | |
| 203 | + public String getDiagnoseTime() { | |
| 204 | + return diagnoseTime; | |
| 205 | + } | |
| 206 | + | |
| 207 | + public void setDiagnoseTime(String diagnoseTime) { | |
| 208 | + this.diagnoseTime = diagnoseTime; | |
| 209 | + } | |
| 210 | + | |
| 211 | + public String getSignature() { | |
| 212 | + return signature; | |
| 213 | + } | |
| 214 | + | |
| 215 | + public void setSignature(String signature) { | |
| 216 | + this.signature = signature; | |
| 217 | + } | |
| 218 | + | |
| 219 | + public Date getModified() { | |
| 220 | + return modified; | |
| 221 | + } | |
| 222 | + | |
| 223 | + public void setModified(Date modified) { | |
| 224 | + this.modified = modified; | |
| 225 | + } | |
| 226 | + | |
| 227 | + public Date getCreated() { | |
| 228 | + return created; | |
| 229 | + } | |
| 230 | + | |
| 231 | + public void setCreated(Date created) { | |
| 232 | + this.created = created; | |
| 233 | + } | |
| 234 | +} |
platform-dal/src/main/java/com/lyms/platform/query/DiagnoseConfigQuery.java
View file @
100a284
| ... | ... | @@ -19,7 +19,7 @@ |
| 19 | 19 | private String id; |
| 20 | 20 | private String hospitalId; |
| 21 | 21 | //是否启用 0停用 1启用 |
| 22 | - private Integer enable; | |
| 22 | + private String enable; | |
| 23 | 23 | //默认是孕妇类型,type=2是儿童类型 |
| 24 | 24 | private String type; |
| 25 | 25 | private boolean typeb; |
| 26 | 26 | |
| ... | ... | @@ -77,11 +77,11 @@ |
| 77 | 77 | this.id = id; |
| 78 | 78 | } |
| 79 | 79 | |
| 80 | - public Integer getEnable() { | |
| 80 | + public String getEnable() { | |
| 81 | 81 | return enable; |
| 82 | 82 | } |
| 83 | 83 | |
| 84 | - public void setEnable(Integer enable) { | |
| 84 | + public void setEnable(String enable) { | |
| 85 | 85 | this.enable = enable; |
| 86 | 86 | } |
| 87 | 87 |
platform-operate-api/src/main/java/com/lyms/platform/operate/web/controller/AntenatalExaminationController.java
View file @
100a284
| ... | ... | @@ -24,6 +24,7 @@ |
| 24 | 24 | import com.lyms.platform.permission.service.CouponService; |
| 25 | 25 | import com.lyms.platform.permission.service.OrganizationService; |
| 26 | 26 | import com.lyms.platform.permission.service.UsersService; |
| 27 | +import com.lyms.platform.pojo.AntExHighRiskModel; | |
| 27 | 28 | import org.apache.commons.lang.StringUtils; |
| 28 | 29 | import org.slf4j.Logger; |
| 29 | 30 | import org.slf4j.LoggerFactory; |
| ... | ... | @@ -659,5 +660,32 @@ |
| 659 | 660 | return antenatalExaminationFacade.antexCheckCount(checkTime,loginState.getId()); |
| 660 | 661 | } |
| 661 | 662 | |
| 663 | + /** | |
| 664 | + * 增加产检高危手册(大同) | |
| 665 | + * @param antExHighRiskModel | |
| 666 | + * @param request | |
| 667 | + * @return | |
| 668 | + */ | |
| 669 | + @RequestMapping(method = RequestMethod.POST, value = "/addAntexHighRisk") | |
| 670 | + @ResponseBody | |
| 671 | + @TokenRequired | |
| 672 | + public BaseResponse addAntexHighRisk(@RequestBody AntExHighRiskModel antExHighRiskModel, HttpServletRequest request){ | |
| 673 | + LoginContext loginState = (LoginContext) request.getAttribute("loginContext"); | |
| 674 | + return antenatalExaminationFacade.addAntexHighRisk(antExHighRiskModel,loginState.getId()); | |
| 675 | + } | |
| 676 | + | |
| 677 | + /** | |
| 678 | + * 查询产检高危手册(大同) | |
| 679 | + * @param parentId | |
| 680 | + * @param request | |
| 681 | + * @return | |
| 682 | + */ | |
| 683 | + @RequestMapping(method = RequestMethod.GET, value = "/queryAntexHighRisk") | |
| 684 | + @ResponseBody | |
| 685 | + @TokenRequired | |
| 686 | + public BaseResponse queryAntexHighRisk(@RequestParam String parentId,HttpServletRequest request){ | |
| 687 | + LoginContext loginState = (LoginContext) request.getAttribute("loginContext"); | |
| 688 | + return antenatalExaminationFacade.queryAntexHighRisk(parentId,loginState.getId()); | |
| 689 | + } | |
| 662 | 690 | } |
platform-operate-api/src/main/java/com/lyms/platform/operate/web/facade/AntenatalExaminationFacade.java
View file @
100a284
| ... | ... | @@ -4130,7 +4130,7 @@ |
| 4130 | 4130 | antexListResult.setSieveStatus(sieveFacade.getSieveStatus(patients.getId(), hospitalId)); |
| 4131 | 4131 | DiagnoseConfigQuery diagnoseConfigQuery = new DiagnoseConfigQuery(); |
| 4132 | 4132 | diagnoseConfigQuery.setHospitalId(hospitalId); |
| 4133 | - diagnoseConfigQuery.setEnable(1); | |
| 4133 | + diagnoseConfigQuery.setEnable("1"); | |
| 4134 | 4134 | List <DiagnoseConfigModel> configModels = diagnoseConfigService.queryDiagnoseConfigs(diagnoseConfigQuery); |
| 4135 | 4135 | if (CollectionUtils.isNotEmpty(configModels) && StringUtils.isNotEmpty(configModels.get(0).getEnable())) { |
| 4136 | 4136 | antexListResult.setEnableConfig(configModels.get(0).getEnable()); |
| ... | ... | @@ -6628,5 +6628,33 @@ |
| 6628 | 6628 | return new BaseObjectResponse().setErrorcode(ErrorCodeConstants.SUCCESS).setErrormsg("成功").setData(data); |
| 6629 | 6629 | } |
| 6630 | 6630 | |
| 6631 | + public BaseResponse addAntexHighRisk(AntExHighRiskModel antExHighRiskModel,Integer userId){ | |
| 6632 | + String hospitalId = autoMatchFacade.getHospitalId(userId); | |
| 6633 | + antExHighRiskModel.setYn(1); | |
| 6634 | + antExHighRiskModel.setHospitalId(hospitalId); | |
| 6635 | + if (antExHighRiskModel.getId()!=null){ | |
| 6636 | + antExHighRiskModel.setModified(new Date()); | |
| 6637 | + Query updateQuery = Query.query(Criteria.where("_id").is(antExHighRiskModel.getId())); | |
| 6638 | + Update update = MongoConvertHelper | |
| 6639 | + .convertToNativeUpdate(ReflectionUtils.getUpdateField(antExHighRiskModel)); | |
| 6640 | + mongoTemplate.updateFirst(updateQuery, update, AntExHighRiskModel.class); | |
| 6641 | + | |
| 6642 | + }else { | |
| 6643 | + antExHighRiskModel.setCreated(new Date()); | |
| 6644 | + antExHighRiskModel.setModified(new Date()); | |
| 6645 | + mongoTemplate.insert(antExHighRiskModel); | |
| 6646 | + } | |
| 6647 | + return new BaseResponse().setErrorcode(ErrorCodeConstants.SUCCESS).setErrormsg("成功"); | |
| 6648 | + } | |
| 6649 | + | |
| 6650 | + public BaseResponse queryAntexHighRisk(String parentId,Integer userId){ | |
| 6651 | + String hospitalId = autoMatchFacade.getHospitalId(userId); | |
| 6652 | + List<AntExHighRiskModel> antExHighRiskModels= mongoTemplate.find(Query.query(Criteria.where("parentId").is(parentId).and("hospitalId").is(hospitalId).and("yn").is(1)), AntExHighRiskModel.class); | |
| 6653 | + | |
| 6654 | + AntExHighRiskModel antExHighRiskModel= CollectionUtils.isNotEmpty(antExHighRiskModels)?antExHighRiskModels.get(0):null; | |
| 6655 | + BaseResponse baseResponse= new BaseResponse(); | |
| 6656 | + baseResponse.setErrorcode(ErrorCodeConstants.SUCCESS).setErrormsg("成功").setObject(antExHighRiskModel); | |
| 6657 | + return baseResponse; | |
| 6658 | + } | |
| 6631 | 6659 | } |
platform-operate-api/src/main/java/com/lyms/platform/operate/web/facade/PatientFacade.java
View file @
100a284
| ... | ... | @@ -1634,7 +1634,8 @@ |
| 1634 | 1634 | Criteria criteria10 = Criteria.where("name").is("丙肝阳性"); |
| 1635 | 1635 | Criteria criteria11 = Criteria.where("name").is("乙肝大三阳"); |
| 1636 | 1636 | Criteria criteria12 = Criteria.where("name").is("乙肝小三阳"); |
| 1637 | - yn = Query.query(Criteria.where("yn").is(1).orOperator(criteria1, criteria2, criteria3, criteria4,criteria5,criteria6,criteria7,criteria8,criteria9,criteria10,criteria11,criteria12)); | |
| 1637 | + Criteria criteria13=Criteria.where("name").is("所有妊娠合井传染性疾病--如病毒性肝炎、梅毒、HV感染及艾滋病、结核病、重症盛染性肺炎、特殊病毒感染(H1N7、寨卡等)"); | |
| 1638 | + yn = Query.query(Criteria.where("yn").is(1).orOperator(criteria1, criteria2, criteria3, criteria4,criteria5,criteria6,criteria7,criteria8,criteria9,criteria10,criteria11,criteria12,criteria13)); | |
| 1638 | 1639 | } |
| 1639 | 1640 | List <BasicConfig> models = mongoTemplate.find(yn, BasicConfig.class); |
| 1640 | 1641 | List <String> rFactorList = new ArrayList <>(); |
| ... | ... | @@ -1747,6 +1748,8 @@ |
| 1747 | 1748 | PatientsQuery patientsQuery = new PatientsQuery();//complayRequest(riskPatientsQueryRequest, isHighRisk, type, userId, needPage, isRegion); |
| 1748 | 1749 | patientsQuery.setHospitalId(hospital); |
| 1749 | 1750 | patientsQuery.setNeed(needPage); |
| 1751 | + patientsQuery.setLimit(riskPatientsQueryRequest.getLimit()); | |
| 1752 | + patientsQuery.setPage(riskPatientsQueryRequest.getPage()); | |
| 1750 | 1753 | //查询符合条件的孕妇 |
| 1751 | 1754 | StopWatch stopWatch = new StopWatch("queryPatient1 -" + hospital); |
| 1752 | 1755 | stopWatch.start(); |