From 96cfedc1dbb38c31b63040d117408965d132abc3 Mon Sep 17 00:00:00 2001 From: mengkuiliang <1464081137@qq.com> Date: Tue, 10 Oct 2023 09:13:30 +0800 Subject: [PATCH] =?UTF-8?q?=E6=B7=BB=E5=8A=A0=E6=9C=8D=E5=8A=A1=E9=A2=84?= =?UTF-8?q?=E7=BA=A6=E7=9B=B8=E5=85=B3=E6=8E=A5=E5=8F=A3=EF=BC=9B=E4=BF=AE?= =?UTF-8?q?=E6=94=B9=E6=B3=A8=E5=86=8C=E6=8E=A5=E5=8F=A3=EF=BC=9B?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../applet/ResidentPatientInfoController.java | 64 +++-- .../ResidentServiceApplyController.java | 6 +- .../web/controller/fd/FDController.java | 1 - .../src/main/resources/application.yml | 22 +- xinelu-familydoctor/pom.xml | 4 + .../applet/pojo/body/PatientInfoBody.java | 27 +- .../applet/pojo/entity/PatientInfo.java | 15 ++ .../applet/pojo/vo/OrgDetailVo.java | 150 +++++++++++ .../applet/pojo/vo/PerformanceDetailVo.java | 236 ++++++++++++++++++ .../applet/pojo/vo/ScreeningProjectVo.java | 81 +++--- .../service/IResidentPatientInfoService.java | 2 +- .../IResidentServiceAppletService.java | 3 +- .../impl/ResidentPatientInfoServiceImpl.java | 89 ++++--- .../impl/ResidentServiceApplyServiceImpl.java | 104 +++++++- .../register/ResidentPatientInfoMapper.xml | 9 + .../hospitalinfo/HospitalInfoMapper.java | 9 + .../hospitalinfo/IHospitalInfoService.java | 9 + .../impl/HospitalInfoServiceImpl.java | 12 + .../hospitalinfo/HospitalInfoMapper.xml | 6 + 19 files changed, 722 insertions(+), 127 deletions(-) create mode 100644 xinelu-familydoctor/src/main/java/com/xinelu/familydoctor/applet/pojo/vo/OrgDetailVo.java create mode 100644 xinelu-familydoctor/src/main/java/com/xinelu/familydoctor/applet/pojo/vo/PerformanceDetailVo.java diff --git a/xinelu-admin/src/main/java/com/xinelu/web/controller/applet/ResidentPatientInfoController.java b/xinelu-admin/src/main/java/com/xinelu/web/controller/applet/ResidentPatientInfoController.java index e31137c..323a11f 100644 --- a/xinelu-admin/src/main/java/com/xinelu/web/controller/applet/ResidentPatientInfoController.java +++ b/xinelu-admin/src/main/java/com/xinelu/web/controller/applet/ResidentPatientInfoController.java @@ -1,6 +1,11 @@ package com.xinelu.web.controller.applet; import com.alibaba.fastjson2.JSONObject; +import com.xinelu.common.config.XinELuConfig; +import com.xinelu.common.core.domain.AjaxResult; +import com.xinelu.common.exception.ServiceException; +import com.xinelu.common.utils.file.FileUploadUtils; +import com.xinelu.common.utils.file.MimeTypeUtils; import com.xinelu.familydoctor.applet.pojo.body.PatientInfoBody; import com.xinelu.familydoctor.applet.pojo.entity.PatientInfo; import com.xinelu.familydoctor.applet.service.IResidentPatientInfoService; @@ -14,10 +19,9 @@ import org.springframework.web.bind.annotation.PathVariable; import org.springframework.web.bind.annotation.RequestBody; import org.springframework.web.bind.annotation.RequestMapping; import org.springframework.web.bind.annotation.RestController; -import com.xinelu.common.annotation.Log; import com.xinelu.common.core.controller.BaseController; import com.xinelu.common.core.domain.R; -import com.xinelu.common.enums.BusinessType; +import org.springframework.web.multipart.MultipartFile; import javax.annotation.Resource; import java.util.List; @@ -36,6 +40,8 @@ public class ResidentPatientInfoController extends BaseController { @Resource private IResidentPatientInfoService residentPatientInfoService; + @Resource + private XinELuConfig xinELuConfig; @ApiOperation("获取OpenId") @GetMapping("/getOpenId/{code}") @@ -57,9 +63,8 @@ public class ResidentPatientInfoController extends BaseController { } } - @ApiOperation("注册") - @Log(title = "居民小程序注册", businessType = BusinessType.INSERT) - @PostMapping("/") + @ApiOperation("注册完善信息") + @PostMapping("") public R register(@Validated @RequestBody PatientInfoBody body) { try { residentPatientInfoService.register(body); @@ -69,20 +74,19 @@ public class ResidentPatientInfoController extends BaseController { } } - @ApiOperation("修改注册信息") - @Log(title = "修改注册信息", businessType = BusinessType.UPDATE) - @PostMapping("/update") - public R update(@Validated @RequestBody PatientInfo body) { - try { - residentPatientInfoService.updatePatientInfo(body); - return R.ok(); - } catch (Exception e) { - return R.fail(e.getMessage()); - } - } +// @ApiOperation("修改注册信息") +// @Log(title = "修改注册信息", businessType = BusinessType.UPDATE) +// @PostMapping("/update") +// public R update(@Validated @RequestBody PatientInfo body) { +// try { +// residentPatientInfoService.updatePatientInfo(body); +// return R.ok(); +// } catch (Exception e) { +// return R.fail(e.getMessage()); +// } +// } @ApiOperation("解绑") - @Log(title = "居民小程序解绑", businessType = BusinessType.UPDATE) @GetMapping("/unbinding/{patientCode}") public R unbinding(@PathVariable String patientCode) { residentPatientInfoService.unbinding(patientCode); @@ -119,4 +123,30 @@ public class ResidentPatientInfoController extends BaseController { } return R.ok(residentPatientInfoService.getCurrentResident(openid, cityCode)); } + + /** + * @Author mengkuiliang + * @Description 居民头像上传 + * @Date 2023-10-09 009 13:41 + * @Param + * @return + **/ + @ApiOperation("居民头像上传") + @PostMapping(value = "/headPictureUpload") + public AjaxResult headPictureUpload(MultipartFile file) throws Exception { + if (StringUtils.isBlank(file.getOriginalFilename())) { + return AjaxResult.error("请选择所要上传的头像!"); + } + //获取路径名称 + String uploadPathUrl = XinELuConfig.getProfile() + xinELuConfig.getHeadPictureUrl(); + //上传图片 + String pictureName = FileUploadUtils.uploadNurseStationPath(uploadPathUrl, file, MimeTypeUtils.IMAGE_EXTENSION); + if (StringUtils.isBlank(pictureName)) { + throw new ServiceException(pictureName + "居民头像上传失败!"); + } + //获取返回值 + AjaxResult ajax = AjaxResult.success("上传成功!"); + ajax.put("imgUrl", pictureName); + return ajax; + } } diff --git a/xinelu-admin/src/main/java/com/xinelu/web/controller/applet/ResidentServiceApplyController.java b/xinelu-admin/src/main/java/com/xinelu/web/controller/applet/ResidentServiceApplyController.java index c11fe17..97eb659 100644 --- a/xinelu-admin/src/main/java/com/xinelu/web/controller/applet/ResidentServiceApplyController.java +++ b/xinelu-admin/src/main/java/com/xinelu/web/controller/applet/ResidentServiceApplyController.java @@ -7,6 +7,7 @@ import com.xinelu.common.exception.ServiceException; import com.xinelu.familydoctor.applet.pojo.body.ResidentServiceApplyBody; import com.xinelu.familydoctor.applet.pojo.query.ApplyQuery; import com.xinelu.familydoctor.applet.pojo.vo.ResidentServiceApplyVo; +import com.xinelu.familydoctor.applet.pojo.vo.ScreeningProjectVo; import com.xinelu.familydoctor.applet.service.IResidentServiceAppletService; import io.swagger.annotations.Api; import io.swagger.annotations.ApiOperation; @@ -14,6 +15,7 @@ import org.apache.commons.lang3.StringUtils; import org.springframework.web.bind.annotation.*; import javax.annotation.Resource; +import java.util.List; /** * @Author mengkuiliang @@ -69,7 +71,7 @@ public class ResidentServiceApplyController extends BaseController { @ApiOperation("获取个性服务包和筛查项目") @GetMapping("/getForm/{identity}") - public R getForm(@PathVariable String identity) { - return R.ok(residentServiceAppletService.getForm(identity)); + public R> getForm(@PathVariable String identity, @RequestHeader("region") String region) { + return R.ok(residentServiceAppletService.getForm(identity, region)); } } diff --git a/xinelu-admin/src/main/java/com/xinelu/web/controller/fd/FDController.java b/xinelu-admin/src/main/java/com/xinelu/web/controller/fd/FDController.java index 8381138..acd2eb1 100644 --- a/xinelu-admin/src/main/java/com/xinelu/web/controller/fd/FDController.java +++ b/xinelu-admin/src/main/java/com/xinelu/web/controller/fd/FDController.java @@ -38,7 +38,6 @@ public class FDController { @PostMapping("/performanceBooking/list") public R> performanceBookingList(@RequestBody ApplyQuery query) { PageHelper.startPage(query.getPageNum(), query.getPageSize()); -// query.setBookingStatus("0"); return R.ok(PageInfo.of(residentServiceAppletService.findList(query))); } @ApiOperation("服务申请详情") diff --git a/xinelu-admin/src/main/resources/application.yml b/xinelu-admin/src/main/resources/application.yml index 560beee..1b7f413 100644 --- a/xinelu-admin/src/main/resources/application.yml +++ b/xinelu-admin/src/main/resources/application.yml @@ -149,7 +149,7 @@ token: # 令牌有效期(默认30分钟) expireTime: 1440 #请求拦截白名单 - ant-matchers: /applet/test/**,/nurseApplet/**,/nurseApp/**,/applet/**,webSocket/**, + ant-matchers: /nurseApplet/**,/nurseApp/**,/applet/**,webSocket/** # MyBatis-Plus配置 mybatis-plus: @@ -222,7 +222,7 @@ swagger: pathMapping: /dev-api swagger-ui: - base-url: com.xinelu.web + base-url: com.xinelu # 防止XSS攻击 xss: @@ -233,19 +233,15 @@ xss: # 匹配链接 urlPatterns: /system/*,/monitor/*,/tool/* -# 微信小程序配置 +# 家医签约附近的机构 applet: - wxAppid: wxccb16a452ab5e4b4 - wxSecret: 72e11a5757e578c47ee935c00f49e8bf - grantType: authorization_code - openIDUrl: https://api.weixin.qq.com/sns/jscode2session - # 附近机构,多少公里内 + # 多少公里内 distance: 100.00 # 家医请求地址 fd: - dy: http://192.168.124.10:8001/fd/mp - dz: http://192.168.124.10:8002/fd/mp + dy: http://192.168.124.6:8001/fd/mp + dz: http://192.168.124.6:8001/fd/mp # 腾讯云音视频 trtc: @@ -257,9 +253,9 @@ trtc: # 微信小程序参数配置信息 applet-chat-config: # 微信小程序id,wxdec3416aa3d60cab - applet-id: wxdc32268eca6b78f9 + applet-id: wxccb16a452ab5e4b4 # 微信小程序密钥,f58e19be0380c2ebc6e9e9684c0dacce - secret: 0d0e41432908750460aef2bf0aa871ae + secret: 72e11a5757e578c47ee935c00f49e8bf # 微信小程序返回国家语言 lang: zh_CN # 微信小程序授权类型 @@ -297,4 +293,4 @@ applet-page-config: # 积分页面跳转路径 integral-page-url: pages/integral/integral # 护理结构详情页面跳转路径 - nursestation-details-page-url: pages/nursestation/nursestation \ No newline at end of file + nursestation-details-page-url: pages/nursestation/nursestation diff --git a/xinelu-familydoctor/pom.xml b/xinelu-familydoctor/pom.xml index 5e90368..84cb4ac 100644 --- a/xinelu-familydoctor/pom.xml +++ b/xinelu-familydoctor/pom.xml @@ -35,5 +35,9 @@ swagger-models 1.6.2 + + com.xinelu + xinelu-nurse-manage + diff --git a/xinelu-familydoctor/src/main/java/com/xinelu/familydoctor/applet/pojo/body/PatientInfoBody.java b/xinelu-familydoctor/src/main/java/com/xinelu/familydoctor/applet/pojo/body/PatientInfoBody.java index 8afec9f..a379a27 100644 --- a/xinelu-familydoctor/src/main/java/com/xinelu/familydoctor/applet/pojo/body/PatientInfoBody.java +++ b/xinelu-familydoctor/src/main/java/com/xinelu/familydoctor/applet/pojo/body/PatientInfoBody.java @@ -1,8 +1,10 @@ package com.xinelu.familydoctor.applet.pojo.body; import java.util.Date; +import java.util.List; import com.fasterxml.jackson.annotation.JsonFormat; +import com.xinelu.common.annotation.Excel; import com.xinelu.common.core.domain.BaseEntity; import io.swagger.annotations.ApiModel; import io.swagger.annotations.ApiModelProperty; @@ -179,7 +181,7 @@ public class PatientInfoBody extends BaseEntity { /** * 会员累计签到天数 */ - @ApiModelProperty(value = "会员累计签到天数") + @ApiModelProperty(value = "会员累计签到天数", hidden = true) private Integer totalSignInDays; /** @@ -195,11 +197,6 @@ public class PatientInfoBody extends BaseEntity { @JsonFormat(pattern = "yyyy-MM-dd") private Date birthDate; - /** - * 是否删除标识,0:否,1:是 - */ - private Integer delFlag; - /** * 小程序个人微信二维码图片存放地址 */ @@ -218,6 +215,20 @@ public class PatientInfoBody extends BaseEntity { @ApiModelProperty(value = "失能原因") private String disablingReason; + /** + * 基础疾病,1:高血压,2:高血糖,3:高血脂,0:无 + */ + @ApiModelProperty(value = "基础疾病,1:高血压,2:高血糖,3:高血脂,0:无") + @Excel(name = "基础疾病,1:高血压,2:高血糖,3:高血脂,0:无") + private String disease; + + /** + * 基础疾病集合 + */ + @ApiModelProperty(value = "基础疾病集合") + @Excel(name = "基础疾病集合") + private List diseaseList; + /** * 绑定城市(1:德州 2:东营) */ @@ -229,14 +240,14 @@ public class PatientInfoBody extends BaseEntity { /** * 小程序绑定时间 */ - @ApiModelProperty(value = "小程序绑定时间") + @ApiModelProperty(value = "小程序绑定时间", hidden = true) @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss") private Date bindingTime; /** * 当前是否选中(0: 否 1:是) */ - @ApiModelProperty(value = "当前是否选中(0: 否 1:是)") + @ApiModelProperty(value = "当前是否选中(0: 否 1:是)", hidden = true) private String isChecked; } diff --git a/xinelu-familydoctor/src/main/java/com/xinelu/familydoctor/applet/pojo/entity/PatientInfo.java b/xinelu-familydoctor/src/main/java/com/xinelu/familydoctor/applet/pojo/entity/PatientInfo.java index 350a61d..1fd7df9 100644 --- a/xinelu-familydoctor/src/main/java/com/xinelu/familydoctor/applet/pojo/entity/PatientInfo.java +++ b/xinelu-familydoctor/src/main/java/com/xinelu/familydoctor/applet/pojo/entity/PatientInfo.java @@ -1,6 +1,7 @@ package com.xinelu.familydoctor.applet.pojo.entity; import java.util.Date; +import java.util.List; import com.fasterxml.jackson.annotation.JsonFormat; import com.xinelu.common.core.domain.BaseEntity; @@ -251,6 +252,20 @@ public class PatientInfo extends BaseEntity { @Excel(name = "失能原因") private String disablingReason; + /** + * 基础疾病,1:高血压,2:高血糖,3:高血脂,0:无 + */ + @ApiModelProperty(value = "基础疾病,1:高血压,2:高血糖,3:高血脂,0:无") + @Excel(name = "基础疾病,1:高血压,2:高血糖,3:高血脂,0:无") + private String disease; + + /** + * 基础疾病集合 + */ + @ApiModelProperty(value = "基础疾病集合") + @Excel(name = "基础疾病集合") + private List diseaseList; + /** * 绑定城市(1:德州 2:东营) */ diff --git a/xinelu-familydoctor/src/main/java/com/xinelu/familydoctor/applet/pojo/vo/OrgDetailVo.java b/xinelu-familydoctor/src/main/java/com/xinelu/familydoctor/applet/pojo/vo/OrgDetailVo.java new file mode 100644 index 0000000..36aad3d --- /dev/null +++ b/xinelu-familydoctor/src/main/java/com/xinelu/familydoctor/applet/pojo/vo/OrgDetailVo.java @@ -0,0 +1,150 @@ +package com.xinelu.familydoctor.applet.pojo.vo; + +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import lombok.Data; + +import java.math.BigDecimal; + +/** + * @Author mengkuiliang + * @Description 机构展示对象 + * @Date 2023-10-09 009 15:38 + * @Param + * @return + **/ +@ApiModel("机构展示对象") +@Data +public class OrgDetailVo { + /** + * 机构业务主键 + */ + @ApiModelProperty("机构业务主键") + private String orgNo; + + /** + * 上级机构业务主键 + */ + @ApiModelProperty("上级机构业务主键") + private String parentNo; + + /** + * 上级机构名称 + */ + @ApiModelProperty("上级机构名称") + private String parentName; + + /** + * 所有上级机构业务主键 + */ + @ApiModelProperty("所有上级机构业务主键") + private String ancestors; + + /** + * 机构名称 + */ + @ApiModelProperty("机构名称") + private String orgName; + + /** + * 公卫授权码 + */ + @ApiModelProperty("公卫授权码") + private String phAuthCode; + + /** + * 公卫机构id + */ + @ApiModelProperty("公卫机构id") + private String phOrgId; + + /** + * 公卫机构编码 + */ + @ApiModelProperty("公卫机构编码") + private String phOrgCode; + + /** + * 机构类型(0:卫健委,1:卫健局,2:医院,3:乡镇卫生院,4:街道卫生服务中心,5:社区服务站,6:村卫生室) + */ + @ApiModelProperty("机构类型(0:卫健委,1:卫健局,2:医院,3:乡镇卫生院,4:街道卫生服务中心,5:社区服务站,6:村卫生室)") + private String orgType; + + /** + * 机构地址 + */ + @ApiModelProperty("机构地址") + private String address; + + /** + * 经度 + */ + @ApiModelProperty("经度") + private BigDecimal lng; + + /** + * 纬度 + */ + @ApiModelProperty("纬度") + private BigDecimal lat; + + /** + * 机构联系方式 + */ + @ApiModelProperty("机构联系方式") + private String phone; + + /** + * 机构公章路径 + */ + @ApiModelProperty("机构公章路径") + private String sealPath; + + /** + * 机构介绍 + */ + @ApiModelProperty("机构介绍") + private String introduction; + + /** + * 行政级别(0-4等级依次降低,4级不能创建子机构) + */ + @ApiModelProperty("行政级别(0-4等级依次降低,4级不能创建子机构)") + private Integer orgLevel; + + /** + * 所属区县级的行政区划编号 + */ + @ApiModelProperty("所属区县级的行政区划编号") + private Long areaCode; + + /** + * 所属区县级的行政区划名称 + */ + @ApiModelProperty("所属区县级的行政区划名称") + private String areaName; + + /** + * 后缀,用于分表查询 + */ + @ApiModelProperty(value = "后缀,用于分表查询", hidden=true) + private String suffix; + + /** + * 系统版本(0:公卫随访版本 1:家医签约版本 2:精细化履约版本 3:三高共管版本) + */ + @ApiModelProperty(value = "系统版本(0:公卫随访版本 1:家医签约版本 2:精细化履约版本 3:三高共管版本)", hidden=true) + private String sysVersion; + + /** + * 是否可用 0:停用,1:正常 + */ + @ApiModelProperty("是否可用") + private Boolean usable; + + /** + * 备注 + */ + @ApiModelProperty("备注") + private String remark; +} diff --git a/xinelu-familydoctor/src/main/java/com/xinelu/familydoctor/applet/pojo/vo/PerformanceDetailVo.java b/xinelu-familydoctor/src/main/java/com/xinelu/familydoctor/applet/pojo/vo/PerformanceDetailVo.java new file mode 100644 index 0000000..626dd77 --- /dev/null +++ b/xinelu-familydoctor/src/main/java/com/xinelu/familydoctor/applet/pojo/vo/PerformanceDetailVo.java @@ -0,0 +1,236 @@ +package com.xinelu.familydoctor.applet.pojo.vo; + +import io.swagger.annotations.ApiModel; +import io.swagger.annotations.ApiModelProperty; +import lombok.Data; + +import java.math.BigDecimal; +import java.util.Date; + +/** + * @Author mengkuiliang + * @Description 履约明细展示类 + * @Date 2023-10-09 009 15:16 + * @Param + * @return + **/ +@ApiModel("履约明细展示类") +@Data +public class PerformanceDetailVo { + + /** + * 履约明细业务主键 + */ + @ApiModelProperty(value = "履约明细业务主键") + private String performanceDetailNo; + /** + * 签约编号 + */ + @ApiModelProperty(value = "签约编号") + private String signNo; + + /** + * 居民用户业务主键 + */ + @ApiModelProperty(value = "居民用户业务主键") + private String residentNo; + + /** + * 姓名 + */ + @ApiModelProperty(value = "姓名") + private String residentName; + + /** + * 身份证号 + */ + @ApiModelProperty(value = "身份证号") + private String identity; + + /** + * 服务包编号 + */ + @ApiModelProperty(value = "服务包编号") + private String packageNo; + + /** + * 服务包名称 + */ + @ApiModelProperty(value = "服务包名称") + private String packageName; + + /** + * 服务包明细编号 + */ + @ApiModelProperty(value = "服务包明细编号") + private String packageDetailNo; + + /** + * 服务项表单编号 + */ + @ApiModelProperty(value = "服务项表单编号") + private String formNo; + + /** + * 服务项表单名称 + */ + @ApiModelProperty(value = "服务项表单名称") + private String formName; + + /** + * 价格(单位:元,#0.00) + */ + @ApiModelProperty(value = "价格(单位:元,#0.00)") + private BigDecimal packCost; + + /** + * 优惠价格(单位:元,#0.00) + */ + @ApiModelProperty(value = "优惠价格(单位:元,#0.00)") + private BigDecimal packCostCheap; + + /** + * 签约价格(单位:元,#0.00) + */ + @ApiModelProperty(value = "签约价格(单位:元,#0.00)") + private BigDecimal packSignCost; + + /** + * 服务包类型(0:基本公共卫生服务包 1:家医服务包 2:精细化服务包) + */ + @ApiModelProperty(value = "服务包类型(0:基本公共卫生服务包 1:家医服务包 2:精细化服务包)") + private String packType; + + /** + * 服务包类别(0:基础服务包 1:个性化服务包) + * */ + @ApiModelProperty(value = "服务包类别(0:基础服务包 1:个性化服务包)") + private String packCategory; + + /** + * 是否精细化表单 + */ + @ApiModelProperty("是否精细化表单") + private Boolean refineForm; + + /** + * 是否公卫表单0:否,1:是 + */ + @ApiModelProperty(value = "是否公卫表单0:否,1:是") + private Boolean phForm; + + /** + * 公卫类型,是公卫表单时不能为空(12:孕产妇产后访视 14:新生儿随访 28:高血压 29:糖尿病 30:高血压高危人群 32:精神障碍) + */ + @ApiModelProperty(value = "公卫类型,是公卫表单时不能为空(12:孕产妇产后访视 14:新生儿随访 28:高血压 29:糖尿病 30:高血压高危人群 32:精神障碍)") + private String phType; + + /** + * PC端路径 + */ + @ApiModelProperty(value = "PC端路径") + private String pcFormPath; + + /** + * APP端路径 + */ + @ApiModelProperty(value = "APP端路径") + private String appFormPath; + + /** + * 应服务次数 + */ + @ApiModelProperty(value = "应服务次数") + private Integer serviceFreq; + + /** + * 已履约次数 + */ + @ApiModelProperty(value = "已履约次数") + private Integer performanceCount; + + /** + * 机构业务编号 + */ + @ApiModelProperty(value = "机构业务编号") + private String orgNo; + + /** + * 机构名称 + */ + @ApiModelProperty(value = "机构名称", required = true) + private String orgName; + + /** + * 团队业务编号 + */ + @ApiModelProperty(value = "团队业务编号", required = true) + private String teamNo; + + /** + * 团队名称 + */ + @ApiModelProperty(value = "团队名称", required = true) + private String teamName; + + /** + * 是否已完成(0:否 1:是) + */ + @ApiModelProperty(value = "是否已完成(0:否 1:是)") + private Boolean complete; + + /** + * 履约医生编号 + */ + @ApiModelProperty(value = "履约医生编号") + private String userNo; + + /** + * 履约医生姓名 + */ + @ApiModelProperty(value = "履约医生姓名") + private String userName; + + /** + * 最后履约时间 + */ + @ApiModelProperty(value = "最后履约时间") + private Date lastDate; + + /** + * 备注 + */ + @ApiModelProperty(value = "备注") + private String remark; + + /** + * 创建人 + */ + @ApiModelProperty(value = "创建人") + private String createBy; + + /** + * 创建时间 + */ + @ApiModelProperty(value = "创建时间") + private Date createDate; + + /** + * 更新人 + */ + @ApiModelProperty(value = "更新人") + private String updateBy; + + /** + * 更新时间 + */ + @ApiModelProperty(value = "更新时间") + private Date updateDate; + + /** + * 删除标识( 0:正常,1:已删除) + */ + @ApiModelProperty(value = "删除标识( 0:正常,1:已删除)") + private Boolean delete; + +} diff --git a/xinelu-familydoctor/src/main/java/com/xinelu/familydoctor/applet/pojo/vo/ScreeningProjectVo.java b/xinelu-familydoctor/src/main/java/com/xinelu/familydoctor/applet/pojo/vo/ScreeningProjectVo.java index a06e9ba..ea584ee 100644 --- a/xinelu-familydoctor/src/main/java/com/xinelu/familydoctor/applet/pojo/vo/ScreeningProjectVo.java +++ b/xinelu-familydoctor/src/main/java/com/xinelu/familydoctor/applet/pojo/vo/ScreeningProjectVo.java @@ -1,12 +1,10 @@ package com.xinelu.familydoctor.applet.pojo.vo; -import com.fasterxml.jackson.annotation.JsonFormat; import io.swagger.annotations.ApiModel; import io.swagger.annotations.ApiModelProperty; import lombok.Data; import java.math.BigDecimal; -import java.util.Date; /** * @Author mengkuiliang @@ -19,10 +17,28 @@ import java.util.Date; @ApiModel("筛查项目展示对象") public class ScreeningProjectVo { + /** + * 项目来源 + */ + @ApiModelProperty("项目来源(1: 家医个性服务包 2: 筛查包)") + private String sourceType; + + /** + * 服务包编码 + */ + @ApiModelProperty("服务包编码") + private String packageId; + + /** + * 服务包名称 + */ + @ApiModelProperty("服务包名称") + private String packageName; + /** * 项目编码 */ - @ApiModelProperty("项目业务主键") + @ApiModelProperty("项目编号=码") private String projectId; /** @@ -32,21 +48,15 @@ public class ScreeningProjectVo { private String projectName; /** - * 类型(0:其他项目 1:常规项目 2:履约项目) + * 机构ID */ - @ApiModelProperty("类型(0:其他项目 1:常规项目 2:履约项目)") - private String projectType; - - /** - * 所属机构ID - */ - @ApiModelProperty("所属机构ID") + @ApiModelProperty("机构ID") private String deptId; /** * 所属机构名称 */ - @ApiModelProperty("所属机构名称") + @ApiModelProperty("机构名称") private String deptName; /** @@ -54,6 +64,7 @@ public class ScreeningProjectVo { */ @ApiModelProperty("服务内容") private String serviceContent; + /** * 单价(元/次) */ @@ -67,47 +78,51 @@ public class ScreeningProjectVo { private String discount; /** - * 显示排序 + * 优惠后价格 */ - @ApiModelProperty("显示排序") - private Integer orderNum; + @ApiModelProperty("优惠后价格") + private BigDecimal discountPrice; /** - * 项目状态(0:正常,1:停用) + * 应服务次数 */ - @ApiModelProperty("项目状态(0:正常,1:停用)") - private String status; + @ApiModelProperty(value = "应服务次数") + private Integer serviceFreq; /** - * 删除标识(0:存在,1:删除) + * 已履约次数 */ - @ApiModelProperty(value = "删除标识(0:存在,1:删除)", hidden = true) - private String delFlag; + @ApiModelProperty(value = "已服务次数") + private Integer performanceCount; /** - * 创建者 + * 团队业务编号 */ - private String createBy; + @ApiModelProperty(value = "团队业务编号", required = true) + private String teamNo; /** - * 创建时间 + * 团队名称 */ - @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss") - private Date createTime; + @ApiModelProperty(value = "团队名称", required = true) + private String teamName; /** - * 更新者 + * 是否已完成(0:否 1:是) */ - private String updateBy; + @ApiModelProperty(value = "是否已完成(0:否 1:是)") + private Boolean complete; /** - * 更新时间 + * 履约医生编号 */ - @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss") - private Date updateTime; + @ApiModelProperty(value = "服务医生编号") + private String userNo; /** - * 备注 + * 履约医生姓名 */ - private String remark; + @ApiModelProperty(value = "服务医生姓名") + private String userName; + } diff --git a/xinelu-familydoctor/src/main/java/com/xinelu/familydoctor/applet/service/IResidentPatientInfoService.java b/xinelu-familydoctor/src/main/java/com/xinelu/familydoctor/applet/service/IResidentPatientInfoService.java index 5c03f63..f3561c8 100644 --- a/xinelu-familydoctor/src/main/java/com/xinelu/familydoctor/applet/service/IResidentPatientInfoService.java +++ b/xinelu-familydoctor/src/main/java/com/xinelu/familydoctor/applet/service/IResidentPatientInfoService.java @@ -64,7 +64,7 @@ public interface IResidentPatientInfoService { /** * @return void * @Author mengkuiliang - * @Description 注册 + * @Description 注册和完善信息 * @Date 2023-09-21 021 10:13 * @Param [body] **/ diff --git a/xinelu-familydoctor/src/main/java/com/xinelu/familydoctor/applet/service/IResidentServiceAppletService.java b/xinelu-familydoctor/src/main/java/com/xinelu/familydoctor/applet/service/IResidentServiceAppletService.java index 70049f4..9ed4fa4 100644 --- a/xinelu-familydoctor/src/main/java/com/xinelu/familydoctor/applet/service/IResidentServiceAppletService.java +++ b/xinelu-familydoctor/src/main/java/com/xinelu/familydoctor/applet/service/IResidentServiceAppletService.java @@ -4,6 +4,7 @@ import com.xinelu.familydoctor.applet.pojo.body.ApprovalBody; import com.xinelu.familydoctor.applet.pojo.body.ResidentServiceApplyBody; import com.xinelu.familydoctor.applet.pojo.query.ApplyQuery; import com.xinelu.familydoctor.applet.pojo.vo.ResidentServiceApplyVo; +import com.xinelu.familydoctor.applet.pojo.vo.ScreeningProjectVo; import java.util.List; import java.util.Map; @@ -103,5 +104,5 @@ public interface IResidentServiceAppletService { * @Param [identity] * @return java.lang.Object **/ - List getForm(String identity); + List getForm(String identity, String region); } diff --git a/xinelu-familydoctor/src/main/java/com/xinelu/familydoctor/applet/service/impl/ResidentPatientInfoServiceImpl.java b/xinelu-familydoctor/src/main/java/com/xinelu/familydoctor/applet/service/impl/ResidentPatientInfoServiceImpl.java index a92123b..544e454 100644 --- a/xinelu-familydoctor/src/main/java/com/xinelu/familydoctor/applet/service/impl/ResidentPatientInfoServiceImpl.java +++ b/xinelu-familydoctor/src/main/java/com/xinelu/familydoctor/applet/service/impl/ResidentPatientInfoServiceImpl.java @@ -6,6 +6,7 @@ import java.util.stream.Collectors; import com.alibaba.fastjson2.JSON; import com.alibaba.fastjson2.JSONObject; +import com.xinelu.common.config.AppletChatConfig; import com.xinelu.common.exception.ServiceException; import com.xinelu.common.utils.bean.BeanUtils; import com.xinelu.common.utils.http.HttpService; @@ -38,15 +39,8 @@ public class ResidentPatientInfoServiceImpl implements IResidentPatientInfoServi private ResidentPatientInfoMapper residentPatientInfoMapper; @Resource private HttpService httpService; - - @Value("${applet.wxAppid}") - private String WX_APPID; - @Value("${applet.wxSecret}") - private String WX_SECRET; - @Value("${applet.grantType}") - private String GRANTTYPE; - @Value("${applet.openIDUrl}") - private String OPENID_URL; + @Resource + private AppletChatConfig appletChatConfig; /** * @return com.xinelu.familydoctor.applet.pojo.entity.PatientInfo @@ -83,9 +77,9 @@ public class ResidentPatientInfoServiceImpl implements IResidentPatientInfoServi public String getOpenId(String code) { try { SslUtils.ignoreSsl(); - String params = "appid=" + WX_APPID + "&secret=" + WX_SECRET + "&js_code=" + code + "&grant_type=" + GRANTTYPE; + String params = "appid=" + appletChatConfig.getAppletId() + "&secret=" + appletChatConfig.getSecret() + "&js_code=" + code + "&grant_type=" + appletChatConfig.getGrantType(); log.info("获取openID请求参数{}", params); - String result = HttpUtils.sendPost(OPENID_URL, params); + String result = HttpUtils.sendPost("https://api.weixin.qq.com/sns/jscode2session", params); JSONObject json = JSONObject.parseObject(result); // {"errcode":40029,"errmsg":"invalid code, rid: 650bf9c3-31a6c960-2b437029"} log.info("获取openID响应结果{}", json.toJSONString()); @@ -112,7 +106,7 @@ public class ResidentPatientInfoServiceImpl implements IResidentPatientInfoServi JSONObject result; // 获取token - String token_url = String.format("https://api.weixin.qq.com/cgi-bin/token?grant_type=client_credential&appid=%s&secret=%s", WX_APPID, WX_SECRET); + String token_url = String.format("https://api.weixin.qq.com/cgi-bin/token?grant_type=client_credential&appid=%s&secret=%s", appletChatConfig.getAppletId(), appletChatConfig.getSecret()); SslUtils.ignoreSsl(); String tokenResult = HttpUtils.sendGet(token_url); if (tokenResult == null) { @@ -159,40 +153,57 @@ public class ResidentPatientInfoServiceImpl implements IResidentPatientInfoServi /** * @return void * @Author mengkuiliang - * @Description 注册 + * @Description 注册和完善信息 * @Date 2023-09-21 021 10:14 * @Param [body] **/ @Override public void register(PatientInfoBody body) { if (ObjectUtils.isNotEmpty(body.getCardNo())) { - // 获取当前微信绑定的居民 - List list = residentPatientInfoMapper.getList(body.getOpenid(), body.getCityCode()); - PatientInfo patientInfo = residentPatientInfoMapper.isRegisterByCardNo(body.getCardNo()); - if (patientInfo == null) { - PatientInfo entity = new PatientInfo(); - BeanUtils.copyBeanProp(entity, body); - entity.setPatientCode(IdUtils.fastSimpleUUID()); - entity.setBindingTime(new Date()); - entity.setIsChecked((list == null || list.size() == 0) ? "1" : "0"); - entity.setCreateTime(new Date()); - entity.setCreateBy(body.getCardNo()); - residentPatientInfoMapper.insertPatientInfo(entity); - } else { - if (!StringUtils.isBlank(patientInfo.getOpenid())) { - throw new ServiceException("该身份证号已被注册"); + // 修改 + if(!StringUtils.isBlank(body.getPatientCode())) { + PatientInfo patientInfo = residentPatientInfoMapper.getByCardNo(body.getCardNo()); + BeanUtils.copyBeanProp(patientInfo, body); + if(body.getDiseaseList() != null) { + patientInfo.setDisease(body.getDiseaseList().stream().collect(Collectors.joining(","))); + } + updatePatientInfo(patientInfo); + // 注册 + } else { + // 获取当前微信绑定的居民 + List list = residentPatientInfoMapper.getList(body.getOpenid(), body.getCityCode()); + PatientInfo patientInfo = residentPatientInfoMapper.isRegisterByCardNo(body.getCardNo()); + if (patientInfo == null) { + PatientInfo entity = new PatientInfo(); + BeanUtils.copyBeanProp(entity, body); + if(body.getDiseaseList() != null) { + entity.setDisease(body.getDiseaseList().stream().collect(Collectors.joining(","))); + } + entity.setPatientCode(IdUtils.fastSimpleUUID()); + entity.setBindingTime(new Date()); + entity.setIsChecked((list == null || list.size() == 0) ? "1" : "0"); + entity.setCreateTime(new Date()); + entity.setCreateBy(body.getCardNo()); + residentPatientInfoMapper.insertPatientInfo(entity); + } else { + if (!StringUtils.isBlank(patientInfo.getOpenid())) { + throw new ServiceException("该身份证号已被注册"); + } + patientInfo.setIsChecked((list == null || list.size() == 0) ? "1" : "0"); + patientInfo.setOpenid(body.getOpenid()); + patientInfo.setUnionid(body.getUnionid()); + patientInfo.setPatientName(body.getPatientName()); + patientInfo.setPhone(body.getPhone()); + patientInfo.setAddress(body.getAddress()); + patientInfo.setUpdateTime(new Date()); + patientInfo.setUpdateBy(body.getCardNo()); + patientInfo.setHeadPictureUrl(body.getHeadPictureUrl()); + patientInfo.setDelFlag(0); + if(body.getDiseaseList() != null) { + patientInfo.setDisease(body.getDiseaseList().stream().collect(Collectors.joining(","))); + } + residentPatientInfoMapper.updatePatientInfo(patientInfo); } - patientInfo.setIsChecked((list == null || list.size() == 0) ? "1" : "0"); - patientInfo.setOpenid(body.getOpenid()); - patientInfo.setUnionid(body.getUnionid()); - patientInfo.setPatientName(body.getPatientName()); - patientInfo.setPhone(body.getPhone()); - patientInfo.setAddress(body.getAddress()); - patientInfo.setUpdateTime(new Date()); - patientInfo.setUpdateBy(body.getCardNo()); - patientInfo.setHeadPictureUrl(body.getHeadPictureUrl()); - patientInfo.setDelFlag(0); - residentPatientInfoMapper.updatePatientInfo(patientInfo); } } } diff --git a/xinelu-familydoctor/src/main/java/com/xinelu/familydoctor/applet/service/impl/ResidentServiceApplyServiceImpl.java b/xinelu-familydoctor/src/main/java/com/xinelu/familydoctor/applet/service/impl/ResidentServiceApplyServiceImpl.java index 76f7161..b22bdf7 100644 --- a/xinelu-familydoctor/src/main/java/com/xinelu/familydoctor/applet/service/impl/ResidentServiceApplyServiceImpl.java +++ b/xinelu-familydoctor/src/main/java/com/xinelu/familydoctor/applet/service/impl/ResidentServiceApplyServiceImpl.java @@ -1,6 +1,8 @@ package com.xinelu.familydoctor.applet.service.impl; +import com.alibaba.fastjson2.JSONArray; import com.alibaba.fastjson2.JSONObject; +import com.xinelu.common.core.domain.R; import com.xinelu.common.exception.ServiceException; import com.xinelu.common.utils.DateUtils; import com.xinelu.common.utils.StringUtils; @@ -14,10 +16,13 @@ import com.xinelu.familydoctor.applet.pojo.dto.ResidentServiceFormApplyDto; import com.xinelu.familydoctor.applet.pojo.entity.PatientInfo; import com.xinelu.familydoctor.applet.pojo.entity.ResidentServiceApplyEntity; import com.xinelu.familydoctor.applet.pojo.query.ApplyQuery; -import com.xinelu.familydoctor.applet.pojo.vo.ResidentServiceApplyVo; -import com.xinelu.familydoctor.applet.pojo.vo.SignInfoDetailVo; +import com.xinelu.familydoctor.applet.pojo.vo.*; import com.xinelu.familydoctor.applet.service.IResidentPatientInfoService; import com.xinelu.familydoctor.applet.service.IResidentServiceAppletService; +import com.xinelu.manage.domain.hospitalinfo.HospitalInfo; +import com.xinelu.manage.domain.screeningproject.ScreeningProject; +import com.xinelu.manage.service.hospitalinfo.IHospitalInfoService; +import com.xinelu.manage.service.screeningproject.IScreeningProjectService; import org.springframework.beans.BeanUtils; import org.springframework.stereotype.Service; @@ -40,6 +45,10 @@ public class ResidentServiceApplyServiceImpl implements IResidentServiceAppletSe private HttpService httpService; @Resource private IResidentPatientInfoService patientInfoService; + @Resource + private IHospitalInfoService hospitalInfoService; + @Resource + private IScreeningProjectService screeningProjectService; /** * 新增服务申请 @@ -61,7 +70,7 @@ public class ResidentServiceApplyServiceImpl implements IResidentServiceAppletSe } ResidentServiceApplyEntity entity; PatientInfo patientInfo = null; - if(StringUtils.isBlank(body.getPatientId())) { + if (StringUtils.isBlank(body.getPatientId())) { patientInfo = patientInfoService.getByCardNo(body.getIdentity()); if (patientInfo == null) { throw new ServiceException("未查询到注册信息"); @@ -69,11 +78,11 @@ public class ResidentServiceApplyServiceImpl implements IResidentServiceAppletSe } List serviceApplyList = new ArrayList<>(); - for(ResidentServiceFormApplyDto form: body.getFormList()) { - if(!StringUtils.isBlank(form.getFormNo())) { + for (ResidentServiceFormApplyDto form : body.getFormList()) { + if (!StringUtils.isBlank(form.getFormNo())) { entity = new ResidentServiceApplyEntity(); BeanUtils.copyProperties(body, entity); - if(patientInfo != null) { + if (patientInfo != null) { entity.setPatientId(patientInfo.getPatientCode()); } entity.setApplyTime(new Date()); @@ -89,7 +98,7 @@ public class ResidentServiceApplyServiceImpl implements IResidentServiceAppletSe serviceApplyList.add(entity); } } - if(serviceApplyList.size() == 0) { + if (serviceApplyList.size() == 0) { throw new ServiceException("服务项目不能为空"); } residentServiceApplyMapper.batchInsert(serviceApplyList); @@ -178,9 +187,9 @@ public class ResidentServiceApplyServiceImpl implements IResidentServiceAppletSe throw new ServiceException("未查询到申请记录"); } if (!StringUtils.isBlank(residentServiceApplyVo.getBookingStatus())) { - if(residentServiceApplyVo.getBookingStatus().equals("1")) { + if (residentServiceApplyVo.getBookingStatus().equals("1")) { throw new ServiceException("已完成,不能取消"); - } else if(residentServiceApplyVo.getBookingStatus().equals("2")) { + } else if (residentServiceApplyVo.getBookingStatus().equals("2")) { throw new ServiceException("不能重复取消"); } } @@ -242,19 +251,90 @@ public class ResidentServiceApplyServiceImpl implements IResidentServiceAppletSe } /** + * @return java.util.List * @Author mengkuiliang * @Description 获取个性服务包和筛查项目 * @Date 2023-10-09 009 10:55 * @Param [identity] - * @return java.util.List **/ @Override - public List getForm(String identity) { + public List getForm(String identity, String region) { + List projectList = new ArrayList<>(); + + // 获取签约信息 + String result = (String) httpService.get(SpringUtils.getFdUrl(region) + "/resident/signinfo/detail/" + identity, null, String.class); + JSONObject jsonObject = JSONObject.parseObject(result); + if (!"1".equals(jsonObject.get("code"))) { + throw new ServiceException(jsonObject.get("msg").toString()); + } + if (!jsonObject.containsKey("data") || jsonObject.get("data") == null) { + throw new ServiceException("未查询到签约信息"); + } + SignInfoDetailVo signInfo = JSONObject.parseObject(jsonObject.getJSONObject("data").toJSONString(), SignInfoDetailVo.class); + if (signInfo == null) { + throw new ServiceException("未查询到签约信息!"); + } // 获取家医个性服务包 + result = (String) httpService.get(SpringUtils.getFdUrl(region) + "/package/getPackageOfGX/" + identity, null, String.class); + jsonObject = JSONObject.parseObject(result); + if (!"1".equals(jsonObject.get("code"))) { + throw new ServiceException(jsonObject.get("msg").toString()); + } + if (jsonObject.containsKey("data") && jsonObject.get("data") != null) { + List perList = JSONArray.parseArray(jsonObject.getJSONArray("data").toJSONString()).toJavaList(PerformanceDetailVo.class); + if (perList.size() > 0) { + ScreeningProjectVo sp; + for (PerformanceDetailVo per : perList) { + sp = new ScreeningProjectVo(); + sp.setDeptId(per.getOrgNo()); + sp.setDeptName(per.getOrgName()); + sp.setPackageId(per.getPackageNo()); + sp.setPackageName(per.getPackageName()); + sp.setProjectId(per.getFormNo()); + sp.setProjectName(per.getFormName()); + sp.setPrice(per.getPackCost()); + sp.setDiscountPrice(per.getPackSignCost()); + sp.setServiceFreq(per.getServiceFreq()); + sp.setPerformanceCount(per.getPerformanceCount()); + projectList.add(sp); + } + } + } // 获取签约机构下的筛查项目 + // 获取家医机构详情 + result = (String) httpService.get(SpringUtils.getFdUrl(region) + "/org/getOrgDetail/" + signInfo.getOrgNo(), null, String.class); + jsonObject = JSONObject.parseObject(result); + if ("1".equals(jsonObject.get("code"))) { + if (jsonObject.containsKey("data") && jsonObject.get("data") != null) { + OrgDetailVo org = JSONObject.parseObject(jsonObject.getJSONObject("data").toJSONString(), OrgDetailVo.class); + if (org != null && !StringUtils.isBlank(org.getPhOrgCode())) { + // 根据机构编码获取筛查机构 + HospitalInfo Hospital = hospitalInfoService.getHosptalByOrgCode(org.getPhOrgCode()); + if(Hospital != null) { + // 获取筛查项目 + ScreeningProject query = new ScreeningProject(); + query.setDeptId(Hospital.getHospitalCode()); + List screeningProjectList = screeningProjectService.findList(query); + if(screeningProjectList != null && screeningProjectList.size() > 0) { + ScreeningProjectVo sp; + for(ScreeningProject project: screeningProjectList) { + sp = new ScreeningProjectVo(); + sp.setDeptId(project.getDeptId()); + sp.setDeptName(project.getDeptName()); + sp.setProjectId(project.getProjectId()); + sp.setProjectName(project.getProjectName()); + sp.setPrice(project.getPrice()); + sp.setDiscountPrice(project.getDiscountPrice()); + projectList.add(sp); + } + } + } - return null; + } + } + } + return projectList; } } diff --git a/xinelu-familydoctor/src/main/resources/mapper/register/ResidentPatientInfoMapper.xml b/xinelu-familydoctor/src/main/resources/mapper/register/ResidentPatientInfoMapper.xml index d1229db..4d26796 100644 --- a/xinelu-familydoctor/src/main/resources/mapper/register/ResidentPatientInfoMapper.xml +++ b/xinelu-familydoctor/src/main/resources/mapper/register/ResidentPatientInfoMapper.xml @@ -41,6 +41,7 @@ + @@ -83,6 +84,7 @@ personal_wechat_code_url, disabling_condition, disabling_reason, + disease, city_code, binding_time, is_checked @@ -196,6 +198,9 @@ disabling_reason, + + disease, + city_code, binding_time, @@ -274,6 +279,7 @@ #{disablingReason}, + #{disease}, #{cityCode}, #{bindingTime}, @@ -388,6 +394,9 @@ disabling_reason = #{disablingReason}, + + disease = #{disease}, + city_code = #{cityCode}, diff --git a/xinelu-nurse-manage/src/main/java/com/xinelu/manage/mapper/hospitalinfo/HospitalInfoMapper.java b/xinelu-nurse-manage/src/main/java/com/xinelu/manage/mapper/hospitalinfo/HospitalInfoMapper.java index 3ddc486..8e9b16c 100644 --- a/xinelu-nurse-manage/src/main/java/com/xinelu/manage/mapper/hospitalinfo/HospitalInfoMapper.java +++ b/xinelu-nurse-manage/src/main/java/com/xinelu/manage/mapper/hospitalinfo/HospitalInfoMapper.java @@ -74,4 +74,13 @@ public interface HospitalInfoMapper { * @return List */ List selectHospitalList(Long[] ids); + + /** + * @Author mengkuiliang + * @Description 根据家医机构编码查询医院 + * @Date 2023-10-09 009 15:47 + * @Param [orgCode] + * @return com.xinelu.manage.domain.hospitalinfo.HospitalInfo + **/ + HospitalInfo getHosptalByOrgCode(String orgCode); } diff --git a/xinelu-nurse-manage/src/main/java/com/xinelu/manage/service/hospitalinfo/IHospitalInfoService.java b/xinelu-nurse-manage/src/main/java/com/xinelu/manage/service/hospitalinfo/IHospitalInfoService.java index bef90c8..084eead 100644 --- a/xinelu-nurse-manage/src/main/java/com/xinelu/manage/service/hospitalinfo/IHospitalInfoService.java +++ b/xinelu-nurse-manage/src/main/java/com/xinelu/manage/service/hospitalinfo/IHospitalInfoService.java @@ -59,4 +59,13 @@ public interface IHospitalInfoService { * @return 结果 */ int deleteHospitalInfoById(Long id); + + /** + * @Author mengkuiliang + * @Description 根据家医机构编码查询医院 + * @Date 2023-10-09 009 15:46 + * @Param + * @return + **/ + HospitalInfo getHosptalByOrgCode(String orgCode); } diff --git a/xinelu-nurse-manage/src/main/java/com/xinelu/manage/service/hospitalinfo/impl/HospitalInfoServiceImpl.java b/xinelu-nurse-manage/src/main/java/com/xinelu/manage/service/hospitalinfo/impl/HospitalInfoServiceImpl.java index f0b5f66..b3b012e 100644 --- a/xinelu-nurse-manage/src/main/java/com/xinelu/manage/service/hospitalinfo/impl/HospitalInfoServiceImpl.java +++ b/xinelu-nurse-manage/src/main/java/com/xinelu/manage/service/hospitalinfo/impl/HospitalInfoServiceImpl.java @@ -198,5 +198,17 @@ public class HospitalInfoServiceImpl implements IHospitalInfoService { } } } + + /** + * @Author mengkuiliang + * @Description 根据家医机构编码查询医院 + * @Date 2023-10-09 009 15:47 + * @Param [orgCode] + * @return com.xinelu.manage.domain.hospitalinfo.HospitalInfo + **/ + @Override + public HospitalInfo getHosptalByOrgCode(String orgCode) { + return hospitalInfoMapper.getHosptalByOrgCode(orgCode); + } } diff --git a/xinelu-nurse-manage/src/main/resources/mapper/manage/hospitalinfo/HospitalInfoMapper.xml b/xinelu-nurse-manage/src/main/resources/mapper/manage/hospitalinfo/HospitalInfoMapper.xml index 756ffef..f13ff9a 100644 --- a/xinelu-nurse-manage/src/main/resources/mapper/manage/hospitalinfo/HospitalInfoMapper.xml +++ b/xinelu-nurse-manage/src/main/resources/mapper/manage/hospitalinfo/HospitalInfoMapper.xml @@ -176,4 +176,10 @@ #{ids} + + +