Commit 0cc498ff0829f580f24b371f3cf64267b2e4f3ff

Authored by wtt
1 parent 47ce9d9279

update

Showing 8 changed files with 217 additions and 13 deletions

platform-dal/src/main/java/com/lyms/platform/pojo/BabyCheckModel.java View file @ 0cc498f
... ... @@ -460,6 +460,56 @@
460 460 */
461 461 private String socialContactIA;
462 462 private String socialContactDQ;
  463 + //运动
  464 + private String exercise ;
  465 + //语言
  466 + private String language;
  467 + //社交
  468 + private String socialContact;
  469 + //大运动
  470 + private String alotExercise ;
  471 + //精细运动
  472 + private String fineExercise ;
  473 +
  474 + public String getExercise() {
  475 + return exercise;
  476 + }
  477 +
  478 + public void setExercise(String exercise) {
  479 + this.exercise = exercise;
  480 + }
  481 +
  482 + public String getLanguage() {
  483 + return language;
  484 + }
  485 +
  486 + public void setLanguage(String language) {
  487 + this.language = language;
  488 + }
  489 +
  490 + public String getSocialContact() {
  491 + return socialContact;
  492 + }
  493 +
  494 + public void setSocialContact(String socialContact) {
  495 + this.socialContact = socialContact;
  496 + }
  497 +
  498 + public String getAlotExercise() {
  499 + return alotExercise;
  500 + }
  501 +
  502 + public void setAlotExercise(String alotExercise) {
  503 + this.alotExercise = alotExercise;
  504 + }
  505 +
  506 + public String getFineExercise() {
  507 + return fineExercise;
  508 + }
  509 +
  510 + public void setFineExercise(String fineExercise) {
  511 + this.fineExercise = fineExercise;
  512 + }
463 513  
464 514 public String getExerciseIA() {
465 515 return exerciseIA;
platform-dal/src/main/java/com/lyms/platform/query/BabyModelQuery.java View file @ 0cc498f
... ... @@ -212,7 +212,13 @@
212 212 private Integer dueWeek;
213 213  
214 214 private Integer endCase;
  215 + /*
  216 + 结案日期
  217 + */
  218 + private Date endCaseTimeStart;
215 219  
  220 + private Date endCaseTimeEnd;
  221 +
216 222 private String areaId;
217 223  
218 224 private String provinceId;
... ... @@ -238,6 +244,30 @@
238 244  
239 245 private String numberCode;
240 246  
  247 + public Date getEndCaseTimeStart() {
  248 + return endCaseTimeStart;
  249 + }
  250 +
  251 + public void setEndCaseTimeStart(Date endCaseTimeStart) {
  252 + this.endCaseTimeStart = endCaseTimeStart;
  253 + }
  254 +
  255 + public Date getEndCaseTimeEnd() {
  256 + return endCaseTimeEnd;
  257 + }
  258 +
  259 + public void setEndCaseTimeEnd(Date endCaseTimeEnd) {
  260 + this.endCaseTimeEnd = endCaseTimeEnd;
  261 + }
  262 +
  263 + public Boolean getNull() {
  264 + return isNull;
  265 + }
  266 +
  267 + public void setNull(Boolean aNull) {
  268 + isNull = aNull;
  269 + }
  270 +
241 271 public String getNumberCode() {
242 272 return numberCode;
243 273 }
... ... @@ -1225,7 +1255,10 @@
1225 1255 Criteria cr = Criteria.where("nextDate").gte(nextDateStart).lte(nextDateEnd);
1226 1256 condition.andCondition(new MongoCondition(cr));
1227 1257 }
1228   -
  1258 + if (null != endCaseTimeStart && endCaseTimeEnd != null) {
  1259 + Criteria cr = Criteria.where("endCaseTime").gte(endCaseTimeStart).lte(endCaseTimeEnd);
  1260 + condition.andCondition(new MongoCondition(cr));
  1261 + }
