Commit 288c4afbf7eea65edb953a8bfffa07629df73dc2
1 parent
2741119376
Exists in
master
and in
6 other branches
先心筛查
Showing 7 changed files with 314 additions and 43 deletions
- platform-dal/src/main/java/com/lyms/platform/pojo/BabyHeartModel.java
- platform-dal/src/main/java/com/lyms/platform/pojo/BabyHeartReviewModel.java
- platform-operate-api/src/main/java/com/lyms/platform/operate/web/controller/BabyHeartSieveController.java
- platform-operate-api/src/main/java/com/lyms/platform/operate/web/facade/BabyHeartSieveFacede.java
- platform-operate-api/src/main/java/com/lyms/platform/operate/web/request/BabyHeartSieveRequest.java
- platform-operate-api/src/main/java/com/lyms/platform/operate/web/result/BabyHeartModelResult.java
- platform-operate-api/src/main/java/com/lyms/platform/operate/web/result/BabyHeartModelView.java
platform-dal/src/main/java/com/lyms/platform/pojo/BabyHeartModel.java
View file @
288c4af
| ... | ... | @@ -17,7 +17,8 @@ |
| 17 | 17 | private String id; |
| 18 | 18 | |
| 19 | 19 | private String babyId; |
| 20 | - | |
| 20 | + // 1 72小时内检查 42天检查 | |
| 21 | + private Integer type; | |
| 21 | 22 | //心脏听诊 |
| 22 | 23 | private String heartTz; |
| 23 | 24 | |
| ... | ... | @@ -53,6 +54,14 @@ |
| 53 | 54 | private String checkDoctor; |
| 54 | 55 | private Date created; |
| 55 | 56 | private Date modified; |
| 57 | + | |
| 58 | + public Integer getType() { | |
| 59 | + return type; | |
| 60 | + } | |
| 61 | + | |
| 62 | + public void setType(Integer type) { | |
| 63 | + this.type = type; | |
| 64 | + } | |
| 56 | 65 | |
| 57 | 66 | public Date getSieveDate() { |
| 58 | 67 | return sieveDate; |
platform-dal/src/main/java/com/lyms/platform/pojo/BabyHeartReviewModel.java
View file @
288c4af
| 1 | +package com.lyms.platform.pojo; | |
| 2 | + | |
| 3 | +import com.lyms.platform.common.result.BaseModel; | |
| 4 | +import org.springframework.data.mongodb.core.mapping.Document; | |
| 5 | + | |
| 6 | +import java.util.Date; | |
| 7 | + | |
| 8 | +@Document(collection = "lyms_baby_heart_review") | |
| 9 | +public class BabyHeartReviewModel extends BaseModel { | |
| 10 | + //超声心动图 | |
| 11 | + private String csxdt; | |
| 12 | + //心电图 | |
| 13 | + private String xdt; | |
| 14 | + //X线 | |
| 15 | + private String xx; | |
| 16 | + | |
| 17 | + private String id; | |
| 18 | + private String babyId; | |
| 19 | + private String hospitalId; | |
| 20 | + private Date checkDate; | |
| 21 | + private Date created; | |
| 22 | + private Date modified; | |
| 23 | + private String checkDoctor; | |
| 24 | + | |
| 25 | + public String getCsxdt() { | |
| 26 | + return csxdt; | |
| 27 | + } | |
| 28 | + | |
| 29 | + public void setCsxdt(String csxdt) { | |
| 30 | + this.csxdt = csxdt; | |
| 31 | + } | |
| 32 | + | |
| 33 | + public String getXdt() { | |
| 34 | + return xdt; | |
| 35 | + } | |
| 36 | + | |
| 37 | + public void setXdt(String xdt) { | |
| 38 | + this.xdt = xdt; | |
| 39 | + } | |
| 40 | + | |
| 41 | + public String getXx() { | |
| 42 | + return xx; | |
| 43 | + } | |
| 44 | + | |
| 45 | + public void setXx(String xx) { | |
| 46 | + this.xx = xx; | |
| 47 | + } | |
| 48 | + | |
| 49 | + public String getId() { | |
| 50 | + return id; | |
| 51 | + } | |
| 52 | + | |
| 53 | + public void setId(String id) { | |
| 54 | + this.id = id; | |
| 55 | + } | |
| 56 | + | |
| 57 | + public String getBabyId() { | |
| 58 | + return babyId; | |
| 59 | + } | |
| 60 | + | |
| 61 | + public void setBabyId(String babyId) { | |
| 62 | + this.babyId = babyId; | |
| 63 | + } | |
| 64 | + | |
| 65 | + public String getHospitalId() { | |
| 66 | + return hospitalId; | |
| 67 | + } | |
| 68 | + | |
| 69 | + public void setHospitalId(String hospitalId) { | |
| 70 | + this.hospitalId = hospitalId; | |
| 71 | + } | |
| 72 | + | |
| 73 | + public Date getCheckDate() { | |
| 74 | + return checkDate; | |
| 75 | + } | |
| 76 | + | |
| 77 | + public void setCheckDate(Date checkDate) { | |
| 78 | + this.checkDate = checkDate; | |
| 79 | + } | |
| 80 | + | |
| 81 | + public Date getCreated() { | |
| 82 | + return created; | |
| 83 | + } | |
| 84 | + | |
| 85 | + public void setCreated(Date created) { | |
| 86 | + this.created = created; | |
| 87 | + } | |
| 88 | + | |
| 89 | + public Date getModified() { | |
| 90 | + return modified; | |
| 91 | + } | |
| 92 | + | |
| 93 | + public void setModified(Date modified) { | |
| 94 | + this.modified = modified; | |
| 95 | + } | |
| 96 | + | |
| 97 | + public String getCheckDoctor() { | |
| 98 | + return checkDoctor; | |
| 99 | + } | |
| 100 | + | |
| 101 | + public void setCheckDoctor(String checkDoctor) { | |
| 102 | + this.checkDoctor = checkDoctor; | |
| 103 | + } | |
| 104 | +} |
platform-operate-api/src/main/java/com/lyms/platform/operate/web/controller/BabyHeartSieveController.java
View file @
288c4af
| ... | ... | @@ -10,6 +10,7 @@ |
| 10 | 10 | import com.lyms.platform.operate.web.request.BabyHeartSieveRequest; |
| 11 | 11 | import com.lyms.platform.operate.web.request.BabySieveAddQhdRequest; |
| 12 | 12 | import com.lyms.platform.operate.web.request.BabySieveAddRequest; |
| 13 | +import com.lyms.platform.pojo.BabyHeartReviewModel; | |
| 13 | 14 | import com.lyms.platform.pojo.NewSieveLabModel; |
| 14 | 15 | import org.apache.commons.lang.StringUtils; |
| 15 | 16 | import org.springframework.beans.factory.annotation.Autowired; |
| 16 | 17 | |
| ... | ... | @@ -58,8 +59,16 @@ |
| 58 | 59 | } |
| 59 | 60 | |
| 60 | 61 | |
| 62 | + | |
| 61 | 63 | @TokenRequired |
| 62 | 64 | @ResponseBody |
| 65 | + @RequestMapping(value = "/queryBabyHeartRecords/{babyId}",method = RequestMethod.GET) | |
| 66 | + public BaseResponse queryBabyHeartRecords(@PathVariable("babyId") String babyId,HttpServletRequest request) { | |
| 67 | + return babyHeartSieveFacede.queryBabyHeartRecords(babyId); | |
| 68 | + } | |
| 69 | + | |
| 70 | + @TokenRequired | |
| 71 | + @ResponseBody | |
| 63 | 72 | @RequestMapping(value = "/queryBabyHeartList",method = RequestMethod.GET) |
| 64 | 73 | public BaseResponse queryBabyHeartList(@RequestParam(value = "queryNo", required = false) String queryNo, |
| 65 | 74 | @RequestParam(value = "sieveDate", required = false) String sieveDate, |
| ... | ... | @@ -96,5 +105,36 @@ |
| 96 | 105 | } |
| 97 | 106 | |
| 98 | 107 | |
| 108 | + @TokenRequired | |
| 109 | + @ResponseBody | |
| 110 | + @RequestMapping(value = "/addBabyHeartReview",method = RequestMethod.POST) | |
| 111 | + public BaseResponse addBabyHeartReview(@RequestBody @Valid BabyHeartReviewModel babyHeartReviewModel, HttpServletRequest request) { | |
| 112 | + LoginContext loginState = (LoginContext) request.getAttribute("loginContext"); | |
| 113 | + return babyHeartSieveFacede.addBabyHeartReview(babyHeartReviewModel, loginState.getId()); | |
| 114 | + } | |
| 115 | + @TokenRequired | |
| 116 | + @ResponseBody | |
| 117 | + @RequestMapping(value = "/queryBabyHeartReviewList",method = RequestMethod.POST) | |
| 118 | + public BaseResponse queryBabyHeartReviewList(@RequestParam(value = "queryNo", required = false) String queryNo, | |
| 119 | + @RequestParam(value = "checkDate", required = false) String checkDate, | |
| 120 | + @RequestParam("page") Integer page, | |
| 121 | + @RequestParam("limit") Integer limit, | |
| 122 | + HttpServletRequest request) { | |
| 123 | + LoginContext loginState = (LoginContext) request.getAttribute("loginContext"); | |
| 124 | + return babyHeartSieveFacede.queryBabyHeartReviewList(queryNo,checkDate,page,limit, loginState.getId()); | |
| 125 | + } | |
| 126 | + | |
| 127 | + @TokenRequired | |
| 128 | + @ResponseBody | |
| 129 | + @RequestMapping(value = "/queryBabyHeartReviewById/{id}",method = RequestMethod.GET) | |
| 130 | + public BaseResponse queryBabyHeartReviewById(@PathVariable("id") String id,HttpServletRequest request) { | |
| 131 | + return babyHeartSieveFacede.queryBabyHeartReviewById(id); | |
| 132 | + } | |
| 133 | + @TokenRequired | |
| 134 | + @ResponseBody | |
| 135 | + @RequestMapping(value = "/queryBabyHeartReviewView/{id}",method = RequestMethod.GET) | |
| 136 | + public BaseResponse queryBabyHeartReviewView(@PathVariable("id") String id,HttpServletRequest request) { | |
| 137 | + return babyHeartSieveFacede.queryBabyHeartReviewView(id); | |
| 138 | + } | |
| 99 | 139 | } |
platform-operate-api/src/main/java/com/lyms/platform/operate/web/facade/BabyHeartSieveFacede.java
View file @
288c4af
| 1 | 1 | package com.lyms.platform.operate.web.facade; |
| 2 | 2 | |
| 3 | -import com.lyms.platform.beans.MsgRequest; | |
| 4 | 3 | import com.lyms.platform.biz.service.*; |
| 5 | 4 | import com.lyms.platform.common.constants.ErrorCodeConstants; |
| 5 | +import com.lyms.platform.common.dao.BaseQuery; | |
| 6 | 6 | import com.lyms.platform.common.enums.*; |
| 7 | 7 | import com.lyms.platform.common.result.BaseListResponse; |
| 8 | 8 | import com.lyms.platform.common.result.BaseObjectResponse; |
| 9 | 9 | import com.lyms.platform.common.result.BaseResponse; |
| 10 | 10 | import com.lyms.platform.common.utils.*; |
| 11 | 11 | import com.lyms.platform.operate.web.request.BabyHeartSieveRequest; |
| 12 | -import com.lyms.platform.operate.web.request.BabySieveAddQhdRequest; | |
| 13 | -import com.lyms.platform.operate.web.request.BabySieveAddRequest; | |
| 14 | 12 | import com.lyms.platform.operate.web.result.*; |
| 15 | -import com.lyms.platform.operate.web.utils.BabySieveHandleTask; | |
| 16 | -import com.lyms.platform.operate.web.utils.BabySieveQhdHandleTask; | |
| 17 | -import com.lyms.platform.operate.web.utils.CommonsHelper; | |
| 18 | -import com.lyms.platform.permission.model.Organization; | |
| 19 | 13 | import com.lyms.platform.permission.service.OrganizationService; |
| 20 | 14 | import com.lyms.platform.permission.service.UsersService; |
| 21 | 15 | import com.lyms.platform.pojo.*; |
| 22 | 16 | import com.lyms.platform.query.*; |
| 23 | -import net.sf.json.JSONObject; | |
| 24 | 17 | import org.apache.commons.collections.CollectionUtils; |
| 25 | -import org.apache.commons.io.FileUtils; | |
| 26 | 18 | import org.apache.commons.lang.StringUtils; |
| 27 | 19 | import org.springframework.beans.factory.annotation.Autowired; |
| 28 | -import org.springframework.beans.factory.annotation.Qualifier; | |
| 29 | 20 | import org.springframework.data.domain.Sort; |
| 30 | 21 | import org.springframework.data.mongodb.core.MongoTemplate; |
| 31 | 22 | import org.springframework.data.mongodb.core.query.Criteria; |
| 32 | 23 | import org.springframework.data.mongodb.core.query.Query; |
| 33 | 24 | import org.springframework.data.mongodb.core.query.Update; |
| 34 | -import org.springframework.scheduling.concurrent.ThreadPoolTaskExecutor; | |
| 35 | 25 | import org.springframework.stereotype.Component; |
| 36 | 26 | |
| 37 | -import java.io.File; | |
| 38 | -import java.text.ParseException; | |
| 39 | -import java.text.SimpleDateFormat; | |
| 40 | 27 | import java.util.*; |
| 41 | -import java.util.concurrent.Callable; | |
| 42 | -import java.util.concurrent.Future; | |
| 43 | 28 | |
| 44 | 29 | /** |
| 45 | 30 | * 新生儿筛查 |
| 46 | 31 | |
| 47 | 32 | |
| 48 | 33 | |
| 49 | 34 | |
| 50 | 35 | |
| 51 | 36 | |
| 52 | 37 | |
| 53 | 38 | |
| 54 | 39 | |
| 55 | 40 | |
| ... | ... | @@ -47,43 +32,22 @@ |
| 47 | 32 | */ |
| 48 | 33 | @Component |
| 49 | 34 | public class BabyHeartSieveFacede { |
| 50 | - | |
| 51 | 35 | @Autowired |
| 52 | - @Qualifier("commonThreadPool") | |
| 53 | - private ThreadPoolTaskExecutor commonThreadPool; | |
| 54 | - @Autowired | |
| 55 | - private BasicConfigService basicConfigService; | |
| 56 | - @Autowired | |
| 57 | 36 | private AutoMatchFacade autoMatchFacade; |
| 37 | + | |
| 58 | 38 | @Autowired |
| 59 | - private PatientsService patientsService; | |
| 60 | - @Autowired | |
| 61 | - private MatDeliverService matDeliverService; | |
| 62 | - @Autowired | |
| 63 | 39 | private BabyHeartSieveService babyHeartSieveService; |
| 40 | + | |
| 64 | 41 | @Autowired |
| 65 | - private BabySieveQhdService babySieveQhdService; | |
| 66 | - @Autowired | |
| 67 | - private BabyBookbuildingService babyBookbuildingService; | |
| 68 | - @Autowired | |
| 69 | 42 | private OrganizationService organizationService; |
| 43 | + | |
| 70 | 44 | @Autowired |
| 71 | - private OperateLogFacade operateLogFacade; | |
| 72 | - @Autowired | |
| 73 | - private AntenatalExaminationFacade antenatalExaminationFacade; | |
| 74 | - @Autowired | |
| 75 | 45 | private BabyService babyService; |
| 76 | 46 | @Autowired |
| 77 | 47 | private MongoTemplate mongoTemplate; |
| 78 | 48 | @Autowired |
| 79 | - private SmsConfigFacade smsConfigFacade; | |
| 80 | - @Autowired | |
| 81 | 49 | private UsersService usersService; |
| 82 | - @Autowired | |
| 83 | - private LhBabyEyeCheckService lhBabyEyeCheckService; | |
| 84 | 50 | |
| 85 | - | |
| 86 | - | |
| 87 | 51 | public BaseResponse addBabyHeartSieve(BabyHeartSieveRequest babyHeartSieveRequest, Integer userId) { |
| 88 | 52 | String hospitalId = autoMatchFacade.getHospitalId(userId); |
| 89 | 53 | BabyHeartModel babyHeartModel = babyHeartSieveRequest.convertToDataModel(); |
| ... | ... | @@ -175,6 +139,7 @@ |
| 175 | 139 | data.put("mommyName",babyModel.getMname()); |
| 176 | 140 | data.put("mommyPhone",babyModel.getMphone()); |
| 177 | 141 | data.put("mommyCardNo",babyModel.getMcertNo()); |
| 142 | + data.put("type",babyHeartModel.getType() == null ? "" : (babyHeartModel.getType() == 1 ? "72小时内": "42天")); | |
| 178 | 143 | data.put("sieveDate",DateUtil.getyyyy_MM_dd(babyHeartModel.getSieveDate())); |
| 179 | 144 | data.put("sieveResult",babyHeartModel.getSieveResult() == null ? "" : (babyHeartModel.getSieveResult() == 1 ? "异常": "未见异常")); |
| 180 | 145 | data.put("diagnoseResult",babyHeartModel.getDiagnoseResult() == null ? "" : (babyHeartModel.getDiagnoseResult() == 1 ? "异常": "未见异常")); |
| ... | ... | @@ -207,7 +172,24 @@ |
| 207 | 172 | return new BaseObjectResponse().setErrorcode(ErrorCodeConstants.SUCCESS) |
| 208 | 173 | .setErrormsg(ErrorCodeConstants.SUCCESS_DESCRIPTION).setData(datas); |
| 209 | 174 | } |
| 210 | - | |
| 175 | + public BaseResponse queryBabyHeartRecords(String babyId) { | |
| 176 | + List<Map> datas = new ArrayList<>(); | |
| 177 | + BabyHeartSieveQuery query = new BabyHeartSieveQuery(); | |
| 178 | + query.setBabyId(babyId); | |
| 179 | + List<BabyHeartModel> babyHeartModelList = babyHeartSieveService.getBabyHeartQuery(query); | |
| 180 | + if (CollectionUtils.isNotEmpty(babyHeartModelList)) { | |
| 181 | + for (BabyHeartModel heartModel : babyHeartModelList) | |
| 182 | + { | |
| 183 | + Map data = new HashMap(); | |
| 184 | + data.put("id",heartModel.getId()); | |
| 185 | + data.put("sieveDate",DateUtil.getyyyy_MM_dd(heartModel.getSieveDate())); | |
| 186 | + data.put("type",heartModel.getType() == null ? "" : (heartModel.getType() == 1 ? "72小时内": "42天")); | |
| 187 | + datas.add(data); | |
| 188 | + } | |
| 189 | + } | |
| 190 | + return new BaseObjectResponse().setErrorcode(ErrorCodeConstants.SUCCESS) | |
| 191 | + .setErrormsg(ErrorCodeConstants.SUCCESS_DESCRIPTION).setData(datas); | |
| 192 | + } | |
| 211 | 193 | public BaseResponse queryBabyHeartView(String id) { |
| 212 | 194 | BabyHeartModel babyHeartModel = babyHeartSieveService.getBabyHeartSieveId(id); |
| 213 | 195 | BabyHeartModelView view = new BabyHeartModelView(); |
| 214 | 196 | |
| ... | ... | @@ -225,11 +207,124 @@ |
| 225 | 207 | hd.append(","); |
| 226 | 208 | } |
| 227 | 209 | } |
| 210 | + view.setType(babyHeartModel.getType() == null ? "" : (babyHeartModel.getType() == 1 ? "72小时内": "42天")); | |
| 228 | 211 | view.setDiagnoseItem(hd.toString()); |
| 229 | 212 | view.setCheckDoctor(usersService.getUsers(Integer.parseInt(babyHeartModel.getCheckDoctor())).getName()); |
| 230 | 213 | view.setHospitalName(organizationService.getOrganizationName(babyHeartModel.getHospitalId())); |
| 231 | 214 | return new BaseObjectResponse().setErrorcode(ErrorCodeConstants.SUCCESS) |
| 232 | 215 | .setErrormsg(ErrorCodeConstants.SUCCESS_DESCRIPTION).setData(view); |
| 233 | 216 | } |
| 217 | + | |
| 218 | + public BaseResponse addBabyHeartReview(BabyHeartReviewModel babyHeartReviewModel, Integer userId) { | |
| 219 | + String hospitalId = autoMatchFacade.getHospitalId(userId); | |
| 220 | + if (StringUtils.isNotEmpty(babyHeartReviewModel.getId())) | |
| 221 | + { | |
| 222 | + Query query = Query.query(Criteria.where("id").is(babyHeartReviewModel.getId())); | |
| 223 | + babyHeartReviewModel.setModified(new Date()); | |
| 224 | + Update update = MongoConvertHelper | |
| 225 | + .convertToNativeUpdate(ReflectionUtils.getUpdateField(babyHeartReviewModel)); | |
| 226 | + mongoTemplate.updateFirst(query, update, BabyHeartReviewModel.class); | |
| 227 | + } | |
| 228 | + else | |
| 229 | + { | |
| 230 | + babyHeartReviewModel.setModified(new Date()); | |
| 231 | + babyHeartReviewModel.setCreated(new Date()); | |
| 232 | + babyHeartReviewModel.setHospitalId(hospitalId); | |
| 233 | + mongoTemplate.insert(babyHeartReviewModel); | |
| 234 | + } | |
| 235 | + return new BaseObjectResponse().setErrorcode(ErrorCodeConstants.SUCCESS) | |
| 236 | + .setErrormsg(ErrorCodeConstants.SUCCESS_DESCRIPTION); | |
| 237 | + } | |
| 238 | + | |
| 239 | + public BaseResponse queryBabyHeartReviewList(String queryNo, String checkDate, Integer page, Integer limit, Integer userId) { | |
| 240 | + List<Map> list = new ArrayList<>(); | |
| 241 | + String hospitalId = autoMatchFacade.getHospitalId(userId); | |
| 242 | + List<String> babyList = new ArrayList<>(); | |
| 243 | + if (StringUtils.isNotEmpty(queryNo)) | |
| 244 | + { | |
| 245 | + BabyModelQuery babyQuery = new BabyModelQuery(); | |
| 246 | + babyQuery.setHospitalId(hospitalId); | |
| 247 | + babyQuery.setQueryNo(queryNo); | |
| 248 | + List<BabyModel> babyModels = babyService.queryBabyWithQuery(babyQuery); | |
| 249 | + if (CollectionUtils.isNotEmpty(babyModels)) | |
| 250 | + { | |
| 251 | + for (BabyModel babyModel : babyModels) | |
| 252 | + { | |
| 253 | + babyList.add(babyModel.getId()); | |
| 254 | + } | |
| 255 | + } | |
| 256 | + else | |
| 257 | + { | |
| 258 | + return new BaseObjectResponse().setErrorcode(ErrorCodeConstants.SUCCESS) | |
| 259 | + .setErrormsg(ErrorCodeConstants.SUCCESS_DESCRIPTION).setData(list); | |
| 260 | + } | |
| 261 | + } | |
| 262 | + Query query = new Query(); | |
| 263 | + if (StringUtils.isNotEmpty(checkDate)) | |
| 264 | + { | |
| 265 | + String[] arrs = checkDate.split(" - "); | |
| 266 | + Date startDate = DateUtil.getDayFirstSecond(DateUtil.parseYMD(arrs[0])); | |
| 267 | + Date endDate = DateUtil.getDayLastSecond(DateUtil.parseYMD(arrs[1])); | |
| 268 | + query.addCriteria(Criteria.where("checkDate").gte(startDate).lte(endDate)); | |
| 269 | + } | |
| 270 | + | |
| 271 | + if (CollectionUtils.isNotEmpty(babyList)) | |
| 272 | + { | |
| 273 | + query.addCriteria(Criteria.where("babyId").in(babyList)); | |
| 274 | + } | |
| 275 | + query.with(new Sort(Sort.Direction.DESC, "created")); | |
| 276 | + long count = mongoTemplate.count(query, BabyHeartReviewModel.class); | |
| 277 | + BaseQuery baseQuery = new BaseQuery(); | |
| 278 | + baseQuery.mysqlBuild((int) count); | |
| 279 | + baseQuery.setPage(page); | |
| 280 | + baseQuery.setLimit(limit); | |
| 281 | + query.skip(baseQuery.getOffset()).limit(baseQuery.getLimit()); | |
| 282 | + List<BabyHeartReviewModel> babyHeartModelList = mongoTemplate.find(query, BabyHeartReviewModel.class); | |
| 283 | + if (CollectionUtils.isNotEmpty(babyHeartModelList)) | |
| 284 | + { | |
| 285 | + for (BabyHeartReviewModel model : babyHeartModelList) | |
| 286 | + { | |
| 287 | + Map data = new HashMap(); | |
| 288 | + BabyModel babyModel = babyService.getOneBabyById(model.getBabyId()); | |
| 289 | + data.put("babyName",babyModel.getName()); | |
| 290 | + data.put("babyAge",DateUtil.getAge2(babyModel.getBirth(),new Date())); | |
| 291 | + data.put("mommyName",babyModel.getMname()); | |
| 292 | + data.put("mommyPhone",babyModel.getMphone()); | |
| 293 | + data.put("mommyCardNo",babyModel.getMcertNo()); | |
| 294 | + data.put("xdt",model.getXdt()); | |
| 295 | + data.put("xx",model.getXx()); | |
| 296 | + data.put("csxdt",model.getCsxdt()); | |
| 297 | + data.put("checkDate",DateUtil.getyyyy_MM_dd(model.getCheckDate())); | |
| 298 | + list.add(data); | |
| 299 | + } | |
| 300 | + } | |
| 301 | + return new BaseListResponse().setErrorcode(ErrorCodeConstants.SUCCESS) | |
| 302 | + .setErrormsg(ErrorCodeConstants.SUCCESS_DESCRIPTION).setData(list).setPageInfo(baseQuery.getPageInfo()); | |
| 303 | + } | |
| 304 | + | |
| 305 | + public BaseResponse queryBabyHeartReviewById(String id) { | |
| 306 | + Query query = new Query(); | |
| 307 | + query.addCriteria(Criteria.where("id").is(id)); | |
| 308 | + BabyHeartReviewModel one = mongoTemplate.findOne(query, BabyHeartReviewModel.class); | |
| 309 | + return new BaseObjectResponse().setErrorcode(ErrorCodeConstants.SUCCESS) | |
| 310 | + .setErrormsg(ErrorCodeConstants.SUCCESS_DESCRIPTION).setData(one); | |
| 311 | + } | |
| 312 | + | |
| 313 | + public BaseResponse queryBabyHeartReviewView(String id) { | |
| 314 | + Query query = new Query(); | |
| 315 | + query.addCriteria(Criteria.where("id").is(id)); | |
| 316 | + BabyHeartReviewModel one = mongoTemplate.findOne(query, BabyHeartReviewModel.class); | |
| 317 | + Map data = new HashMap(); | |
| 318 | + data.put("csxdt",one.getCsxdt()); | |
| 319 | + data.put("xdt",one.getXdt()); | |
| 320 | + data.put("xx",one.getXx()); | |
| 321 | + data.put("checkDate",DateUtil.getyyyy_MM_dd(one.getCheckDate())); | |
| 322 | + data.put("checkDoctor",usersService.getUsers(Integer.parseInt(one.getCheckDoctor())).getName()); | |
| 323 | + data.put("hospitalName",organizationService.getOrganizationName(one.getHospitalId())); | |
| 324 | + return new BaseObjectResponse().setErrorcode(ErrorCodeConstants.SUCCESS) | |
| 325 | + .setErrormsg(ErrorCodeConstants.SUCCESS_DESCRIPTION).setData(data); | |
| 326 | + } | |
| 327 | + | |
| 328 | + | |
| 234 | 329 | } |
platform-operate-api/src/main/java/com/lyms/platform/operate/web/request/BabyHeartSieveRequest.java
View file @
288c4af
| ... | ... | @@ -15,6 +15,9 @@ |
| 15 | 15 | |
| 16 | 16 | private String babyId; |
| 17 | 17 | |
| 18 | + // 1 72小时内检查 42天检查 | |
| 19 | + private Integer type; | |
| 20 | + | |
| 18 | 21 | //心脏听诊 |
| 19 | 22 | private String heartTz; |
| 20 | 23 | |
| ... | ... | @@ -74,6 +77,7 @@ |
| 74 | 77 | babyHeartModel.setCheckDoctor(checkDoctor); |
| 75 | 78 | babyHeartModel.setHospitalId(hospitalId); |
| 76 | 79 | babyHeartModel.setBabyId(babyId); |
| 80 | + babyHeartModel.setType(type); | |
| 77 | 81 | babyHeartModel.setSieveDate(DateUtil.parseYMD(sieveDate)); |
| 78 | 82 | return babyHeartModel; |
| 79 | 83 | } |
platform-operate-api/src/main/java/com/lyms/platform/operate/web/result/BabyHeartModelResult.java
View file @
288c4af
| ... | ... | @@ -7,7 +7,8 @@ |
| 7 | 7 | private String id; |
| 8 | 8 | |
| 9 | 9 | private String babyId; |
| 10 | - | |
| 10 | + // 1 72小时内检查 42天检查 | |
| 11 | + private Integer type; | |
| 11 | 12 | //心脏听诊 |
| 12 | 13 | private String heartTz; |
| 13 | 14 | |
| ... | ... | @@ -41,6 +42,14 @@ |
| 41 | 42 | |
| 42 | 43 | private String hospitalId; |
| 43 | 44 | private String checkDoctor; |
| 45 | + | |
| 46 | + public Integer getType() { | |
| 47 | + return type; | |
| 48 | + } | |
| 49 | + | |
| 50 | + public void setType(Integer type) { | |
| 51 | + this.type = type; | |
| 52 | + } | |
| 44 | 53 | |
| 45 | 54 | public String getId() { |
| 46 | 55 | return id; |
platform-operate-api/src/main/java/com/lyms/platform/operate/web/result/BabyHeartModelView.java
View file @
288c4af
| ... | ... | @@ -40,6 +40,16 @@ |
| 40 | 40 | |
| 41 | 41 | private String hospitalName; |
| 42 | 42 | private String checkDoctor; |
| 43 | + // 1 72小时内检查 42天检查 | |
| 44 | + private String type; | |
| 45 | + | |
| 46 | + public String getType() { | |
| 47 | + return type; | |
| 48 | + } | |
| 49 | + | |
| 50 | + public void setType(String type) { | |
| 51 | + this.type = type; | |
| 52 | + } | |
| 43 | 53 | |
| 44 | 54 | public String getId() { |
| 45 | 55 | return id; |