Commit 9df21dc383a9d29da8d25870a1a64833ae7942af

Authored by liquanyu
1 parent 7092403618

隆化功能开发

Showing 13 changed files with 422 additions and 3 deletions

platform-dal/src/main/java/com/lyms/platform/pojo/BabyCheckModel.java View file @ 9df21dc
... ... @@ -742,6 +742,10 @@
742 742 */
743 743 private String lhaxisr;
744 744  
  745 + //屈光筛查
  746 + private Map<String, String> qgscResult;
  747 +
  748 +
745 749 private String sf;//是否失访
746 750 private String sfRea;//失访原因
747 751 private String xb;//胸部
... ... @@ -769,6 +773,14 @@
769 773 private Integer visitType;
770 774 //选项指标记录
771 775 private List<Object> recordChoice;
  776 +
  777 + public Map<String, String> getQgscResult() {
  778 + return qgscResult;
  779 + }
  780 +
  781 + public void setQgscResult(Map<String, String> qgscResult) {
  782 + this.qgscResult = qgscResult;
  783 + }
772 784  
773 785 public List<Object> getRecordChoice() {
774 786 return recordChoice;
platform-dal/src/main/java/com/lyms/platform/pojo/LhBabyEyeCheck.java View file @ 9df21dc
... ... @@ -329,7 +329,16 @@
329 329 * 视力低常 其他
330 330 */
331 331 private String lhsldcqt;
  332 + //屈光筛查
  333 + private Map<String, String> qgscResult;
332 334  
  335 + public Map<String, String> getQgscResult() {
  336 + return qgscResult;
  337 + }
  338 +
  339 + public void setQgscResult(Map<String, String> qgscResult) {
  340 + this.qgscResult = qgscResult;
  341 + }
333 342 public String getGlobal() {
334 343 return global;
335 344 }
platform-dal/src/main/java/com/lyms/platform/pojo/LhBabyGravidityEndingTabModel.java View file @ 9df21dc
... ... @@ -3,6 +3,7 @@
3 3 import org.springframework.data.mongodb.core.mapping.Document;
4 4  
5 5 import java.util.Date;
  6 +import java.util.List;
6 7  
7 8 /**
8 9 * 隆化-妊娠结局记录表
... ... @@ -63,6 +64,9 @@
63 64 //其他
64 65 private String gravidityEndingOther;
65 66  
  67 + //妊娠高危
  68 + private List<Integer> gravidityHigh;
  69 +
66 70 //性别(LhSexEnum)
67 71 private String babySex;
68 72 //出生体重
... ... @@ -105,6 +109,13 @@
105 109 //随访者签名
106 110 private String visitSign;
107 111  
  112 + public List<Integer> getGravidityHigh() {
  113 + return gravidityHigh;
  114 + }
  115 +
  116 + public void setGravidityHigh(List<Integer> gravidityHigh) {
  117 + this.gravidityHigh = gravidityHigh;
  118 + }
108 119  
109 120 public String getBuildId() {
110 121 return buildId;
platform-dal/src/main/java/com/lyms/platform/pojo/LhServiceFollowModel.java View file @ 9df21dc
  1 +package com.lyms.platform.pojo;
  2 +
  3 +import org.springframework.data.mongodb.core.mapping.Document;
  4 +
  5 +import java.util.Date;
  6 +
  7 +/**
  8 + * 隆化-孕前优生男女服务跟踪
  9 + *
  10 + * @author shiy
  11 + */
  12 +@Document(collection = "lyms_service_follow")
  13 +public class LhServiceFollowModel {
  14 + //是否删除(YnEnums)
  15 + private Integer yn;
  16 + private String id;
  17 + //姓名
  18 + private String name;
  19 + //0 女 1 男
  20 + private Integer sex;
  21 +
  22 + //检查结果
  23 + private String checkResult;
  24 +
  25 + //检查日期
  26 + private Date checkDate;
  27 +
  28 + //检查医生
  29 + private String checkDoctor;
  30 +
  31 + //治疗情况
  32 + private String treat;
  33 +
  34 + //治疗时间
  35 + private Date treatDate;
  36 +
  37 + //治疗时间
  38 + private Date treatDoctor;
  39 +
  40 + //处治结果 1 治愈 2 转诊
  41 + private Integer handleResult;
  42 +
  43 + //处治结果日期
  44 + private Date handleDate;
  45 +
  46 + //处治结果医生
  47 + private String handleDoctor;
  48 +
  49 + //孕前优生的档案id
  50 + private String buildId;
  51 +
  52 + private String hospitalId;
  53 +
  54 + private Date modified;
  55 + //记录创建时间
  56 + private Date created;
  57 +
  58 + public Date getModified() {
  59 + return modified;
  60 + }
  61 +
  62 + public void setModified(Date modified) {
  63 + this.modified = modified;
  64 + }
  65 +
  66 + public String getHospitalId() {
  67 + return hospitalId;
  68 + }
  69 +
  70 + public void setHospitalId(String hospitalId) {
  71 + this.hospitalId = hospitalId;
  72 + }
  73 +
  74 + public String getId() {
  75 + return id;
  76 + }
  77 +
  78 + public void setId(String id) {
  79 + this.id = id;
  80 + }
  81 +
  82 + public Integer getYn() {
  83 + return yn;
  84 + }
  85 +
  86 + public void setYn(Integer yn) {
  87 + this.yn = yn;
  88 + }
  89 +
  90 + public String getName() {
  91 + return name;
  92 + }
  93 +
  94 + public void setName(String name) {
  95 + this.name = name;
  96 + }
  97 +
  98 + public Integer getSex() {
  99 + return sex;
  100 + }
  101 +
  102 + public void setSex(Integer sex) {
  103 + this.sex = sex;
  104 + }
  105 +
  106 + public String getCheckResult() {
  107 + return checkResult;
  108 + }
  109 +
  110 + public void setCheckResult(String checkResult) {
  111 + this.checkResult = checkResult;
  112 + }
  113 +
  114 + public Date getCheckDate() {
  115 + return checkDate;
  116 + }
  117 +
  118 + public void setCheckDate(Date checkDate) {
  119 + this.checkDate = checkDate;
  120 + }
  121 +
  122 + public String getCheckDoctor() {
  123 + return checkDoctor;
  124 + }
  125 +
  126 + public void setCheckDoctor(String checkDoctor) {
  127 + this.checkDoctor = checkDoctor;
  128 + }
  129 +
  130 + public String getTreat() {
  131 + return treat;
  132 + }
  133 +
  134 + public void setTreat(String treat) {
  135 + this.treat = treat;
  136 + }
  137 +
  138 + public Date getTreatDate() {
  139 + return treatDate;
  140 + }
  141 +
  142 + public void setTreatDate(Date treatDate) {
  143 + this.treatDate = treatDate;
  144 + }
  145 +
  146 + public Date getTreatDoctor() {
  147 + return treatDoctor;
  148 + }
  149 +
  150 + public void setTreatDoctor(Date treatDoctor) {
  151 + this.treatDoctor = treatDoctor;
  152 + }
  153 +
  154 + public Integer getHandleResult() {
  155 + return handleResult;
  156 + }
  157 +
  158 + public void setHandleResult(Integer handleResult) {
  159 + this.handleResult = handleResult;
  160 + }
  161 +
  162 + public Date getHandleDate() {
  163 + return handleDate;
  164 + }
  165 +
  166 + public void setHandleDate(Date handleDate) {
  167 + this.handleDate = handleDate;
  168 + }
  169 +
  170 + public String getHandleDoctor() {
  171 + return handleDoctor;
  172 + }
  173 +
  174 + public void setHandleDoctor(String handleDoctor) {
  175 + this.handleDoctor = handleDoctor;
  176 + }
  177 +
  178 + public String getBuildId() {
  179 + return buildId;
  180 + }
  181 +
  182 + public void setBuildId(String buildId) {
  183 + this.buildId = buildId;
  184 + }
  185 +
  186 + public Date getCreated() {
  187 + return created;
  188 + }
  189 +
  190 + public void setCreated(Date created) {
  191 + this.created = created;
  192 + }
  193 +}
platform-operate-api/src/main/java/com/lyms/platform/operate/web/controller/LhServiceFollowController.java View file @ 9df21dc
  1 +package com.lyms.platform.operate.web.controller;
  2 +
  3 +import com.lyms.platform.common.annotation.TokenRequired;
  4 +import com.lyms.platform.common.base.BaseController;
  5 +import com.lyms.platform.common.constants.ErrorCodeConstants;
  6 +import com.lyms.platform.common.result.BaseResponse;
  7 +import com.lyms.platform.operate.web.facade.LhBabyPregnancyFollowTabFacade;
  8 +import com.lyms.platform.operate.web.facade.LhServiceFollowFacade;
  9 +import com.lyms.platform.pojo.LhBabyPregnancyFollowTabModel;
  10 +import com.lyms.platform.pojo.LhServiceFollowModel;
  11 +import com.lyms.platform.query.LhBabyPregnancyFollowTabQuery;
  12 +import org.springframework.beans.factory.annotation.Autowired;
  13 +import org.springframework.stereotype.Controller;
  14 +import org.springframework.web.bind.annotation.*;
  15 +
  16 +import javax.servlet.http.HttpServletRequest;
  17 +
  18 +/**
  19 + * 隆化-孕前优生服务随访表
  20 + *
  21 + * Created by shy on 2021/10/20
  22 + */
  23 +@Controller
  24 +public class LhServiceFollowController extends BaseController {
  25 +
  26 + @Autowired
  27 + private LhServiceFollowFacade lhServiceFollowFacade;
  28 +
  29 +
  30 +
  31 + //查询-隆化-早孕随访记录表-多胎列表
  32 + @RequestMapping(method = RequestMethod.GET, value = "/queryLhServiceFollow/{buildId}")
  33 + @ResponseBody
  34 + @TokenRequired
  35 + public BaseResponse queryLhServiceFollow(@PathVariable("buildId") String buildId, HttpServletRequest request) {
  36 +
  37 + return lhServiceFollowFacade.queryLhServiceFollow(buildId);
  38 + }
  39 +
  40 + //增加/修改-隆化-孕前优生服务服务跟踪
  41 + @RequestMapping(method = RequestMethod.POST, value = "/addOrUpdateServiceFollow")
  42 + @ResponseBody
  43 + @TokenRequired
  44 + public BaseResponse addOrUpdateServiceFollow(@RequestBody LhServiceFollowModel lhServiceFollowModel,
  45 + HttpServletRequest request) {
  46 + return lhServiceFollowFacade.addOrUpdateServiceFollow(lhServiceFollowModel,getUserId(request));
  47 + }
  48 +
  49 + //删除-隆化--孕前优生服务服务跟踪
  50 + @RequestMapping(method = RequestMethod.DELETE, value = "/delServiceFollow/{id}")
  51 + @ResponseBody
  52 + @TokenRequired
  53 + public BaseResponse delServiceFollow(@PathVariable("id") String id,HttpServletRequest request) {
  54 + lhServiceFollowFacade.delServiceFollow(id,getUserId(request));
  55 + return new BaseResponse().setErrorcode(ErrorCodeConstants.SUCCESS).setErrormsg("成功");
  56 + }
  57 +
  58 +
  59 +}
platform-operate-api/src/main/java/com/lyms/platform/operate/web/facade/BabyCheckFacade.java View file @ 9df21dc
... ... @@ -412,6 +412,7 @@
412 412 private BabyCheckModel getBabyCheckModel(BabyCheckRequest request) {
413 413  
414 414 BabyCheckModel model = new BabyCheckModel();
  415 + model.setQgscResult(request.getQgscResult());
415 416 model.setXtxblz(request.getXtxblz());
416 417 model.setEljy(request.getEljy());
417 418 model.setEdfs(request.getEdfs());
... ... @@ -2450,6 +2451,7 @@
2450 2451 */
2451 2452 private BabyCheckResult getBabyCheckResult(BabyCheckModel checkModel, BabyModel babyMode) {
2452 2453 BabyCheckResult model = new BabyCheckResult();
  2454 + model.setQgscResult(model.getQgscResult());
2453 2455 model.setXtxblz(checkModel.getXtxblz());
2454 2456 model.setDoctorSign(checkModel.getDoctorSign());
2455 2457 model.setPatientSign(checkModel.getPatientSign());
platform-operate-api/src/main/java/com/lyms/platform/operate/web/facade/LhBabyEyeCheckFacade.java View file @ 9df21dc
... ... @@ -610,6 +610,7 @@
610 610 map.put("lhdsr",checkModel.getLhdsr());
611 611 map.put("lhdcr",checkModel.getLhdcr());
612 612 map.put("lhaxisr",checkModel.getLhaxisr());
  613 + map.put("qgscResult",checkModel.getQgscResult());
613 614 }
614 615 BaseResponse baseResponse=new BaseResponse();
615 616 baseResponse.setErrormsg("成功");
platform-operate-api/src/main/java/com/lyms/platform/operate/web/facade/LhServiceFollowFacade.java View file @ 9df21dc
  1 +package com.lyms.platform.operate.web.facade;
  2 +
  3 +import com.lyms.platform.biz.service.BasicConfigService;
  4 +import com.lyms.platform.common.constants.ErrorCodeConstants;
  5 +import com.lyms.platform.common.dao.BaseMongoDAOImpl;
  6 +import com.lyms.platform.common.dao.operator.MongoCondition;
  7 +import com.lyms.platform.common.dao.operator.MongoOper;
  8 +import com.lyms.platform.common.dao.operator.MongoQuery;
  9 +import com.lyms.platform.common.enums.OptActionEnums;
  10 +import com.lyms.platform.common.enums.YnEnums;
  11 +import com.lyms.platform.common.result.BaseObjectResponse;
  12 +import com.lyms.platform.common.result.BaseResponse;
  13 +import com.lyms.platform.common.utils.DateUtil;
  14 +import com.lyms.platform.common.utils.MongoConvertHelper;
  15 +import com.lyms.platform.common.utils.ReflectionUtils;
  16 +import com.lyms.platform.common.utils.StringUtils;
  17 +import com.lyms.platform.operate.web.result.LhBabyPregnancyFollowTabResult;
  18 +import com.lyms.platform.operate.web.utils.CollectionUtils;
  19 +import com.lyms.platform.pojo.LhBabyPregnancyFollowTabModel;
  20 +import com.lyms.platform.pojo.LhServiceFollowModel;
  21 +import com.lyms.platform.pojo.PreEugenicsBaseModel;
  22 +import com.lyms.platform.query.LhBabyPregnancyFollowTabQuery;
  23 +import org.springframework.beans.factory.annotation.Autowired;
  24 +import org.springframework.data.domain.Sort;
  25 +import org.springframework.data.mongodb.core.MongoTemplate;
  26 +import org.springframework.data.mongodb.core.query.Criteria;
  27 +import org.springframework.data.mongodb.core.query.Query;
  28 +import org.springframework.data.mongodb.core.query.Update;
  29 +import org.springframework.stereotype.Component;
  30 +
  31 +import java.util.*;
  32 +
  33 +@Component
  34 +public class LhServiceFollowFacade {
  35 +
  36 + @Autowired
  37 + private MongoTemplate mongoTemplate;
  38 + @Autowired
  39 + private AutoMatchFacade autoMatchFacade;
  40 + @Autowired
  41 + private BasicConfigService basicConfigService;
  42 +
  43 +
  44 + public BaseResponse addOrUpdateServiceFollow(LhServiceFollowModel lhServiceFollowModel, Integer userId) {
  45 + String hospitalId = autoMatchFacade.getHospitalId(userId);
  46 +
  47 + if (StringUtils.isNotEmpty(lhServiceFollowModel.getId()))
  48 + {
  49 + Query query = Query.query(Criteria.where("id").is(lhServiceFollowModel.getId()));
  50 + lhServiceFollowModel.setModified(new Date());
  51 + Update update = MongoConvertHelper
  52 + .convertToNativeUpdate(ReflectionUtils.getUpdateField(lhServiceFollowModel));
  53 + mongoTemplate.updateFirst(query, update, LhServiceFollowModel.class);
  54 + }
  55 + else
  56 + {
  57 + lhServiceFollowModel.setHospitalId(hospitalId);
  58 + lhServiceFollowModel.setCreated(new Date());
  59 + lhServiceFollowModel.setModified(new Date());
  60 + mongoTemplate.save(lhServiceFollowModel);
  61 + }
  62 +
  63 + BaseObjectResponse br = new BaseObjectResponse();
  64 + br.setErrorcode(ErrorCodeConstants.SUCCESS);
  65 + br.setErrormsg("成功");
  66 + return br;
  67 + }
  68 +
  69 + public void delServiceFollow(String id, Integer userId) {
  70 + LhServiceFollowModel lhServiceFollowModel = new LhServiceFollowModel();
  71 + Query query = Query.query(Criteria.where("id").is(id));
  72 + lhServiceFollowModel.setYn(YnEnums.NO.getId());
  73 + Update update = MongoConvertHelper
  74 + .convertToNativeUpdate(ReflectionUtils.getUpdateField(lhServiceFollowModel));
  75 + mongoTemplate.updateFirst(query, update, LhServiceFollowModel.class);
  76 +
  77 + }
  78 +
  79 + public BaseResponse queryLhServiceFollow(String buildId) {
  80 + Query query = new Query();
  81 + query.addCriteria(Criteria.where("buildId").is(buildId));
  82 + query.addCriteria(Criteria.where("yn").is(YnEnums.YES.getId()));
  83 + List<LhServiceFollowModel> lhServiceFollowModels = mongoTemplate.find(query, LhServiceFollowModel.class);
  84 + BaseObjectResponse br = new BaseObjectResponse();
  85 + br.setData(lhServiceFollowModels);
  86 + br.setErrorcode(ErrorCodeConstants.SUCCESS);
  87 + br.setErrormsg("成功");
  88 + return br;
  89 + }
  90 +}
platform-operate-api/src/main/java/com/lyms/platform/operate/web/facade/ViewFacade.java View file @ 9df21dc
... ... @@ -5893,7 +5893,7 @@
5893 5893 BabyCheckPageResult model = new BabyCheckPageResult();
5894 5894  
5895 5895 if (babyModel != null) {
5896   -
  5896 + model.setQgscResult(checkModel.getQgscResult());
5897 5897 model.setXtxblz(checkModel.getXtxblz());
5898 5898 model.setEljy(checkModel.getEljy());
5899 5899 model.setEdfs(checkModel.getEdfs());
platform-operate-api/src/main/java/com/lyms/platform/operate/web/request/BabyCheckRequest.java View file @ 9df21dc
... ... @@ -704,6 +704,8 @@
704 704 */
705 705 private String lhaxisr;
706 706  
  707 + //屈光筛查
  708 + private Map<String, String> qgscResult;
707 709 private String sf;//是否失访
708 710 private String sfRea;//失访原因
709 711 private String xb;//胸部
... ... @@ -740,6 +742,14 @@
740 742 private Integer visitType;
741 743 //选项指标记录
742 744 private List<Object> recordChoice;
  745 +
  746 + public Map<String, String> getQgscResult() {
  747 + return qgscResult;
  748 + }
  749 +
  750 + public void setQgscResult(Map<String, String> qgscResult) {
  751 + this.qgscResult = qgscResult;
  752 + }
743 753  
744 754 public List<Object> getRecordChoice() {
745 755 return recordChoice;
platform-operate-api/src/main/java/com/lyms/platform/operate/web/result/BabyCheckPageResult.java View file @ 9df21dc
... ... @@ -1003,6 +1003,17 @@
1003 1003 //选项指标记录
1004 1004 private List<Object> recordChoice;
1005 1005  
  1006 + //屈光筛查
  1007 + private Map<String, String> qgscResult;
  1008 +
  1009 + public Map<String, String> getQgscResult() {
  1010 + return qgscResult;
  1011 + }
  1012 +
  1013 + public void setQgscResult(Map<String, String> qgscResult) {
  1014 + this.qgscResult = qgscResult;
  1015 + }
  1016 +
1006 1017 public List<Object> getRecordChoice() {
1007 1018 return recordChoice;
1008 1019 }
platform-operate-api/src/main/java/com/lyms/platform/operate/web/result/BabyCheckResult.java View file @ 9df21dc
... ... @@ -751,6 +751,17 @@
751 751 //儿童疾病
752 752 private List<Map> diseases;
753 753  
  754 + //屈光筛查
  755 + private Map<String, String> qgscResult;
  756 +
  757 + public Map<String, String> getQgscResult() {
  758 + return qgscResult;
  759 + }
  760 +
  761 + public void setQgscResult(Map<String, String> qgscResult) {
  762 + this.qgscResult = qgscResult;
  763 + }
  764 +
754 765 public List<Map> getDiseases() {
755 766 return diseases;
756 767 }
platform-operate-api/src/main/java/com/lyms/platform/operate/web/result/LhBabyGravidityEndingTabResult.java View file @ 9df21dc
... ... @@ -14,6 +14,7 @@
14 14 import org.springframework.beans.factory.annotation.Autowired;
15 15  
16 16 import java.util.Date;
  17 +import java.util.List;
17 18  
18 19 public class LhBabyGravidityEndingTabResult {
19 20 private String id;
... ... @@ -66,7 +67,8 @@
66 67 private String gravidityEnding;
67 68 //其他
68 69 private String gravidityEndingOther;
69   -
  70 + //妊娠高危
  71 + private List<Integer> gravidityHigh;
70 72 //性别(LhSexEnum)
71 73 private String babySex;
72 74 //出生体重
... ... @@ -110,6 +112,14 @@
110 112 //填表日期
111 113 private Date writeDate;
112 114  
  115 + public List<Integer> getGravidityHigh() {
  116 + return gravidityHigh;
  117 + }
  118 +
  119 + public void setGravidityHigh(List<Integer> gravidityHigh) {
  120 + this.gravidityHigh = gravidityHigh;
  121 + }
  122 +
113 123 public String getId() {
114 124 return id;
115 125 }
... ... @@ -442,7 +452,7 @@
442 452 setGravidityEnding(StringUtils.isNotEmpty(gravidityEnding.toString())?gravidityEnding.toString():null);
443 453 //其他
444 454 setGravidityEndingOther(model.getGravidityEndingOther());
445   -
  455 + setGravidityHigh(model.getGravidityHigh());
446 456 //性别(LhSexEnum)
447 457 setBabySex(LhSexEnum.getName(model.getBabySex()));
448 458 //出生体重