1229 1262  
1230 1263 if (null != phoneOrcardNo) {
1231 1264 MongoCondition c1 = MongoCondition.newInstance();
platform-operate-api/src/main/java/com/lyms/platform/operate/web/controller/BabyBuildController.java View file @ 0cc498f
... ... @@ -213,6 +213,7 @@
213 213 @RequestParam(value = "endMonthAge", required = false) Integer endMonthAge,
214 214 @RequestParam(value = "birth", required = false) String birth,
215 215 @RequestParam(value = "nextDate", required = false) String nextDate,
  216 + @RequestParam(value = "endCaseTime", required = false) String endCaseTime,
216 217 @RequestParam(value = "expVip", required = false) Integer expVip,
217 218 @RequestParam(value = "serviceType", required = false) Integer serviceType,
218 219 @RequestParam(value = "serviceStatus", required = false) Integer serviceStatus,
... ... @@ -266,6 +267,7 @@
266 267 request.setMonthAgeEnd(endMonthAge);
267 268 request.setBirth(birth);
268 269 request.setNextDate(nextDate);
  270 + request.setEndCaseTime(endCaseTime);
269 271 request.setExpVip(expVip);
270 272 request.setHighRiskType(highRiskType);
271 273 request.setServiceType(serviceType);
... ... @@ -299,6 +301,19 @@
299 301 return babyBookbuildingFacade.queryBabyList(request, loginState.getId());
300 302 }
301 303  
  304 + /**
  305 + * 修改儿童档案结案状态
  306 + * @param babyManageRequest
  307 + * @param httpServletRequest
  308 + * @return
  309 + */
  310 + @RequestMapping(value = "/updateEndCase", method = RequestMethod.GET)
  311 + @ResponseBody
  312 + @TokenRequired
  313 + public BaseResponse updateEndCase(BabyCheckRequest babyManageRequest,HttpServletRequest httpServletRequest ){
  314 + LoginContext loginState = (LoginContext) httpServletRequest.getAttribute("loginContext");
  315 + return babyBookbuildingFacade.updateEndCase(babyManageRequest, loginState.getId());
  316 + }
302 317  
303 318 @RequestMapping(value = "/exportChilds", method = RequestMethod.GET)
304 319 @TokenRequired
platform-operate-api/src/main/java/com/lyms/platform/operate/web/facade/BabyBookbuildingFacade.java View file @ 0cc498f
... ... @@ -17,10 +17,7 @@
17 17 import com.lyms.platform.common.result.BaseObjectResponse;
18 18 import com.lyms.platform.common.result.BaseResponse;
19 19 import com.lyms.platform.common.utils.*;
20   -import com.lyms.platform.operate.web.request.BabyBookbuildingAddRequest;
21   -import com.lyms.platform.operate.web.request.BabyGuideSmsequest;
22   -import com.lyms.platform.operate.web.request.BabyManageRequest;
23   -import com.lyms.platform.operate.web.request.BookbuildingQueryRequest;
  20 +import com.lyms.platform.operate.web.request.*;
