1、修改获取服务预约列表接口;
2、修改其他代码;
This commit is contained in:
parent
7d17791ac1
commit
43b0a22561
@ -66,6 +66,9 @@ public class ResidentPatientInfoController extends BaseController {
|
|||||||
@ApiOperation("注册完善信息")
|
@ApiOperation("注册完善信息")
|
||||||
@PostMapping("")
|
@PostMapping("")
|
||||||
public R<String> register(@Validated @RequestBody PatientInfoBody body) {
|
public R<String> register(@Validated @RequestBody PatientInfoBody body) {
|
||||||
|
if(body.getDiseaseList() == null || body.getDiseaseList().size() == 0) {
|
||||||
|
return R.fail("请选择基础疾病");
|
||||||
|
}
|
||||||
try {
|
try {
|
||||||
residentPatientInfoService.register(body);
|
residentPatientInfoService.register(body);
|
||||||
return R.ok();
|
return R.ok();
|
||||||
|
|||||||
@ -69,7 +69,7 @@ public class ResidentServiceApplyController extends BaseController {
|
|||||||
return R.ok(residentServiceAppletService.detail(bookingNo));
|
return R.ok(residentServiceAppletService.detail(bookingNo));
|
||||||
}
|
}
|
||||||
|
|
||||||
@ApiOperation("获取个性服务包和筛查项目")
|
@ApiOperation(value = "获取服务预约列表", notes = "获取家医个性服务包和筛查项目")
|
||||||
@GetMapping("/getForm/{identity}")
|
@GetMapping("/getForm/{identity}")
|
||||||
public R<List<ScreeningProjectVo>> getForm(@PathVariable String identity, @RequestHeader("region") String region) {
|
public R<List<ScreeningProjectVo>> getForm(@PathVariable String identity, @RequestHeader("region") String region) {
|
||||||
return R.ok(residentServiceAppletService.getForm(identity, region));
|
return R.ok(residentServiceAppletService.getForm(identity, region));
|
||||||
|
|||||||
@ -35,7 +35,7 @@ import java.util.List;
|
|||||||
public class SignInfoController extends BaseController {
|
public class SignInfoController extends BaseController {
|
||||||
@Resource
|
@Resource
|
||||||
private HttpService httpService;
|
private HttpService httpService;
|
||||||
@Value("${applet.distance}")
|
@Value("${fd.distance}")
|
||||||
private BigDecimal DISTANCE;
|
private BigDecimal DISTANCE;
|
||||||
|
|
||||||
@ApiOperation(value = "获取签约详情")
|
@ApiOperation(value = "获取签约详情")
|
||||||
|
|||||||
@ -233,15 +233,12 @@ xss:
|
|||||||
# 匹配链接
|
# 匹配链接
|
||||||
urlPatterns: /system/*,/monitor/*,/tool/*
|
urlPatterns: /system/*,/monitor/*,/tool/*
|
||||||
|
|
||||||
# 家医签约附近的机构
|
# 家医配置
|
||||||
applet:
|
|
||||||
# 多少公里内
|
|
||||||
distance: 100.00
|
|
||||||
|
|
||||||
# 家医请求地址
|
|
||||||
fd:
|
fd:
|
||||||
dy: http://192.168.124.6:8001/fd/mp
|
dy: http://192.168.124.6:8001/fd/mp
|
||||||
dz: http://192.168.124.6:8001/fd/mp
|
dz: http://192.168.124.6:8001/fd/mp
|
||||||
|
# 签约附近的机构多少公里内
|
||||||
|
distance: 100.00
|
||||||
|
|
||||||
# 腾讯云音视频
|
# 腾讯云音视频
|
||||||
trtc:
|
trtc:
|
||||||
|
|||||||
@ -40,7 +40,7 @@ public class ResidentServiceApplyBody {
|
|||||||
/**
|
/**
|
||||||
* 预约服务方式1:家庭2:门诊3:电话99:其他
|
* 预约服务方式1:家庭2:门诊3:电话99:其他
|
||||||
*/
|
*/
|
||||||
@ApiModelProperty(value = "预约服务方式1:家庭2:门诊3:电话99:其他", required = true)
|
@ApiModelProperty(value = "预约服务方式1:家庭2:门诊3:电话99:其他", hidden = true)
|
||||||
private String serviceWay;
|
private String serviceWay;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
|||||||
@ -286,6 +286,7 @@ public class ResidentServiceApplyServiceImpl implements IResidentServiceAppletSe
|
|||||||
ScreeningProjectVo sp;
|
ScreeningProjectVo sp;
|
||||||
for (PerformanceDetailVo per : perList) {
|
for (PerformanceDetailVo per : perList) {
|
||||||
sp = new ScreeningProjectVo();
|
sp = new ScreeningProjectVo();
|
||||||
|
sp.setSourceType("1");
|
||||||
sp.setDeptId(per.getOrgNo());
|
sp.setDeptId(per.getOrgNo());
|
||||||
sp.setDeptName(per.getOrgName());
|
sp.setDeptName(per.getOrgName());
|
||||||
sp.setPackageId(per.getPackageNo());
|
sp.setPackageId(per.getPackageNo());
|
||||||
@ -308,20 +309,21 @@ public class ResidentServiceApplyServiceImpl implements IResidentServiceAppletSe
|
|||||||
if ("1".equals(jsonObject.get("code"))) {
|
if ("1".equals(jsonObject.get("code"))) {
|
||||||
if (jsonObject.containsKey("data") && jsonObject.get("data") != null) {
|
if (jsonObject.containsKey("data") && jsonObject.get("data") != null) {
|
||||||
OrgDetailVo org = JSONObject.parseObject(jsonObject.getJSONObject("data").toJSONString(), OrgDetailVo.class);
|
OrgDetailVo org = JSONObject.parseObject(jsonObject.getJSONObject("data").toJSONString(), OrgDetailVo.class);
|
||||||
if (org != null && !StringUtils.isBlank(org.getPhOrgCode())) {
|
if (org != null && !StringUtils.isBlank(org.getPhOrgId())) {
|
||||||
// 根据机构编码获取筛查机构
|
// 根据机构编码获取筛查机构
|
||||||
HospitalInfo Hospital = hospitalInfoService.getHosptalByOrgCode(org.getPhOrgCode());
|
HospitalInfo Hospital = hospitalInfoService.getHosptalByOrgCode(org.getPhOrgId());
|
||||||
if(Hospital != null) {
|
if(Hospital != null) {
|
||||||
// 获取筛查项目
|
// 获取筛查项目
|
||||||
ScreeningProject query = new ScreeningProject();
|
ScreeningProject query = new ScreeningProject();
|
||||||
query.setDeptId(Hospital.getHospitalCode());
|
query.setHospitalId(String.valueOf(Hospital.getId()));
|
||||||
List<ScreeningProject> screeningProjectList = screeningProjectService.findList(query);
|
List<ScreeningProject> screeningProjectList = screeningProjectService.findList(query);
|
||||||
if(screeningProjectList != null && screeningProjectList.size() > 0) {
|
if(screeningProjectList != null && screeningProjectList.size() > 0) {
|
||||||
ScreeningProjectVo sp;
|
ScreeningProjectVo sp;
|
||||||
for(ScreeningProject project: screeningProjectList) {
|
for(ScreeningProject project: screeningProjectList) {
|
||||||
sp = new ScreeningProjectVo();
|
sp = new ScreeningProjectVo();
|
||||||
sp.setDeptId(project.getDeptId());
|
sp.setSourceType("2");
|
||||||
sp.setDeptName(project.getDeptName());
|
sp.setDeptId(project.getHospitalId());
|
||||||
|
sp.setDeptName(project.getHospitalName());
|
||||||
sp.setProjectId(project.getProjectId());
|
sp.setProjectId(project.getProjectId());
|
||||||
sp.setProjectName(project.getProjectName());
|
sp.setProjectName(project.getProjectName());
|
||||||
sp.setPrice(project.getPrice());
|
sp.setPrice(project.getPrice());
|
||||||
|
|||||||
@ -53,8 +53,8 @@ public class ScreeningProjectController extends BaseController {
|
|||||||
@ApiOperation("新增服务项目")
|
@ApiOperation("新增服务项目")
|
||||||
@PostMapping("add")
|
@PostMapping("add")
|
||||||
public R<String> add(@RequestBody ScreeningProject project) {
|
public R<String> add(@RequestBody ScreeningProject project) {
|
||||||
if (projectService.checkSameProjectName(project.getProjectName(), project.getDeptId(), null)) {
|
if (projectService.checkSameProjectName(project.getProjectName(), project.getHospitalId(), null)) {
|
||||||
return R.fail("【" + project.getDeptName() + "】已存在服务项目【" + project.getProjectName() + "】,不能重复添加");
|
return R.fail("【" + project.getHospitalName() + "】已存在服务项目【" + project.getProjectName() + "】,不能重复添加");
|
||||||
}
|
}
|
||||||
//价格校验
|
//价格校验
|
||||||
if (Objects.isNull(project.getDiscount())) {
|
if (Objects.isNull(project.getDiscount())) {
|
||||||
@ -83,8 +83,8 @@ public class ScreeningProjectController extends BaseController {
|
|||||||
@ApiOperation("修改服务项目")
|
@ApiOperation("修改服务项目")
|
||||||
@PostMapping("update")
|
@PostMapping("update")
|
||||||
public R<?> update(@RequestBody ScreeningProject project) {
|
public R<?> update(@RequestBody ScreeningProject project) {
|
||||||
if (projectService.checkSameProjectName(project.getProjectName(), project.getDeptId(), project.getProjectId())) {
|
if (projectService.checkSameProjectName(project.getProjectName(), project.getHospitalId(), project.getProjectId())) {
|
||||||
return R.fail("【" + project.getDeptName() + "】已存在服务项目【" + project.getProjectName() + "】,不能重复添加");
|
return R.fail("【" + project.getHospitalName() + "】已存在服务项目【" + project.getProjectName() + "】,不能重复添加");
|
||||||
}
|
}
|
||||||
//价格校验
|
//价格校验
|
||||||
if (Objects.isNull(project.getDiscount())) {
|
if (Objects.isNull(project.getDiscount())) {
|
||||||
|
|||||||
@ -60,13 +60,13 @@ public class ScreeningProject extends BaseEntity {
|
|||||||
* 医院编号
|
* 医院编号
|
||||||
*/
|
*/
|
||||||
@ApiModelProperty("医院编号")
|
@ApiModelProperty("医院编号")
|
||||||
private String deptId;
|
private String hospitalId;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* 医院名称
|
* 医院名称
|
||||||
*/
|
*/
|
||||||
@ApiModelProperty("医院名称")
|
@ApiModelProperty("医院名称")
|
||||||
private String deptName;
|
private String hospitalName;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* 删除标识(0:存在,1:已删除)
|
* 删除标识(0:存在,1:已删除)
|
||||||
|
|||||||
@ -26,6 +26,6 @@ public interface ScreeningProjectMapper {
|
|||||||
|
|
||||||
int updateByPrimaryKey(ScreeningProject record);
|
int updateByPrimaryKey(ScreeningProject record);
|
||||||
|
|
||||||
Integer checkSameName(@Param("projectName") String projectName, @Param("deptId") String deptId, @Param("projectId") String projectId);
|
Integer checkSameName(@Param("projectName") String projectName, @Param("hospitalId") String hospitalId, @Param("projectId") String projectId);
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|||||||
@ -42,7 +42,7 @@ public class ScreeningProjectServiceImpl implements IScreeningProjectService {
|
|||||||
projectMapper.updateByPrimaryKeySelective(project);
|
projectMapper.updateByPrimaryKeySelective(project);
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override public boolean checkSameProjectName(String projectName, String deptId, String projectId) {
|
@Override public boolean checkSameProjectName(String projectName, String hospitalId, String projectId) {
|
||||||
return projectMapper.checkSameName(projectName, deptId, projectId) != null;
|
return projectMapper.checkSameName(projectName, hospitalId, projectId) != null;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@ -13,8 +13,8 @@
|
|||||||
<result property="discount" column="discount" jdbcType="INTEGER"/>
|
<result property="discount" column="discount" jdbcType="INTEGER"/>
|
||||||
<result property="discountPrice" column="discount_price" jdbcType="VARCHAR"/>
|
<result property="discountPrice" column="discount_price" jdbcType="VARCHAR"/>
|
||||||
<result property="status" column="status" jdbcType="CHAR"/>
|
<result property="status" column="status" jdbcType="CHAR"/>
|
||||||
<result property="deptId" column="dept_id" jdbcType="VARCHAR"/>
|
<result property="hospitalId" column="hospital_id" jdbcType="VARCHAR"/>
|
||||||
<result property="deptName" column="dept_name" jdbcType="VARCHAR"/>
|
<result property="hospitalName" column="hospital_name" jdbcType="VARCHAR"/>
|
||||||
<result property="createBy" column="create_by" jdbcType="VARCHAR"/>
|
<result property="createBy" column="create_by" jdbcType="VARCHAR"/>
|
||||||
<result property="createTime" column="create_time" jdbcType="DATE"/>
|
<result property="createTime" column="create_time" jdbcType="DATE"/>
|
||||||
<result property="updateBy" column="update_by" jdbcType="VARCHAR"/>
|
<result property="updateBy" column="update_by" jdbcType="VARCHAR"/>
|
||||||
@ -26,8 +26,8 @@
|
|||||||
<sql id="Base_Column_List">
|
<sql id="Base_Column_List">
|
||||||
id,project_id,project_name,
|
id,project_id,project_name,
|
||||||
project_type,price,discount,
|
project_type,price,discount,
|
||||||
discount_price,status,dept_id,
|
discount_price,status,hospital_id,
|
||||||
dept_name,create_by,create_time,
|
hospital_name,create_by,create_time,
|
||||||
update_by,update_time,del_flag,
|
update_by,update_time,del_flag,
|
||||||
remark
|
remark
|
||||||
</sql>
|
</sql>
|
||||||
@ -39,8 +39,8 @@
|
|||||||
<if test="projectName != null and projectName != ''">
|
<if test="projectName != null and projectName != ''">
|
||||||
and project_name like concat( '%' ,#{projectName}, '%')
|
and project_name like concat( '%' ,#{projectName}, '%')
|
||||||
</if>
|
</if>
|
||||||
<if test="deptId != null and deptId != ''">
|
<if test="hospitalId != null and hospitalId != ''">
|
||||||
and dept_id = #{deptId}
|
and hospital_id = #{hospitalId}
|
||||||
</if>
|
</if>
|
||||||
<if test="projectType != null and projectType != ''">
|
<if test="projectType != null and projectType != ''">
|
||||||
and project_type = #{projectType}
|
and project_type = #{projectType}
|
||||||
@ -69,14 +69,14 @@
|
|||||||
insert into screening_project
|
insert into screening_project
|
||||||
( id,project_id,project_name
|
( id,project_id,project_name
|
||||||
,project_type,price,discount
|
,project_type,price,discount
|
||||||
,discount_price,status,dept_id
|
,discount_price,status,hospital_id
|
||||||
,dept_name,create_by,create_time
|
,hospital_name,create_by,create_time
|
||||||
,update_by,update_time,del_flag
|
,update_by,update_time,del_flag
|
||||||
,remark)
|
,remark)
|
||||||
values (#{id,jdbcType=BIGINT},#{projectId,jdbcType=VARCHAR},#{projectName,jdbcType=VARCHAR}
|
values (#{id,jdbcType=BIGINT},#{projectId,jdbcType=VARCHAR},#{projectName,jdbcType=VARCHAR}
|
||||||
,#{projectType,jdbcType=CHAR},#{price,jdbcType=DECIMAL},#{discount,jdbcType=INTEGER}
|
,#{projectType,jdbcType=CHAR},#{price,jdbcType=DECIMAL},#{discount,jdbcType=INTEGER}
|
||||||
,#{discountPrice,jdbcType=VARCHAR},#{status,jdbcType=CHAR},#{deptId,jdbcType=VARCHAR}
|
,#{discountPrice,jdbcType=VARCHAR},#{status,jdbcType=CHAR},#{hospitalId,jdbcType=VARCHAR}
|
||||||
,#{deptName,jdbcType=VARCHAR},#{createBy,jdbcType=VARCHAR},#{createTime,jdbcType=DATE}
|
,#{hospitalName,jdbcType=VARCHAR},#{createBy,jdbcType=VARCHAR},#{createTime,jdbcType=DATE}
|
||||||
,#{updateBy,jdbcType=VARCHAR},#{updateTime,jdbcType=DATE},#{delFlag,jdbcType=CHAR}
|
,#{updateBy,jdbcType=VARCHAR},#{updateTime,jdbcType=DATE},#{delFlag,jdbcType=CHAR}
|
||||||
,#{remark,jdbcType=VARCHAR})
|
,#{remark,jdbcType=VARCHAR})
|
||||||
</insert>
|
</insert>
|
||||||
@ -91,8 +91,8 @@
|
|||||||
<if test="discount != null">discount,</if>
|
<if test="discount != null">discount,</if>
|
||||||
<if test="discountPrice != null">discount_price,</if>
|
<if test="discountPrice != null">discount_price,</if>
|
||||||
<if test="status != null">status,</if>
|
<if test="status != null">status,</if>
|
||||||
<if test="deptId != null">dept_id,</if>
|
<if test="hospitalId != null">hospital_id,</if>
|
||||||
<if test="deptName != null">dept_name,</if>
|
<if test="hospitalName != null">hospital_name,</if>
|
||||||
<if test="createBy != null">create_by,</if>
|
<if test="createBy != null">create_by,</if>
|
||||||
<if test="createTime != null">create_time,</if>
|
<if test="createTime != null">create_time,</if>
|
||||||
<if test="updateBy != null">update_by,</if>
|
<if test="updateBy != null">update_by,</if>
|
||||||
@ -109,8 +109,8 @@
|
|||||||
<if test="discount != null">#{discount,jdbcType=INTEGER},</if>
|
<if test="discount != null">#{discount,jdbcType=INTEGER},</if>
|
||||||
<if test="discountPrice != null">#{discountPrice,jdbcType=DECIMAL},</if>
|
<if test="discountPrice != null">#{discountPrice,jdbcType=DECIMAL},</if>
|
||||||
<if test="status != null">#{status,jdbcType=CHAR},</if>
|
<if test="status != null">#{status,jdbcType=CHAR},</if>
|
||||||
<if test="deptId != null">#{deptId,jdbcType=VARCHAR},</if>
|
<if test="hospitalId != null">#{hospitalId,jdbcType=VARCHAR},</if>
|
||||||
<if test="deptName != null">#{deptName,jdbcType=VARCHAR},</if>
|
<if test="hospitalName != null">#{hospitalName,jdbcType=VARCHAR},</if>
|
||||||
<if test="createBy != null">#{createBy,jdbcType=VARCHAR},</if>
|
<if test="createBy != null">#{createBy,jdbcType=VARCHAR},</if>
|
||||||
<if test="createTime != null">#{createTime,jdbcType=DATE},</if>
|
<if test="createTime != null">#{createTime,jdbcType=DATE},</if>
|
||||||
<if test="updateBy != null">#{updateBy,jdbcType=VARCHAR},</if>
|
<if test="updateBy != null">#{updateBy,jdbcType=VARCHAR},</if>
|
||||||
@ -140,11 +140,11 @@
|
|||||||
<if test="status != null">
|
<if test="status != null">
|
||||||
status = #{status,jdbcType=CHAR},
|
status = #{status,jdbcType=CHAR},
|
||||||
</if>
|
</if>
|
||||||
<if test="deptId != null">
|
<if test="hospitalId != null">
|
||||||
dept_id = #{deptId,jdbcType=VARCHAR},
|
hospital_id = #{hospitalId,jdbcType=VARCHAR},
|
||||||
</if>
|
</if>
|
||||||
<if test="deptName != null">
|
<if test="hospitalName != null">
|
||||||
dept_name = #{deptName,jdbcType=VARCHAR},
|
hospital_name = #{hospitalName,jdbcType=VARCHAR},
|
||||||
</if>
|
</if>
|
||||||
<if test="createBy != null">
|
<if test="createBy != null">
|
||||||
create_by = #{createBy,jdbcType=VARCHAR},
|
create_by = #{createBy,jdbcType=VARCHAR},
|
||||||
@ -176,8 +176,8 @@
|
|||||||
discount = #{discount,jdbcType=INTEGER},
|
discount = #{discount,jdbcType=INTEGER},
|
||||||
discount_price = #{discountPrice,jdbcType=VARCHAR},
|
discount_price = #{discountPrice,jdbcType=VARCHAR},
|
||||||
status = #{status,jdbcType=CHAR},
|
status = #{status,jdbcType=CHAR},
|
||||||
dept_id = #{deptId,jdbcType=VARCHAR},
|
hospital_id = #{hospitalId,jdbcType=VARCHAR},
|
||||||
dept_name = #{deptName,jdbcType=VARCHAR},
|
hospital_name = #{hospitalName,jdbcType=VARCHAR},
|
||||||
create_by = #{createBy,jdbcType=VARCHAR},
|
create_by = #{createBy,jdbcType=VARCHAR},
|
||||||
create_time = #{createTime,jdbcType=DATE},
|
create_time = #{createTime,jdbcType=DATE},
|
||||||
update_by = #{updateBy,jdbcType=VARCHAR},
|
update_by = #{updateBy,jdbcType=VARCHAR},
|
||||||
@ -187,7 +187,7 @@
|
|||||||
where project_id = #{projectId,jdbcType=VARCHAR}
|
where project_id = #{projectId,jdbcType=VARCHAR}
|
||||||
</update>
|
</update>
|
||||||
<select id="checkSameName" resultType="java.lang.Integer">
|
<select id="checkSameName" resultType="java.lang.Integer">
|
||||||
select 1 from screening_project where del_flag = '0' and project_name = #{projectName} and dept_id = #{deptId}
|
select 1 from screening_project where del_flag = '0' and project_name = #{projectName} and hospital_id = #{hospitalId}
|
||||||
<if test="projectId != null and projectId != ''">
|
<if test="projectId != null and projectId != ''">
|
||||||
and project_id != #{projectId}
|
and project_id != #{projectId}
|
||||||
</if>
|
</if>
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user