24 21 import com.lyms.platform.operate.web.result.*;
25 22 import com.lyms.platform.operate.web.service.BabyAfterVisitService;
26 23 import com.lyms.platform.operate.web.service.ITrackDownService;
27 24  
... ... @@ -818,14 +815,10 @@
818 815 return br;
819 816 }
820 817  
821   - private void getNumberCode(BabyModel model)
822   - {
823   - if (model.getMcertNo().length() > 8)
824   - {
  818 + private void getNumberCode(BabyModel model) {
  819 + if (model.getMcertNo().length() > 8) {
825 820 model.setNumberCode(model.getMcertNo().substring(model.getMcertNo().length() - 8));
826   - }
827   - else
828   - {
  821 + } else {
829 822 model.setNumberCode(model.getMcertNo());
830 823 }
831 824 }
... ... @@ -2284,6 +2277,32 @@
2284 2277 }
2285 2278  
2286 2279  
  2280 + public BaseResponse updateEndCase(BabyCheckRequest request, Integer userId) {
  2281 + BaseObjectResponse br = new BaseObjectResponse();
  2282 + BabyModel bm = new BabyModel();
  2283 + try {
  2284 + if (request == null || request.getBuildId() == null) {
  2285 + br.setErrorcode(ErrorCodeConstants.SYSTEM_ERROR);
  2286 + br.setErrormsg("失败");
  2287 + }
  2288 + //添加结案记录
  2289 + if (null != request.getEndCase()) {
  2290 + bm.setEndCase(request.getEndCase());
  2291 + if (1 == request.getEndCase()) {
  2292 + bm.setEndCaseTime(new Date());
  2293 + }
  2294 + }
  2295 +
  2296 + } catch (Exception e) {
  2297 + e.printStackTrace();
  2298 + }
  2299 + babyBookbuildingService.updateBabyBuild(bm, request.getBuildId());
  2300 + br.setErrorcode(ErrorCodeConstants.SUCCESS);
  2301 + br.setErrormsg("成功");
  2302 + return br;
  2303 + }
  2304 +
  2305 +
2287 2306 private List<BabyModel> getBabayListByCondition(BabyManageRequest request, boolean isPage, BabyModelQuery babyQuery) {
2288 2307  
2289 2308  
2290 2309  
... ... @@ -2322,7 +2341,19 @@
2322 2341 babyQuery.setNextDateEnd(DateUtil.parseYMD(dates[1]));
2323 2342 }
2324 2343 }
  2344 + //结案时间
  2345 + if (StringUtils.isNotEmpty(request.getEndCaseTime())) {
  2346 + String endCaseTime = request.getEndCaseTime();
  2347 + String[] dates = endCaseTime.split(" - ");
2325 2348  
  2349 + babyQuery.setEndCaseTimeStart(DateUtil.parseYMD(dates[0]));
  2350 + if (dates.length == 2) {
  2351 + // babyQuery.setEndCaseTimeEnd(DateUtil.parseYMD(dates[1]));
  2352 + babyQuery.setEndCaseTimeEnd(new Date(DateUtil.parseYMD(dates[1]).getTime() + 24 * 60 * 60 * 1000 - 1));
  2353 +
  2354 + }
  2355 + }
  2356 +
2326 2357 if (org.apache.commons.lang.StringUtils.isNotEmpty(request.getBuildDate())) {
2327 2358 babyQuery.setBuildDateStart(DateUtil.getSNDate(request.getBuildDate())[0]);
2328 2359 babyQuery.setBuildDateEnd(DateUtil.getSNDate(request.getBuildDate())[1]);
... ... @@ -4183,7 +4214,7 @@
4183 4214 public void autoGetBabyDiagnose() {
4184 4215  
4185 4216 Date end = new Date();
4186   - Date start = DateUtil.addDay(end,-2);
  4217 + Date start = DateUtil.addDay(end, -2);
4187 4218  
4188 4219 String lrrqStart = DateUtil.getYyyyMMddHHssmm(start);
4189 4220 String lrrqEnd = DateUtil.getYyyyMMddHHssmm(end);
platform-operate-api/src/main/java/com/lyms/platform/operate/web/facade/BabyCheckFacade.java View file @ 0cc498f
... ... @@ -456,7 +456,14 @@
456 456 model.setLanguageDQ(request.getLanguageDQ());
457 457 model.setMovementDQ(request.getMovementDQ());
458 458 model.setSocialContactDQ(request.getSocialContactDQ());
  459 + model.setExercise(request.getExercise());
  460 + model.setLanguage(request.getLanguage());
  461 + model.setSocialContact(request.getSocialContact());
  462 + model.setAlotExercise(request.getAlotExercise());
  463 + model.setFineExercise(request.getFineExercise());
459 464  
  465 +
  466 +
460 467 return model;
461 468 }
462 469  
... ... @@ -1404,6 +1411,7 @@
1404 1411 result.setName(model.getName());
1405 1412 result.setBirth(DateUtil.getyyyy_MM_dd(model.getBirth()));
1406 1413 result.setHospitalId(model.getHospitalId());
  1414 + result.setBlNo(model.getBlNo());
1407 1415 String hospital = "";
1408 1416 if (org.apache.commons.lang.StringUtils.isNotEmpty(model.getHospitalId())) {
1409 1417 Organization organization = organizationService.getOrganization(Integer.parseInt(model.getHospitalId()));
platform-operate-api/src/main/java/com/lyms/platform/operate/web/request/BabyCheckRequest.java View file @ 0cc498f
... ... @@ -402,6 +402,14 @@
402 402 private String exerciseIA;
403 403 private String exerciseDQ ;
404 404  
  405 + private String exercise ;
  406 + private String language;
  407 + private String socialContact;
  408 + //大运动
  409 + private String alotExercise ;
  410 + //精细运动
  411 + private String fineExercise ;
  412 +
405 413 /**
406 414 * 动作
407 415 */
... ... @@ -425,6 +433,46 @@
425 433 */
426 434 private String socialContactIA;
427 435 private String socialContactDQ;
  436 +
  437 + public String getSocialContact() {
  438 + return socialContact;
  439 + }
  440 +
  441 + public void setSocialContact(String socialContact) {
  442 + this.socialContact = socialContact;
  443 + }
  444 +
  445 + public String getExercise() {
  446 + return exercise;
  447 + }
  448 +
  449 + public void setExercise(String exercise) {
  450 + this.exercise = exercise;
  451 + }
  452 +
  453 + public String getAlotExercise() {
  454 + return alotExercise;
  455 + }
  456 +
  457 + public void setAlotExercise(String alotExercise) {
  458 + this.alotExercise = alotExercise;
  459 + }
  460 +
  461 + public String getFineExercise() {
  462 + return fineExercise;
  463 + }
  464 +
  465 + public void setFineExercise(String fineExercise) {
  466 + this.fineExercise = fineExercise;
  467 + }
  468 +
  469 + public String getLanguage() {
  470 + return language;
  471 + }
  472 +
  473 + public void setLanguage(String language) {
  474 + this.language = language;
  475 + }
428 476  
429 477 public String getExerciseIA() {
430 478 return exerciseIA;
platform-operate-api/src/main/java/com/lyms/platform/operate/web/request/BabyManageRequest.java View file @ 0cc498f
... ... @@ -30,6 +30,8 @@
30 30 private String birth;
31 31 //下次预约时间
32 32 private String nextDate;
  33 + //结案时间
  34 + private String endCaseTime;
33 35 //母亲联系方式
34 36 private String mphone;
35 37 //性别
... ... @@ -362,6 +364,14 @@
362 364  
363 365 public void setMonthAgeEnd(Integer monthAgeEnd) {
364 366 this.monthAgeEnd = monthAgeEnd;
  367 + }
  368 +
  369 + public String getEndCaseTime() {
  370 + return endCaseTime;
  371 + }
  372 +
  373 + public void setEndCaseTime(String endCaseTime) {
  374 + this.endCaseTime = endCaseTime;
365 375 }
366 376  
367 377 public String getNextDate() {
platform-operate-api/src/main/java/com/lyms/platform/operate/web/result/BabyChooseResult.java View file @ 0cc498f
... ... @@ -12,6 +12,15 @@
12 12 private String pid;
13 13 private String hospitalId;
14 14 private String hospitalName;
  15 + private String blNo;
  16 +
  17 + public String getBlNo() {
  18 + return blNo;
  19 + }
  20 +
  21 + public void setBlNo(String blNo) {
  22 + this.blNo = blNo;
  23 + }
15 24  
16 25 public String getHospitalName() {
17 26 return hospitalName;