Merge branch 'dev_gy_0920' of http://182.92.166.109:3000/jihan/xinelu-api into dev_gy_0920
Conflicts: xinelu-admin/src/main/resources/application.yml
This commit is contained in:
commit
3f0902a7da
@ -108,6 +108,7 @@ public class ResidentPatientInfoController extends BaseController {
|
||||
try {
|
||||
return R.ok(residentPatientInfoService.switchResident(openid, patientCode));
|
||||
} catch (Exception e) {
|
||||
e.printStackTrace();
|
||||
return R.fail(e.getMessage());
|
||||
}
|
||||
}
|
||||
@ -127,6 +128,12 @@ public class ResidentPatientInfoController extends BaseController {
|
||||
return R.ok(residentPatientInfoService.getCurrentResident(openid, cityCode));
|
||||
}
|
||||
|
||||
@ApiOperation("是否已注册")
|
||||
@GetMapping(value = "/isRegistered/{code}")
|
||||
public R<PatientInfo> isRegistered(@PathVariable("code") String code) {
|
||||
return R.ok(residentPatientInfoService.isRegistered(code));
|
||||
}
|
||||
|
||||
/**
|
||||
* @Author mengkuiliang
|
||||
* @Description 居民头像上传
|
||||
@ -134,22 +141,22 @@ public class ResidentPatientInfoController extends BaseController {
|
||||
* @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;
|
||||
}
|
||||
// @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;
|
||||
// }
|
||||
}
|
||||
|
||||
@ -53,6 +53,7 @@ public class ResidentRescindApplyController extends BaseController {
|
||||
List<ResidentRescindApplyVo> list = rescindApplyService.findList(query);
|
||||
return getDataTable(list);
|
||||
} catch (Exception e) {
|
||||
e.printStackTrace();
|
||||
throw new ServiceException(e.getMessage());
|
||||
}
|
||||
}
|
||||
@ -63,6 +64,7 @@ public class ResidentRescindApplyController extends BaseController {
|
||||
try {
|
||||
return R.ok(rescindApplyService.detail(applyNo));
|
||||
} catch (Exception e) {
|
||||
e.printStackTrace();
|
||||
return R.fail(e.getMessage());
|
||||
}
|
||||
}
|
||||
|
||||
@ -32,12 +32,15 @@ public class ResidentServiceApplyController extends BaseController {
|
||||
@Resource
|
||||
private IResidentServiceAppletService residentServiceAppletService;
|
||||
|
||||
@ApiOperation("提交服务申请(批量)")
|
||||
@ApiOperation("提交服务申请")
|
||||
@PostMapping("/save")
|
||||
public R<?> save(@RequestBody ResidentServiceApplyBody body) {
|
||||
if (body == null || body.getFormList() == null || body.getFormList().size() == 0) {
|
||||
if (body == null || StringUtils.isBlank(body.getPackageNo()) || StringUtils.isBlank(body.getFormNo())) {
|
||||
return R.fail("请求参数不能为空");
|
||||
}
|
||||
if(StringUtils.isBlank(body.getIdentity())) {
|
||||
return R.fail("居民身份证号不能为空");
|
||||
}
|
||||
residentServiceAppletService.insert(body);
|
||||
return R.ok();
|
||||
}
|
||||
@ -59,6 +62,7 @@ public class ResidentServiceApplyController extends BaseController {
|
||||
startPage();
|
||||
return getDataTable(residentServiceAppletService.findList(query));
|
||||
} catch (Exception e) {
|
||||
e.printStackTrace();
|
||||
throw new ServiceException(e.getMessage());
|
||||
}
|
||||
}
|
||||
@ -69,9 +73,9 @@ public class ResidentServiceApplyController extends BaseController {
|
||||
return R.ok(residentServiceAppletService.detail(bookingNo));
|
||||
}
|
||||
|
||||
@ApiOperation(value = "获取服务预约列表", notes = "获取家医个性服务包和筛查项目")
|
||||
@ApiOperation(value = "获取服务预约项目列表", notes = "获取家医个性服务包和筛查项目")
|
||||
@GetMapping("/getForm/{identity}")
|
||||
public R<List<ScreeningProjectVo>> getForm(@PathVariable String identity, @RequestHeader("region") String region) {
|
||||
return R.ok(residentServiceAppletService.getForm(identity, region));
|
||||
public R<List<ScreeningProjectVo>> getForm(@PathVariable String identity, String projectName, @RequestHeader("region") String region) {
|
||||
return R.ok(residentServiceAppletService.getForm(identity, projectName,region));
|
||||
}
|
||||
}
|
||||
|
||||
@ -1,9 +1,18 @@
|
||||
package com.xinelu.web.controller.applet;
|
||||
|
||||
import com.alibaba.fastjson2.JSONObject;
|
||||
import com.xinelu.common.config.XinELuConfig;
|
||||
import com.xinelu.common.core.controller.BaseController;
|
||||
import com.xinelu.common.core.domain.AjaxResult;
|
||||
import com.xinelu.common.core.domain.R;
|
||||
import com.xinelu.common.core.page.TableDataInfo;
|
||||
import com.xinelu.common.exception.ServiceException;
|
||||
import com.xinelu.common.utils.file.FileUploadUtils;
|
||||
import com.xinelu.common.utils.file.FileUtils;
|
||||
import com.xinelu.common.utils.file.MimeTypeUtils;
|
||||
import com.xinelu.common.utils.http.HttpService;
|
||||
import com.xinelu.common.utils.spring.SpringUtils;
|
||||
import com.xinelu.familydoctor.applet.pojo.body.FileUploadBody;
|
||||
import com.xinelu.familydoctor.applet.pojo.body.ResidentSignApplyBody;
|
||||
import com.xinelu.familydoctor.applet.pojo.query.ApplyQuery;
|
||||
import com.xinelu.familydoctor.applet.pojo.vo.ResidentSignApplyVo;
|
||||
@ -11,9 +20,12 @@ import com.xinelu.familydoctor.applet.service.IResidentSignAppletService;
|
||||
import io.swagger.annotations.Api;
|
||||
import io.swagger.annotations.ApiOperation;
|
||||
import org.apache.commons.lang3.StringUtils;
|
||||
import org.aspectj.weaver.loadtime.Aj;
|
||||
import org.springframework.web.bind.annotation.*;
|
||||
import org.springframework.web.multipart.MultipartFile;
|
||||
|
||||
import javax.annotation.Resource;
|
||||
import java.util.Base64;
|
||||
import java.util.List;
|
||||
|
||||
/**
|
||||
@ -30,13 +42,21 @@ public class ResidentSignApplyController extends BaseController {
|
||||
|
||||
@Resource
|
||||
private IResidentSignAppletService residentSignAppletService;
|
||||
@Resource
|
||||
private HttpService httpService;
|
||||
|
||||
@ApiOperation("提交签约申请")
|
||||
@PostMapping("/save")
|
||||
public R<String> save(@RequestBody ResidentSignApplyBody body) {
|
||||
if(StringUtils.isBlank(body.getIdentity())) {
|
||||
if (StringUtils.isBlank(body.getIdentity())) {
|
||||
return R.fail("身份证号不能为空");
|
||||
}
|
||||
if (body.getCrowdList() == null || body.getCrowdList().size() == 0) {
|
||||
return R.fail("人群不能为空");
|
||||
}
|
||||
if (body.getPackageList() == null || body.getPackageList().size() == 0) {
|
||||
return R.fail("服务包不能为空");
|
||||
}
|
||||
residentSignAppletService.insert(body);
|
||||
return R.ok();
|
||||
}
|
||||
@ -54,6 +74,7 @@ public class ResidentSignApplyController extends BaseController {
|
||||
try {
|
||||
return R.ok(residentSignAppletService.checkSignApply(identity, region));
|
||||
} catch (Exception e) {
|
||||
e.printStackTrace();
|
||||
return R.fail(e.getMessage());
|
||||
}
|
||||
}
|
||||
@ -66,6 +87,7 @@ public class ResidentSignApplyController extends BaseController {
|
||||
List<ResidentSignApplyVo> list = residentSignAppletService.findList(query);
|
||||
return getDataTable(list);
|
||||
} catch (Exception e) {
|
||||
e.printStackTrace();
|
||||
throw new ServiceException(e.getMessage());
|
||||
}
|
||||
}
|
||||
@ -76,8 +98,46 @@ public class ResidentSignApplyController extends BaseController {
|
||||
try {
|
||||
return R.ok(residentSignAppletService.detail(bookingNo));
|
||||
} catch (Exception e) {
|
||||
e.printStackTrace();
|
||||
return R.fail(e.getMessage());
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@ApiOperation("居民签字上传")
|
||||
@PostMapping(value = "/residentSignatureUpload")
|
||||
public AjaxResult headPictureUpload(MultipartFile file, @RequestHeader("region") String region) throws Exception {
|
||||
if (StringUtils.isBlank(file.getOriginalFilename())) {
|
||||
return AjaxResult.error("请选择所要上传的居民签字!");
|
||||
}
|
||||
FileUploadBody body = new FileUploadBody();
|
||||
body.setOriginalFilename(file.getOriginalFilename());
|
||||
body.setCode("1001");
|
||||
body.setContentType(file.getContentType());
|
||||
body.setSuffix(body.getOriginalFilename().substring(body.getOriginalFilename().lastIndexOf(".") + 1));
|
||||
body.setFile(Base64.getEncoder().encodeToString(file.getBytes()));
|
||||
// 上传家医
|
||||
JSONObject result = httpService.post(SpringUtils.getFdUrl(region) + "/resident/signinfo/uploadBase64", null, JSONObject.parseObject(JSONObject.toJSONString(body)));
|
||||
if ("0".equals(result.get("code"))) {
|
||||
return AjaxResult.error(result.get("msg").toString());
|
||||
}
|
||||
AjaxResult ajax = AjaxResult.success("上传成功!");
|
||||
ajax.put("imgUrl", result.getString("data"));
|
||||
return ajax;
|
||||
}
|
||||
|
||||
@ApiOperation("获取居民签字")
|
||||
@GetMapping(value = "/getResidentSignature/{fileNo}")
|
||||
public AjaxResult getResidentSignature(@PathVariable String fileNo, @RequestHeader("region") String region) {
|
||||
String result = (String) httpService.get(SpringUtils.getFdUrl(region) + "/resident/signinfo/getSignBase64/" + fileNo, null, String.class);
|
||||
JSONObject jsonObject = JSONObject.parseObject(result);
|
||||
if (!"1".equals(jsonObject.get("code"))) {
|
||||
return AjaxResult.error(jsonObject.get("msg").toString());
|
||||
}
|
||||
if (!jsonObject.containsKey("data") || jsonObject.get("data") == null) {
|
||||
return AjaxResult.success();
|
||||
}
|
||||
return AjaxResult.success("查询成功", jsonObject.getString("data"));
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
@ -10,10 +10,12 @@ import com.xinelu.common.utils.http.HttpService;
|
||||
import com.xinelu.common.utils.spring.SpringUtils;
|
||||
import com.xinelu.familydoctor.applet.pojo.query.DoctorListQuery;
|
||||
import com.xinelu.familydoctor.applet.pojo.query.NearbyOrgQuery;
|
||||
import com.xinelu.familydoctor.applet.pojo.query.PackageQuery;
|
||||
import com.xinelu.familydoctor.applet.pojo.query.TeamListQuery;
|
||||
import com.xinelu.familydoctor.applet.pojo.vo.*;
|
||||
import io.swagger.annotations.Api;
|
||||
import io.swagger.annotations.ApiOperation;
|
||||
import org.apache.commons.lang3.StringUtils;
|
||||
import org.springframework.beans.factory.annotation.Value;
|
||||
import org.springframework.web.bind.annotation.*;
|
||||
|
||||
@ -114,7 +116,7 @@ public class SignInfoController extends BaseController {
|
||||
return R.ok(JSONArray.parseArray(result.getJSONArray("data").toJSONString()).toJavaList(NearOrgVo.class));
|
||||
}
|
||||
|
||||
@ApiOperation(value = "获取区划列表", notes = "山东省: 371400000000 德州市: 371400000000 东营市:370500000000")
|
||||
@ApiOperation(value = "获取区划列表", notes = "山东省: 370000000000 德州市: 371400000000 东营市:370500000000")
|
||||
@GetMapping("/area/list/{pid}")
|
||||
public R<List<AreaListVo>> getPhArea(@PathVariable Long pid, @RequestHeader("region") String region) {
|
||||
String result = (String) httpService.get(SpringUtils.getFdUrl(region) + "/area/ph/list/" + pid, null, String.class);
|
||||
@ -214,4 +216,68 @@ public class SignInfoController extends BaseController {
|
||||
}
|
||||
return R.ok(JSONObject.parseObject(jsonObject.getJSONObject("data").toJSONString(), ProtocolContentVo.class));
|
||||
}
|
||||
|
||||
@ApiOperation(value = "获取居民履约情况")
|
||||
@GetMapping("/getPerformance/{identity}")
|
||||
public R<List<PerformancePackageVo>> getPerformance(@PathVariable String identity, @RequestHeader("region") String region) {
|
||||
String result = (String) httpService.get(SpringUtils.getFdUrl(region) + "/performance/getPerPackage/" + identity + "/0", null, String.class);
|
||||
JSONObject jsonObject = JSONObject.parseObject(result);
|
||||
if ("0".equals(jsonObject.get("code"))) {
|
||||
return R.fail(jsonObject.get("msg").toString());
|
||||
}
|
||||
if (!jsonObject.containsKey("data") || jsonObject.get("data") == null) {
|
||||
return R.ok();
|
||||
}
|
||||
return R.ok(JSONArray.parseArray(jsonObject.getJSONArray("data").toJSONString()).toJavaList(PerformancePackageVo.class));
|
||||
}
|
||||
|
||||
@ApiOperation(value = "获取家医人群")
|
||||
@GetMapping("/getCrowd/{identity}")
|
||||
public R<List<CrowdVo>> getCrowd(@PathVariable String identity, @RequestHeader("region") String region) {
|
||||
String result = (String) httpService.get(SpringUtils.getFdUrl(region) + "/resident/signinfo/getCrowd/" + identity, null, String.class);
|
||||
JSONObject jsonObject = JSONObject.parseObject(result);
|
||||
if ("0".equals(jsonObject.get("code"))) {
|
||||
return R.fail(jsonObject.get("msg").toString());
|
||||
}
|
||||
if (!jsonObject.containsKey("data") || jsonObject.get("data") == null) {
|
||||
return R.ok();
|
||||
}
|
||||
return R.ok(JSONArray.parseArray(jsonObject.getJSONArray("data").toJSONString()).toJavaList(CrowdVo.class));
|
||||
}
|
||||
|
||||
@ApiOperation("根据人群获取服务包")
|
||||
@PostMapping("/getPackageByCrowdNo")
|
||||
public R<List<PackageDetailVo>> getPackageByCrowdNo(@RequestBody PackageQuery query, @RequestHeader("region") String region) {
|
||||
if (query == null) {
|
||||
return R.fail("请求参数不能为空");
|
||||
}
|
||||
if (StringUtils.isBlank(query.getOrgNo())) {
|
||||
return R.fail("机构编号不能为空");
|
||||
}
|
||||
if (query.getCrowdNoList() == null || query.getCrowdNoList().size() == 0) {
|
||||
return R.fail("人群编号不能为空");
|
||||
}
|
||||
JSONObject result = httpService.post(SpringUtils.getFdUrl(region) + "/package/getPackageByCrowdNoList", null, JSONObject.parseObject(JSONObject.toJSONString(query)));
|
||||
if ("0".equals(result.get("code"))) {
|
||||
return R.fail(result.get("msg").toString());
|
||||
}
|
||||
if (result.containsKey("data") && result.get("data") != null) {
|
||||
return R.ok(JSONArray.parseArray(result.getJSONArray("data").toJSONString()).toJavaList(PackageDetailVo.class));
|
||||
}
|
||||
return R.ok();
|
||||
}
|
||||
|
||||
@ApiOperation(value = "获取签约协议")
|
||||
@GetMapping("/getSignProtocol/{cardNo}")
|
||||
public R<SignInfoDataVo> getSignProtocol(@PathVariable String cardNo, @RequestHeader("region") String region) {
|
||||
String result = (String) httpService.get(SpringUtils.getFdUrl(region) + "/resident/signinfo/getSignProtocol/" + cardNo, null, String.class);
|
||||
JSONObject jsonObject = JSONObject.parseObject(result);
|
||||
if ("0".equals(jsonObject.get("code"))) {
|
||||
return R.fail(jsonObject.get("msg").toString());
|
||||
}
|
||||
if (!jsonObject.containsKey("data") || jsonObject.get("data") == null) {
|
||||
return R.ok();
|
||||
}
|
||||
return R.ok(JSONObject.parseObject(jsonObject.getJSONObject("data").toJSONString(), SignInfoDataVo.class));
|
||||
}
|
||||
}
|
||||
|
||||
@ -6,6 +6,7 @@ import com.xinelu.common.core.domain.AjaxResult;
|
||||
import com.xinelu.common.utils.StringUtils;
|
||||
import com.xinelu.common.utils.file.FileUploadUtils;
|
||||
import com.xinelu.common.utils.file.FileUtils;
|
||||
import com.xinelu.common.utils.file.MimeTypeUtils;
|
||||
import com.xinelu.framework.config.ServerConfig;
|
||||
import io.swagger.annotations.Api;
|
||||
import io.swagger.annotations.ApiOperation;
|
||||
@ -19,6 +20,7 @@ import org.springframework.web.bind.annotation.RequestMapping;
|
||||
import org.springframework.web.bind.annotation.RestController;
|
||||
import org.springframework.web.multipart.MultipartFile;
|
||||
|
||||
import javax.annotation.Resource;
|
||||
import javax.servlet.http.HttpServletRequest;
|
||||
import javax.servlet.http.HttpServletResponse;
|
||||
import java.util.ArrayList;
|
||||
@ -37,6 +39,8 @@ public class CommonController {
|
||||
|
||||
@Autowired
|
||||
private ServerConfig serverConfig;
|
||||
@Resource
|
||||
private XinELuConfig xinELuConfig;
|
||||
|
||||
private static final String FILE_DELIMETER = ",";
|
||||
|
||||
@ -147,4 +151,23 @@ public class CommonController {
|
||||
log.error("下载文件失败", e);
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* 通用管理端富文本上传请求(单个)
|
||||
*/
|
||||
@PostMapping("/richTextPictureUrl")
|
||||
public AjaxResult richTextPictureUrl(MultipartFile file) throws Exception {
|
||||
// 上传文件路径
|
||||
String filePath = XinELuConfig.getProfile() + xinELuConfig.getRichTextPictureUrl();
|
||||
// 上传并返回新文件名称
|
||||
String fileName = FileUploadUtils.uploadNurseStationPath(filePath, file, MimeTypeUtils.IMAGE_EXTENSION);
|
||||
//拼接路径
|
||||
String url = serverConfig.getUrl() + fileName;
|
||||
AjaxResult ajax = AjaxResult.success();
|
||||
ajax.put("url", url);
|
||||
ajax.put("fileName", fileName);
|
||||
ajax.put("newFileName", FileUtils.getName(fileName));
|
||||
ajax.put("originalFilename", file.getOriginalFilename());
|
||||
return ajax;
|
||||
}
|
||||
}
|
||||
|
||||
@ -82,6 +82,8 @@ xinelu:
|
||||
left-eye-piture-url: /leftEyePitureUrl
|
||||
#眼底病变筛查右眼图片地址
|
||||
right-eye-piture-url: /rightEyePitureUrl
|
||||
#居民签约申请签字图片地址
|
||||
resident-signature-url: /residentSignatureUrl
|
||||
#阿尔兹海默症结果文件地址
|
||||
alzheimer-file-url: /alzheimerFileUrl
|
||||
|
||||
@ -249,8 +251,8 @@ xss:
|
||||
fd:
|
||||
dy: http://192.168.124.6:8001/fd/mp
|
||||
dz: http://192.168.124.6:8001/fd/mp
|
||||
# 签约附近的机构多少公里内
|
||||
distance: 100.00
|
||||
# 签约附近的机构多少公里内 <=0时不限制
|
||||
distance: 0
|
||||
|
||||
# 腾讯云音视频
|
||||
trtc:
|
||||
|
||||
@ -246,6 +246,11 @@ public class XinELuConfig {
|
||||
*/
|
||||
private String chatRecordFileUrl;
|
||||
|
||||
/**
|
||||
* 居民签约申请签字图片地址
|
||||
*/
|
||||
private String residentSignatureUrl;
|
||||
|
||||
public String getConsultationFileUrl() {
|
||||
return consultationFileUrl;
|
||||
}
|
||||
@ -262,6 +267,14 @@ public class XinELuConfig {
|
||||
this.chatRecordFileUrl = chatRecordFileUrl;
|
||||
}
|
||||
|
||||
public String getResidentSignatureUrl() {
|
||||
return residentSignatureUrl;
|
||||
}
|
||||
|
||||
public void setResidentSignatureUrl(String residentSignatureUrl) {
|
||||
this.residentSignatureUrl = residentSignatureUrl;
|
||||
}
|
||||
|
||||
public String getStationWechatCodeUrl() {
|
||||
return stationWechatCodeUrl;
|
||||
}
|
||||
|
||||
@ -0,0 +1,35 @@
|
||||
package com.xinelu.common.enums;
|
||||
|
||||
import lombok.Getter;
|
||||
|
||||
/**
|
||||
* @Description 支付渠道枚举
|
||||
* @Author 纪寒
|
||||
* @Date 2022-10-18 15:23:01
|
||||
* @Version 1.0
|
||||
*/
|
||||
@Getter
|
||||
public enum OrderChannelEnum {
|
||||
|
||||
/**
|
||||
* 手机App
|
||||
*/
|
||||
MOBILE_APP("MOBILE_APP"),
|
||||
|
||||
/**
|
||||
* 微信小程序
|
||||
*/
|
||||
WECHAT_APPLET("WECHAT_APPLET"),
|
||||
|
||||
/**
|
||||
* 支付宝小程序
|
||||
*/
|
||||
ALI_PAY_APPLE("ALI_PAY_APPLE"),
|
||||
;
|
||||
|
||||
final private String info;
|
||||
|
||||
OrderChannelEnum(String info) {
|
||||
this.info = info;
|
||||
}
|
||||
}
|
||||
@ -0,0 +1,29 @@
|
||||
package com.xinelu.common.enums;
|
||||
|
||||
import lombok.Getter;
|
||||
|
||||
/**
|
||||
* @Description 会员信息来源枚举
|
||||
* @Author 纪寒
|
||||
* @Date 2023-02-24 14:08:25
|
||||
* @Version 1.0
|
||||
*/
|
||||
@Getter
|
||||
public enum PatientSourceEnum {
|
||||
/**
|
||||
* 好友邀请
|
||||
*/
|
||||
FRIEND_INVITATION("FRIEND_INVITATION"),
|
||||
|
||||
/**
|
||||
* 自己搜索注册
|
||||
*/
|
||||
REGISTER_YOURSELF("REGISTER_YOURSELF"),
|
||||
;
|
||||
|
||||
final private String info;
|
||||
|
||||
PatientSourceEnum(String info) {
|
||||
this.info = info;
|
||||
}
|
||||
}
|
||||
@ -1,5 +1,6 @@
|
||||
package com.xinelu.common.enums;
|
||||
|
||||
import com.xinelu.common.exception.ServiceException;
|
||||
import lombok.Getter;
|
||||
|
||||
/**
|
||||
@ -34,6 +35,6 @@ public enum RegionKeyType {
|
||||
return uploadType;
|
||||
}
|
||||
}
|
||||
return null;
|
||||
throw new ServiceException("获取区域配置出错");
|
||||
}
|
||||
}
|
||||
|
||||
@ -1,6 +1,7 @@
|
||||
package com.xinelu.common.utils.spring;
|
||||
|
||||
import com.xinelu.common.enums.RegionKeyType;
|
||||
import com.xinelu.common.exception.ServiceException;
|
||||
import com.xinelu.common.utils.StringUtils;
|
||||
import org.springframework.aop.framework.AopContext;
|
||||
import org.springframework.beans.BeansException;
|
||||
|
||||
@ -0,0 +1,33 @@
|
||||
package com.xinelu.familydoctor.applet.pojo.body;
|
||||
|
||||
import io.swagger.annotations.ApiModel;
|
||||
import io.swagger.annotations.ApiModelProperty;
|
||||
import lombok.Data;
|
||||
|
||||
/**
|
||||
* @Author mengkuiliang
|
||||
* @Description base64文件上传请求类
|
||||
* @Date 2023-10-12 012 11:37
|
||||
* @Param
|
||||
* @return
|
||||
**/
|
||||
@ApiModel("base64文件上传请求类")
|
||||
@Data
|
||||
public class FileUploadBody {
|
||||
|
||||
@ApiModelProperty("文件(base64)")
|
||||
private String file;
|
||||
|
||||
@ApiModelProperty("文件类型编码")
|
||||
private String code;
|
||||
|
||||
@ApiModelProperty("文件名称")
|
||||
private String originalFilename;
|
||||
|
||||
@ApiModelProperty("文件类型")
|
||||
private String contentType;
|
||||
|
||||
@ApiModelProperty("文件后缀")
|
||||
private String suffix;
|
||||
|
||||
}
|
||||
@ -17,7 +17,7 @@ import java.util.List;
|
||||
**/
|
||||
@Data
|
||||
@ApiModel("居民服务申请请求对象")
|
||||
public class ResidentServiceApplyBody {
|
||||
public class ResidentServiceApplyBody extends ResidentServiceFormApplyDto{
|
||||
|
||||
/**
|
||||
* 居民编号
|
||||
@ -94,6 +94,7 @@ public class ResidentServiceApplyBody {
|
||||
/**
|
||||
* 服务项集合
|
||||
*/
|
||||
@ApiModelProperty(value = "服务项集合", hidden = true)
|
||||
List<ResidentServiceFormApplyDto> formList;
|
||||
|
||||
}
|
||||
|
||||
@ -1,10 +1,14 @@
|
||||
package com.xinelu.familydoctor.applet.pojo.body;
|
||||
|
||||
import com.xinelu.familydoctor.applet.pojo.dto.CrowdDto;
|
||||
import com.xinelu.familydoctor.applet.pojo.dto.PackageDto;
|
||||
import com.xinelu.familydoctor.applet.pojo.vo.CrowdVo;
|
||||
import io.swagger.annotations.ApiModel;
|
||||
import io.swagger.annotations.ApiModelProperty;
|
||||
import lombok.Data;
|
||||
|
||||
import java.util.Date;
|
||||
import java.util.List;
|
||||
|
||||
/**
|
||||
* @Author mengkuiliang
|
||||
@ -133,27 +137,39 @@ public class ResidentSignApplyBody {
|
||||
/**
|
||||
* 所属人群编号
|
||||
*/
|
||||
@ApiModelProperty(value = "所属人群编号", required = true)
|
||||
@ApiModelProperty(value = "所属人群编号", hidden = true)
|
||||
private String crowdsNo;
|
||||
|
||||
/**
|
||||
* 所属人群名称
|
||||
*/
|
||||
@ApiModelProperty(value = "所属人群名称", required = true)
|
||||
@ApiModelProperty(value = "所属人群名称", hidden = true)
|
||||
private String crowdsName;
|
||||
|
||||
/**
|
||||
* 人群对象集合
|
||||
*/
|
||||
@ApiModelProperty(value = "人群对象集合", required = true)
|
||||
private List<CrowdDto> crowdList;
|
||||
|
||||
/**
|
||||
* 选择服务包编号
|
||||
*/
|
||||
@ApiModelProperty(value = "选择服务包编号", required = true)
|
||||
@ApiModelProperty(value = "选择服务包编号", hidden = true)
|
||||
private String packagesNo;
|
||||
|
||||
/**
|
||||
* 选择服务包名称
|
||||
*/
|
||||
@ApiModelProperty(value = "选择服务包名称", required = true)
|
||||
@ApiModelProperty(value = "选择服务包名称", hidden = true)
|
||||
private String packagesName;
|
||||
|
||||
/**
|
||||
* 服务包对象集合
|
||||
*/
|
||||
@ApiModelProperty(value = "服务包对象集合", required = true)
|
||||
private List<PackageDto> packageList;
|
||||
|
||||
/**
|
||||
* 签约机构编号
|
||||
*/
|
||||
@ -196,6 +212,9 @@ public class ResidentSignApplyBody {
|
||||
@ApiModelProperty(value = "签约时间", required = true)
|
||||
private Date signTime;
|
||||
|
||||
@ApiModelProperty("签约年数")
|
||||
private Integer signYears;
|
||||
|
||||
/**
|
||||
* 居民头像照片
|
||||
*/
|
||||
|
||||
@ -0,0 +1,30 @@
|
||||
package com.xinelu.familydoctor.applet.pojo.dto;
|
||||
|
||||
import io.swagger.annotations.ApiModel;
|
||||
import io.swagger.annotations.ApiModelProperty;
|
||||
import lombok.Data;
|
||||
|
||||
/**
|
||||
* @Author mengkuiliang
|
||||
* @Description 人群对象dto
|
||||
* @Date 2023-10-11 011 16:35
|
||||
* @Param
|
||||
* @return
|
||||
**/
|
||||
@ApiModel("人群对象dto")
|
||||
@Data
|
||||
public class CrowdDto {
|
||||
|
||||
/**
|
||||
* 人群编号
|
||||
*/
|
||||
@ApiModelProperty("人群编号")
|
||||
private String crowdNo;
|
||||
|
||||
/**
|
||||
* 人群名称
|
||||
*/
|
||||
@ApiModelProperty("人群名称")
|
||||
private String crowdName;
|
||||
|
||||
}
|
||||
@ -0,0 +1,33 @@
|
||||
package com.xinelu.familydoctor.applet.pojo.dto;
|
||||
|
||||
import io.swagger.annotations.ApiModel;
|
||||
import io.swagger.annotations.ApiModelProperty;
|
||||
import lombok.Data;
|
||||
|
||||
import java.math.BigDecimal;
|
||||
import java.util.Date;
|
||||
|
||||
/**
|
||||
* @Author mengkuiliang
|
||||
* @Description 服务包Dto
|
||||
* @Date 2023-10-11 011 16:37
|
||||
* @Param
|
||||
* @return
|
||||
**/
|
||||
@ApiModel("服务包Dto")
|
||||
@Data
|
||||
public class PackageDto {
|
||||
|
||||
/**
|
||||
* 服务包业务主键
|
||||
*/
|
||||
@ApiModelProperty(value = "服务包业务主键")
|
||||
private String packageNo;
|
||||
|
||||
/**
|
||||
* 服务包名称
|
||||
*/
|
||||
@ApiModelProperty(value = "服务包名称")
|
||||
private String packageName;
|
||||
|
||||
}
|
||||
@ -205,6 +205,9 @@ public class ResidentSignApplyEntity implements Serializable {
|
||||
@ApiModelProperty(value = "签约时间")
|
||||
private Date signTime;
|
||||
|
||||
@ApiModelProperty("签约年数")
|
||||
private Integer signYears;
|
||||
|
||||
/**
|
||||
* 居民头像照片
|
||||
*/
|
||||
|
||||
@ -0,0 +1,32 @@
|
||||
package com.xinelu.familydoctor.applet.pojo.query;
|
||||
|
||||
import io.swagger.annotations.ApiModel;
|
||||
import io.swagger.annotations.ApiModelProperty;
|
||||
import lombok.Data;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
/**
|
||||
* @Author mengkuiliang
|
||||
* @Description 查询服务包对象(根据人群)
|
||||
* @Date 2023-10-11 011 16:15
|
||||
* @Param
|
||||
* @return
|
||||
**/
|
||||
@ApiModel("查询服务包对象(根据人群)")
|
||||
@Data
|
||||
public class PackageQuery {
|
||||
|
||||
/**
|
||||
* 机构编号
|
||||
*/
|
||||
@ApiModelProperty(value = "机构编号", required = true)
|
||||
private String orgNo;
|
||||
|
||||
/**
|
||||
* 人群编号集合
|
||||
*/
|
||||
@ApiModelProperty(value = "人群编号集合", required = true)
|
||||
private List<String> crowdNoList;
|
||||
|
||||
}
|
||||
@ -0,0 +1,104 @@
|
||||
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.List;
|
||||
|
||||
/**
|
||||
* @Author mengkuiliang
|
||||
* @Description 履约明细服务包集合展示类
|
||||
* @Date 2023-10-11 011 9:19
|
||||
* @Param
|
||||
* @return
|
||||
**/
|
||||
@ApiModel("履约明细服务包集合展示类")
|
||||
@Data
|
||||
public class PerformancePackageVo {
|
||||
|
||||
/**
|
||||
* 履约明细业务主键
|
||||
*/
|
||||
@ApiModelProperty(value = "履约明细业务主键")
|
||||
private String performanceDetailNo;
|
||||
|
||||
/**
|
||||
* 服务包明细编号
|
||||
*/
|
||||
@ApiModelProperty("服务包明细编号")
|
||||
private String packageDetailNo;
|
||||
/**
|
||||
* 服务包编号
|
||||
*/
|
||||
@ApiModelProperty("服务包编号")
|
||||
private String packageNo;
|
||||
|
||||
/**
|
||||
* 服务包名称
|
||||
*/
|
||||
@ApiModelProperty("服务包名称")
|
||||
private String packageName;
|
||||
|
||||
/**
|
||||
* 价格(单位:元,#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;
|
||||
|
||||
/**
|
||||
* 服务周期
|
||||
*/
|
||||
@ApiModelProperty(value = "服务周期")
|
||||
private Integer servicePeriod;
|
||||
|
||||
/**
|
||||
* 单位(D:天,W:周,M:月,Y:年)
|
||||
*/
|
||||
@ApiModelProperty(value = "单位(D:天,W:周,M:月,Y:年)")
|
||||
private String unit;
|
||||
|
||||
/**
|
||||
* 是否公共(市级机构才可创建)
|
||||
* */
|
||||
@ApiModelProperty(value = "是否公共(市级机构才可创建)")
|
||||
private Boolean common;
|
||||
|
||||
/**
|
||||
* 服务包类型(0:基本公共卫生服务包 1:家医服务包 2:精细化服务包)
|
||||
*/
|
||||
@ApiModelProperty(value = "服务包类型(0:基本公共卫生服务包 1:家医服务包 2:精细化服务包)")
|
||||
private String packType;
|
||||
|
||||
/**
|
||||
* 服务包类别(0:基础服务包 1:个性化服务包)
|
||||
* */
|
||||
@ApiModelProperty(value = "服务包类别(0:基础服务包 1:个性化服务包)")
|
||||
private String packCategory;
|
||||
|
||||
/**
|
||||
* 服务包内容
|
||||
*/
|
||||
@ApiModelProperty(value = "服务包内容")
|
||||
private String packageContent;
|
||||
|
||||
/**
|
||||
* 服务项集合
|
||||
*/
|
||||
@ApiModelProperty(value = "服务项集合")
|
||||
private List<PerformanceDetailVo> formList;
|
||||
|
||||
}
|
||||
@ -201,6 +201,9 @@ public class ResidentSignApplyVo extends BaseEntity {
|
||||
@JsonFormat(pattern ="yyyy-MM-dd", timezone = "GMT+8")
|
||||
private Date signTime;
|
||||
|
||||
@ApiModelProperty("签约年数")
|
||||
private Integer signYears;
|
||||
|
||||
/**
|
||||
* 居民签字
|
||||
*/
|
||||
|
||||
@ -0,0 +1,64 @@
|
||||
package com.xinelu.familydoctor.applet.pojo.vo;
|
||||
|
||||
import io.swagger.annotations.ApiModelProperty;
|
||||
import lombok.Data;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
/**
|
||||
* @Author mengkuiliang
|
||||
* @Description 签约信息详情类
|
||||
* @Date 2023-10-12 012 15:02
|
||||
* @Param
|
||||
* @return
|
||||
**/
|
||||
@Data
|
||||
public class SignInfoDataVo {
|
||||
|
||||
/** 签约对象 */
|
||||
@ApiModelProperty(value = "签约对象")
|
||||
private SignInfoDetailVo signInfo;
|
||||
|
||||
/** 基础服务包名称 */
|
||||
@ApiModelProperty(value = "基础服务包名称")
|
||||
private String basePackagesName;
|
||||
|
||||
/** 个性化服务包名称 */
|
||||
@ApiModelProperty(value = "个性化服务包名称")
|
||||
private String specialPackagesName;
|
||||
|
||||
/** 个性化服务包内容 */
|
||||
@ApiModelProperty(value = "个性化服务包内容")
|
||||
private List<String> specialPackageContentList;
|
||||
|
||||
/** 是否存在履约记录 */
|
||||
@ApiModelProperty(value = "是否存在履约记录")
|
||||
private Boolean existPerformance;
|
||||
|
||||
/** 协议模版内容对象 */
|
||||
@ApiModelProperty(value = "协议模版内容对象")
|
||||
private ProtocolContentVo protocolContent;
|
||||
/**
|
||||
* 人群分类1:一般人群2:次重点人群3:重点人群9:未分类
|
||||
*/
|
||||
@ApiModelProperty(value = "人群分类1:一般人群2:次重点人群3:重点人群9:未分类")
|
||||
private String category;
|
||||
|
||||
/**
|
||||
* 居民签名照片Base64
|
||||
*/
|
||||
@ApiModelProperty(value = "居民签名照片Base64")
|
||||
private String residentBase64;
|
||||
|
||||
/**
|
||||
* 医生签名照片Base64
|
||||
*/
|
||||
@ApiModelProperty(value = "医生签名照片Base64")
|
||||
private String doctorBase64;
|
||||
|
||||
/**
|
||||
* 机构公章照片Base64
|
||||
*/
|
||||
@ApiModelProperty(value = "机构公章照片Base64")
|
||||
private String orgBase64;
|
||||
}
|
||||
@ -114,4 +114,13 @@ public interface IResidentPatientInfoService {
|
||||
* @return void
|
||||
**/
|
||||
PatientInfo getByCardNo(String cardNo);
|
||||
|
||||
/**
|
||||
* @Author mengkuiliang
|
||||
* @Description 是否已注册
|
||||
* @Date 2023-10-11 011 10:45
|
||||
* @Param [code]
|
||||
* @return java.lang.Object
|
||||
**/
|
||||
PatientInfo isRegistered(String code);
|
||||
}
|
||||
|
||||
@ -104,5 +104,5 @@ public interface IResidentServiceAppletService {
|
||||
* @Param [identity]
|
||||
* @return java.lang.Object
|
||||
**/
|
||||
List<ScreeningProjectVo> getForm(String identity, String region);
|
||||
List<ScreeningProjectVo> getForm(String identity, String projectName, String region);
|
||||
}
|
||||
|
||||
@ -8,6 +8,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.core.domain.AjaxResult;
|
||||
import com.xinelu.common.exception.ServiceException;
|
||||
import com.xinelu.common.utils.bean.BeanUtils;
|
||||
import com.xinelu.common.utils.http.HttpService;
|
||||
@ -168,6 +169,7 @@ public class ResidentPatientInfoServiceImpl implements IResidentPatientInfoServi
|
||||
if(body.getDiseaseList() != null) {
|
||||
patientInfo.setDisease(body.getDiseaseList().stream().collect(Collectors.joining(",")));
|
||||
}
|
||||
patientInfo.setLoginFlag(Long.valueOf(1));
|
||||
updatePatientInfo(patientInfo);
|
||||
// 注册
|
||||
} else {
|
||||
@ -185,6 +187,7 @@ public class ResidentPatientInfoServiceImpl implements IResidentPatientInfoServi
|
||||
entity.setIsChecked((list == null || list.size() == 0) ? "1" : "0");
|
||||
entity.setCreateTime(new Date());
|
||||
entity.setCreateBy(body.getCardNo());
|
||||
entity.setLoginFlag(Long.valueOf(1));
|
||||
residentPatientInfoMapper.insertPatientInfo(entity);
|
||||
} else {
|
||||
if (!StringUtils.isBlank(patientInfo.getOpenid())) {
|
||||
@ -200,6 +203,7 @@ public class ResidentPatientInfoServiceImpl implements IResidentPatientInfoServi
|
||||
patientInfo.setUpdateBy(body.getCardNo());
|
||||
patientInfo.setHeadPictureUrl(body.getHeadPictureUrl());
|
||||
patientInfo.setDelFlag(0);
|
||||
patientInfo.setLoginFlag(Long.valueOf(1));
|
||||
if(body.getDiseaseList() != null) {
|
||||
patientInfo.setDisease(body.getDiseaseList().stream().collect(Collectors.joining(",")));
|
||||
}
|
||||
@ -310,4 +314,16 @@ public class ResidentPatientInfoServiceImpl implements IResidentPatientInfoServi
|
||||
public PatientInfo getByCardNo(String cardNo) {
|
||||
return residentPatientInfoMapper.getByCardNo(cardNo);
|
||||
}
|
||||
|
||||
/**
|
||||
* @Author mengkuiliang
|
||||
* @Description 是否已注册
|
||||
* @Date 2023-10-11 011 10:46
|
||||
* @Param [code]
|
||||
* @return com.xinelu.familydoctor.applet.pojo.entity.PatientInfo
|
||||
**/
|
||||
@Override
|
||||
public PatientInfo isRegistered(String code) {
|
||||
return getCurrentResident(getOpenId(code), null);
|
||||
}
|
||||
}
|
||||
|
||||
@ -77,9 +77,6 @@ public class ResidentServiceApplyServiceImpl implements IResidentServiceAppletSe
|
||||
}
|
||||
}
|
||||
|
||||
List<ResidentServiceApplyEntity> serviceApplyList = new ArrayList<>();
|
||||
for (ResidentServiceFormApplyDto form : body.getFormList()) {
|
||||
if (!StringUtils.isBlank(form.getFormNo())) {
|
||||
entity = new ResidentServiceApplyEntity();
|
||||
BeanUtils.copyProperties(body, entity);
|
||||
if (patientInfo != null) {
|
||||
@ -91,17 +88,7 @@ public class ResidentServiceApplyServiceImpl implements IResidentServiceAppletSe
|
||||
// 审批状态0:待批准 1:已同意 2:已拒绝
|
||||
entity.setApprovalStatus("0");
|
||||
entity.setBookingNo(IdUtils.simpleUUID());
|
||||
entity.setPackageNo(form.getPackageNo());
|
||||
entity.setPackageName(form.getPackageName());
|
||||
entity.setFormNo(form.getFormNo());
|
||||
entity.setFormName(form.getFormName());
|
||||
serviceApplyList.add(entity);
|
||||
}
|
||||
}
|
||||
if (serviceApplyList.size() == 0) {
|
||||
throw new ServiceException("服务项目不能为空");
|
||||
}
|
||||
residentServiceApplyMapper.batchInsert(serviceApplyList);
|
||||
residentServiceApplyMapper.insert(entity);
|
||||
}
|
||||
|
||||
/**
|
||||
@ -258,9 +245,8 @@ public class ResidentServiceApplyServiceImpl implements IResidentServiceAppletSe
|
||||
* @Param [identity]
|
||||
**/
|
||||
@Override
|
||||
public List<ScreeningProjectVo> getForm(String identity, String region) {
|
||||
public List<ScreeningProjectVo> getForm(String identity, String projectName, String region) {
|
||||
List<ScreeningProjectVo> projectList = new ArrayList<>();
|
||||
|
||||
// 获取签约信息
|
||||
String result = (String) httpService.get(SpringUtils.getFdUrl(region) + "/resident/signinfo/detail/" + identity, null, String.class);
|
||||
JSONObject jsonObject = JSONObject.parseObject(result);
|
||||
@ -275,7 +261,7 @@ public class ResidentServiceApplyServiceImpl implements IResidentServiceAppletSe
|
||||
throw new ServiceException("未查询到签约信息!");
|
||||
}
|
||||
// 获取家医个性服务包
|
||||
result = (String) httpService.get(SpringUtils.getFdUrl(region) + "/package/getPackageOfGX/" + identity, null, String.class);
|
||||
result = (String) httpService.get(SpringUtils.getFdUrl(region) + "/package/getPackageOfGX/" + identity + (!StringUtils.isBlank(projectName) ? ("?formName=" + projectName) : "?formName=null"), null, String.class);
|
||||
jsonObject = JSONObject.parseObject(result);
|
||||
if (!"1".equals(jsonObject.get("code"))) {
|
||||
throw new ServiceException(jsonObject.get("msg").toString());
|
||||
@ -312,14 +298,15 @@ public class ResidentServiceApplyServiceImpl implements IResidentServiceAppletSe
|
||||
if (org != null && !StringUtils.isBlank(org.getPhOrgId())) {
|
||||
// 根据机构编码获取筛查机构
|
||||
HospitalInfo Hospital = hospitalInfoService.getHosptalByOrgCode(org.getPhOrgId());
|
||||
if(Hospital != null) {
|
||||
if (Hospital != null) {
|
||||
// 获取筛查项目
|
||||
ScreeningProject query = new ScreeningProject();
|
||||
query.setHospitalId(Hospital.getId());
|
||||
query.setProjectName(projectName);
|
||||
List<ScreeningProject> screeningProjectList = screeningProjectService.findList(query);
|
||||
if(screeningProjectList != null && screeningProjectList.size() > 0) {
|
||||
if (screeningProjectList != null && screeningProjectList.size() > 0) {
|
||||
ScreeningProjectVo sp;
|
||||
for(ScreeningProject project: screeningProjectList) {
|
||||
for (ScreeningProject project : screeningProjectList) {
|
||||
sp = new ScreeningProjectVo();
|
||||
sp.setSourceType("2");
|
||||
sp.setHospitalId(String.valueOf(project.getHospitalId()));
|
||||
|
||||
@ -10,6 +10,8 @@ import com.xinelu.common.utils.uuid.IdUtils;
|
||||
import com.xinelu.familydoctor.applet.mapper.ResidentSignApplyMapper;
|
||||
import com.xinelu.familydoctor.applet.pojo.body.ApprovalBody;
|
||||
import com.xinelu.familydoctor.applet.pojo.body.ResidentSignApplyBody;
|
||||
import com.xinelu.familydoctor.applet.pojo.dto.CrowdDto;
|
||||
import com.xinelu.familydoctor.applet.pojo.dto.PackageDto;
|
||||
import com.xinelu.familydoctor.applet.pojo.entity.PatientInfo;
|
||||
import com.xinelu.familydoctor.applet.pojo.entity.ResidentSignApplyEntity;
|
||||
import com.xinelu.familydoctor.applet.pojo.query.ApplyQuery;
|
||||
@ -25,6 +27,7 @@ import java.util.Date;
|
||||
import java.util.HashMap;
|
||||
import java.util.List;
|
||||
import java.util.Map;
|
||||
import java.util.stream.Collectors;
|
||||
|
||||
/**
|
||||
* @Author mengkuiliang
|
||||
@ -78,6 +81,16 @@ public class ResidentSignApplyServiceImpl implements IResidentSignAppletService
|
||||
// 审批状态0:待批准 1:已同意 2:已拒绝
|
||||
entity.setApprovalStatus("0");
|
||||
entity.setBookingNo(IdUtils.simpleUUID());
|
||||
if(StringUtils.isBlank(entity.getNation())) {
|
||||
entity.setNation("1");
|
||||
}
|
||||
if(entity.getSignYears() == null || entity.getSignYears() <= 0) {
|
||||
entity.setSignYears(1);
|
||||
}
|
||||
entity.setCrowdsNo(body.getCrowdList().stream().map(CrowdDto::getCrowdNo).collect(Collectors.joining(",")));
|
||||
entity.setCrowdsName(body.getCrowdList().stream().map(CrowdDto::getCrowdName).collect(Collectors.joining(",")));
|
||||
entity.setPackagesNo(body.getPackageList().stream().map(PackageDto::getPackageNo).collect(Collectors.joining(",")));
|
||||
entity.setPackagesName(body.getPackageList().stream().map(PackageDto::getPackageName).collect(Collectors.joining(",")));
|
||||
residentSignApplyMapper.insert(entity);
|
||||
}
|
||||
|
||||
@ -189,7 +202,7 @@ public class ResidentSignApplyServiceImpl implements IResidentSignAppletService
|
||||
// 查询未完成的签约申请
|
||||
ResidentSignApplyVo signBookingInfoVo = getSignBookingByIdentity(identity);
|
||||
if (signBookingInfoVo != null) {
|
||||
retMap.put("code", 01);
|
||||
retMap.put("code", "01");
|
||||
retMap.put("info", DateUtils.parseDateToStr("yyyy年MM月dd日", signBookingInfoVo.getSignTime()) + "已在【" + signBookingInfoVo.getOrgName() + "】【" + signBookingInfoVo.getTeamName() + "】【" + signBookingInfoVo.getUserName() + "】申请签约");
|
||||
return retMap;
|
||||
}
|
||||
@ -202,11 +215,11 @@ public class ResidentSignApplyServiceImpl implements IResidentSignAppletService
|
||||
// 已签约
|
||||
if (jsonObject.containsKey("data") && jsonObject.get("data") != null) {
|
||||
SignInfoDetailVo signInfoDetailVo = JSONObject.parseObject(jsonObject.getJSONObject("data").toJSONString(), SignInfoDetailVo.class);
|
||||
retMap.put("code", 02);
|
||||
retMap.put("code", "02");
|
||||
retMap.put("info", DateUtils.parseDateToStr("yyyy年MM月dd日", signInfoDetailVo.getSignTime()) + "已在【" + signInfoDetailVo.getOrgName() + "】【" + signInfoDetailVo.getTeamName() + "】【" + signInfoDetailVo.getUserName() + "】签约");
|
||||
return retMap;
|
||||
} else {
|
||||
retMap.put("code", 0);
|
||||
retMap.put("code", "0");
|
||||
retMap.put("info", "未签约");
|
||||
}
|
||||
return retMap;
|
||||
|
||||
@ -36,6 +36,7 @@
|
||||
<result property="userNo" column="user_no" jdbcType="VARCHAR"/>
|
||||
<result property="userName" column="user_name" jdbcType="VARCHAR"/>
|
||||
<result property="signTime" column="sign_time" jdbcType="TIMESTAMP"/>
|
||||
<result property="signYears" column="sign_years" jdbcType="INTEGER"/>
|
||||
<result property="residentAutographPath" column="resident_autograph_path" jdbcType="VARCHAR"/>
|
||||
<result property="relationshipWithHouseholder" column="relationship_with_householder" jdbcType="VARCHAR"/>
|
||||
<result property="householderName" column="householder_name" jdbcType="VARCHAR"/>
|
||||
@ -61,7 +62,7 @@
|
||||
crowds_name,packages_no,packages_name,
|
||||
org_no,org_name,team_no,
|
||||
team_name,user_no,user_name,
|
||||
sign_time,resident_autograph_path,relationship_with_householder,
|
||||
sign_time,sign_years,resident_autograph_path,relationship_with_householder,
|
||||
householder_name,householder_identity,apply_time,
|
||||
booking_status,cancel_time,approval_status,
|
||||
refuse_reason,approval_time,remark
|
||||
@ -78,7 +79,7 @@
|
||||
p.crowds_name,p.packages_no,p.packages_name,
|
||||
p.org_no,p.org_name,p.team_no,
|
||||
p.team_name,p.user_no,p.user_name,
|
||||
p.sign_time,p.resident_autograph_path,p.relationship_with_householder,
|
||||
p.sign_time,p.sign_years,p.resident_autograph_path,p.relationship_with_householder,
|
||||
p.householder_name,p.householder_identity,p.apply_time,
|
||||
p.booking_status,p.cancel_time,p.approval_status,
|
||||
p.refuse_reason,p.approval_time,p.remark
|
||||
@ -148,6 +149,9 @@
|
||||
</if>
|
||||
<if test="signTime != null">sign_time,
|
||||
</if>
|
||||
<if test="signYears != null">
|
||||
sign_years,
|
||||
</if>
|
||||
<if test="residentAutographPath != null">resident_autograph_path,
|
||||
</if>
|
||||
<if test="residentAvatar != null">resident_avatar,
|
||||
@ -235,6 +239,9 @@
|
||||
</if>
|
||||
<if test="signTime != null">#{signTime},
|
||||
</if>
|
||||
<if test="signYears != null">
|
||||
#{signYears},
|
||||
</if>
|
||||
<if test="residentAutographPath != null">#{residentAutographPath},
|
||||
</if>
|
||||
<if test="residentAvatar != null">#{residentAvatar},
|
||||
|
||||
@ -76,6 +76,9 @@ public class AppletScreeningRecordController extends BaseController {
|
||||
@ApiOperation(value = "预约")
|
||||
@RepeatSubmit(interval = 2000, message = "请求过于频繁")
|
||||
public R<String> save(@RequestBody ScreeningApplyDTO body) {
|
||||
if(org.apache.commons.lang3.StringUtils.isBlank(body.getIdentity())) {
|
||||
return R.fail("居民身份证号不能为空");
|
||||
}
|
||||
try {
|
||||
if(!DateUtils.formatDate(body.getApplyStartTime(), "yyyy-MM-dd").equals(DateUtils.formatDate(body.getApplyEndTime(), "yyyy-MM-dd"))) {
|
||||
return R.fail("预约日期请选择在同一天");
|
||||
|
||||
@ -1,5 +1,6 @@
|
||||
package com.xinelu.applet.controller.nurseapplogin;
|
||||
|
||||
import com.xinelu.applet.dto.appletlogin.AppletUserInfoDTO;
|
||||
import com.xinelu.applet.dto.appletlogin.StationItemInfoDTO;
|
||||
import com.xinelu.applet.service.nurseapplogin.NurseAppLoginService;
|
||||
import com.xinelu.applet.vo.nursepersonapplogin.OrderAndItemVO;
|
||||
@ -7,14 +8,14 @@ import com.xinelu.common.annotation.MobileRequestAuthorization;
|
||||
import com.xinelu.common.core.controller.BaseController;
|
||||
import com.xinelu.common.core.domain.AjaxResult;
|
||||
import com.xinelu.common.core.page.TableDataInfo;
|
||||
import com.xinelu.common.custominterface.Insert;
|
||||
import com.xinelu.common.custominterface.Query;
|
||||
import com.xinelu.common.exception.ServiceException;
|
||||
import com.xinelu.common.utils.regex.RegexUtil;
|
||||
import org.apache.commons.lang3.StringUtils;
|
||||
import org.springframework.validation.BindingResult;
|
||||
import org.springframework.validation.annotation.Validated;
|
||||
import org.springframework.web.bind.annotation.GetMapping;
|
||||
import org.springframework.web.bind.annotation.RequestMapping;
|
||||
import org.springframework.web.bind.annotation.RestController;
|
||||
import org.springframework.web.bind.annotation.*;
|
||||
|
||||
import javax.annotation.Resource;
|
||||
import java.util.List;
|
||||
@ -31,8 +32,6 @@ import java.util.Objects;
|
||||
@RequestMapping("/nurseApp/login")
|
||||
public class NurseAppLoginController extends BaseController {
|
||||
|
||||
@Resource
|
||||
private RegexUtil regexUtil;
|
||||
@Resource
|
||||
private NurseAppLoginService nurseAppLoginService;
|
||||
|
||||
|
||||
@ -15,6 +15,30 @@ import java.util.List;
|
||||
*/
|
||||
public interface NurseAppLoginMapper {
|
||||
|
||||
/**
|
||||
* 根据id查询被护理人疾病
|
||||
*
|
||||
* @param patientId 被护理人id
|
||||
* @return int
|
||||
*/
|
||||
int selectPatientDiseaseInfo(Long patientId);
|
||||
|
||||
/**
|
||||
* 根据id删除被护理人疾病
|
||||
*
|
||||
* @param patientId 被护理人id
|
||||
* @return int
|
||||
*/
|
||||
long deletePatientDiseaseInfo(Long patientId);
|
||||
|
||||
/**
|
||||
* 查询身份证数量
|
||||
*
|
||||
* @param cardNo 身份证号
|
||||
* @return 数量
|
||||
*/
|
||||
int getCardNoCount(String cardNo);
|
||||
|
||||
/**
|
||||
* 个人中心查询
|
||||
*
|
||||
|
||||
@ -1,5 +1,6 @@
|
||||
package com.xinelu.applet.service.nurseapplogin;
|
||||
|
||||
import com.xinelu.applet.dto.appletlogin.AppletUserInfoDTO;
|
||||
import com.xinelu.applet.dto.appletlogin.StationItemInfoDTO;
|
||||
import com.xinelu.applet.vo.nursepersonapplogin.OrderAndItemVO;
|
||||
import com.xinelu.common.core.domain.AjaxResult;
|
||||
|
||||
@ -1,8 +1,11 @@
|
||||
package com.xinelu.applet.service.nurseapplogin.impl;
|
||||
|
||||
import com.xinelu.applet.dto.appletlogin.AppletUserInfoDTO;
|
||||
import com.xinelu.applet.dto.appletlogin.StationItemInfoDTO;
|
||||
import com.xinelu.applet.mapper.appletlogin.AppletLoginMapper;
|
||||
import com.xinelu.applet.mapper.nurseapplogin.NurseAppLoginMapper;
|
||||
import com.xinelu.applet.mapper.patientcenter.PatientCenterMapper;
|
||||
import com.xinelu.applet.service.messagepush.MessagePushService;
|
||||
import com.xinelu.applet.service.nurseapplogin.NurseAppLoginService;
|
||||
import com.xinelu.applet.utils.AppointmentTimeUtil;
|
||||
import com.xinelu.applet.vo.appletlogin.NurserStationItemConsumableVO;
|
||||
@ -10,24 +13,55 @@ import com.xinelu.applet.vo.appletlogin.NurserStationItemInfoVO;
|
||||
import com.xinelu.applet.vo.nurseapplogin.PatientAndDiseaseVO;
|
||||
import com.xinelu.applet.vo.nursepersonapplogin.OrderAndItemVO;
|
||||
import com.xinelu.applet.vo.specialdisease.WeekDaysVO;
|
||||
import com.xinelu.common.config.AppletChatConfig;
|
||||
import com.xinelu.common.config.XinELuConfig;
|
||||
import com.xinelu.common.constant.Constants;
|
||||
import com.xinelu.common.core.domain.AjaxResult;
|
||||
import com.xinelu.common.enums.AppointmentTimeIntervalEnum;
|
||||
import com.xinelu.common.enums.GooodsOrderStatusEnum;
|
||||
import com.xinelu.common.enums.*;
|
||||
import com.xinelu.common.exception.ServiceException;
|
||||
import com.xinelu.common.utils.AgeUtil;
|
||||
import com.xinelu.common.utils.bean.BeanUtils;
|
||||
import com.xinelu.common.utils.codes.GenerateSystemCodeUtil;
|
||||
import com.xinelu.common.utils.regex.RegexUtil;
|
||||
import com.xinelu.manage.domain.coupon.Coupon;
|
||||
import com.xinelu.manage.domain.goodsOrder.GoodsOrder;
|
||||
import com.xinelu.manage.domain.patientcouponreceive.PatientCouponReceive;
|
||||
import com.xinelu.manage.domain.patientdiseaseinfo.PatientDiseaseInfo;
|
||||
import com.xinelu.manage.domain.patientinfo.PatientInfo;
|
||||
import com.xinelu.manage.domain.patientintegralchange.PatientIntegralChange;
|
||||
import com.xinelu.manage.domain.receiveAddressInfo.ReceiveAddressInfo;
|
||||
import com.xinelu.manage.domain.subscribemessagerecord.SubscribeMessageRecord;
|
||||
import com.xinelu.manage.domain.systemsettingsinfo.SystemSettingsInfo;
|
||||
import com.xinelu.manage.mapper.coupon.CouponMapper;
|
||||
import com.xinelu.manage.mapper.patientcouponreceive.PatientCouponReceiveMapper;
|
||||
import com.xinelu.manage.mapper.patientdiseaseinfo.PatientDiseaseInfoMapper;
|
||||
import com.xinelu.manage.mapper.patientinfo.PatientInfoMapper;
|
||||
import com.xinelu.manage.mapper.patientintegralchange.PatientIntegralChangeMapper;
|
||||
import com.xinelu.manage.mapper.receiveAddressInfo.ReceiveAddressInfoMapper;
|
||||
import com.xinelu.manage.mapper.subscribemessagerecord.SubscribeMessageRecordMapper;
|
||||
import com.xinelu.manage.mapper.sysarea.SysAreaMapper;
|
||||
import com.xinelu.manage.mapper.systemsettingsinfo.SystemSettingsInfoMapper;
|
||||
import com.xinelu.manage.vo.patientcouponreceive.PatientCouponReceiveInfoVO;
|
||||
import com.xinelu.manage.vo.patientinfo.PatientInfoVO;
|
||||
import com.xinelu.manage.vo.sysarea.SysAreaVO;
|
||||
import com.xinelu.system.domain.SysConfig;
|
||||
import com.xinelu.system.mapper.SysConfigMapper;
|
||||
import lombok.extern.slf4j.Slf4j;
|
||||
import org.apache.commons.collections4.CollectionUtils;
|
||||
import org.apache.commons.compress.utils.Lists;
|
||||
import org.apache.commons.lang3.BooleanUtils;
|
||||
import org.apache.commons.lang3.StringUtils;
|
||||
import org.springframework.stereotype.Service;
|
||||
import org.springframework.transaction.annotation.Transactional;
|
||||
|
||||
import javax.annotation.Resource;
|
||||
import java.io.File;
|
||||
import java.math.BigDecimal;
|
||||
import java.time.LocalDate;
|
||||
import java.time.LocalDateTime;
|
||||
import java.time.LocalTime;
|
||||
import java.util.*;
|
||||
import java.util.concurrent.atomic.AtomicInteger;
|
||||
import java.util.stream.Collectors;
|
||||
|
||||
/**
|
||||
@ -42,13 +76,13 @@ public class NurseAppLoginServiceImpl implements NurseAppLoginService {
|
||||
@Resource
|
||||
private NurseAppLoginMapper nurseAppLoginMapper;
|
||||
@Resource
|
||||
private SysAreaMapper sysAreaMapper;
|
||||
@Resource
|
||||
private AppletLoginMapper appletLoginMapper;
|
||||
@Resource
|
||||
private SysConfigMapper sysConfigMapper;
|
||||
private SysAreaMapper sysAreaMapper;
|
||||
@Resource
|
||||
private AppointmentTimeUtil appointmentTimeUtil;
|
||||
@Resource
|
||||
private SysConfigMapper sysConfigMapper;
|
||||
|
||||
/**
|
||||
* 查询护理人列表信息
|
||||
|
||||
@ -33,6 +33,35 @@
|
||||
<result property="diseaseName" column="disease_name"/>
|
||||
</resultMap>
|
||||
|
||||
<select id="selectPatientDiseaseInfo" resultType="int">
|
||||
select
|
||||
count(1)
|
||||
from patient_disease_info
|
||||
<where>
|
||||
<if test="patientId != null">
|
||||
patient_id = #{patientId}
|
||||
</if>
|
||||
</where>
|
||||
</select>
|
||||
|
||||
<delete id="deletePatientDiseaseInfo" parameterType="long">
|
||||
delete
|
||||
from patient_disease_info
|
||||
where patient_id = #{patientId}
|
||||
</delete>
|
||||
|
||||
<select id="getCardNoCount" resultType="java.lang.Integer">
|
||||
select
|
||||
count(1)
|
||||
from patient_info
|
||||
<where>
|
||||
del_flag = 0
|
||||
<if test="cardNo != null">
|
||||
and card_no = #{cardNo}
|
||||
</if>
|
||||
</where>
|
||||
</select>
|
||||
|
||||
<select id="getPatientDiseaseByPatientId" resultMap="PatientAndDiseaseVO">
|
||||
SELECT
|
||||
pi.id patientId,
|
||||
|
||||
@ -0,0 +1,91 @@
|
||||
package com.xinelu.manage.controller.orderevaluateinfo;
|
||||
|
||||
import com.xinelu.common.annotation.Log;
|
||||
import com.xinelu.common.core.controller.BaseController;
|
||||
import com.xinelu.common.core.domain.AjaxResult;
|
||||
import com.xinelu.common.core.page.TableDataInfo;
|
||||
import com.xinelu.common.enums.BusinessType;
|
||||
import com.xinelu.common.utils.poi.ExcelUtil;
|
||||
import com.xinelu.manage.domain.orderevaluateinfo.OrderEvaluateInfo;
|
||||
import com.xinelu.manage.service.orderevaluateinfo.IOrderEvaluateInfoService;
|
||||
import org.springframework.security.access.prepost.PreAuthorize;
|
||||
import org.springframework.web.bind.annotation.*;
|
||||
|
||||
import javax.annotation.Resource;
|
||||
import javax.servlet.http.HttpServletResponse;
|
||||
import java.util.List;
|
||||
|
||||
/**
|
||||
* 预约服务订单和商品订单评价信息Controller
|
||||
*
|
||||
* @author xinyilu
|
||||
* @date 2022-11-17
|
||||
*/
|
||||
@RestController
|
||||
@RequestMapping("/system/orderEvaluateInfo")
|
||||
public class OrderEvaluateInfoController extends BaseController {
|
||||
@Resource
|
||||
private IOrderEvaluateInfoService orderEvaluateInfoService;
|
||||
|
||||
/**
|
||||
* 查询预约服务订单和商品订单评价信息列表
|
||||
*/
|
||||
@PreAuthorize("@ss.hasPermi('system:orderEvaluateInfo:list')")
|
||||
@GetMapping("/list")
|
||||
public TableDataInfo list(OrderEvaluateInfo orderEvaluateInfo) {
|
||||
startPage();
|
||||
List<OrderEvaluateInfo> list = orderEvaluateInfoService.selectOrderEvaluateInfoList(orderEvaluateInfo);
|
||||
return getDataTable(list);
|
||||
}
|
||||
|
||||
/**
|
||||
* 导出预约服务订单和商品订单评价信息列表
|
||||
*/
|
||||
@PreAuthorize("@ss.hasPermi('system:orderEvaluateInfo:export')")
|
||||
@Log(title = "预约服务订单和商品订单评价信息", businessType = BusinessType.EXPORT)
|
||||
@PostMapping("/export")
|
||||
public void export(HttpServletResponse response, OrderEvaluateInfo orderEvaluateInfo) {
|
||||
List<OrderEvaluateInfo> list = orderEvaluateInfoService.selectOrderEvaluateInfoList(orderEvaluateInfo);
|
||||
ExcelUtil<OrderEvaluateInfo> util = new ExcelUtil<>(OrderEvaluateInfo.class);
|
||||
util.exportExcel(response, list, "预约服务订单和商品订单评价信息数据");
|
||||
}
|
||||
|
||||
/**
|
||||
* 获取预约服务订单和商品订单评价信息详细信息
|
||||
*/
|
||||
@PreAuthorize("@ss.hasPermi('system:orderEvaluateInfo:query')")
|
||||
@GetMapping(value = "/{id}")
|
||||
public AjaxResult getInfo(@PathVariable("id") Long id) {
|
||||
return AjaxResult.success(orderEvaluateInfoService.selectOrderEvaluateInfoById(id));
|
||||
}
|
||||
|
||||
/**
|
||||
* 新增预约服务订单和商品订单评价信息
|
||||
*/
|
||||
@PreAuthorize("@ss.hasPermi('system:orderEvaluateInfo:add')")
|
||||
@Log(title = "预约服务订单和商品订单评价信息", businessType = BusinessType.INSERT)
|
||||
@PostMapping("add")
|
||||
public AjaxResult add(@RequestBody OrderEvaluateInfo orderEvaluateInfo) {
|
||||
return toAjax(orderEvaluateInfoService.insertOrderEvaluateInfo(orderEvaluateInfo));
|
||||
}
|
||||
|
||||
/**
|
||||
* 修改预约服务订单和商品订单评价信息
|
||||
*/
|
||||
@PreAuthorize("@ss.hasPermi('system:orderEvaluateInfo:edit')")
|
||||
@Log(title = "预约服务订单和商品订单评价信息", businessType = BusinessType.UPDATE)
|
||||
@PostMapping("edit")
|
||||
public AjaxResult edit(@RequestBody OrderEvaluateInfo orderEvaluateInfo) {
|
||||
return toAjax(orderEvaluateInfoService.updateOrderEvaluateInfo(orderEvaluateInfo));
|
||||
}
|
||||
|
||||
/**
|
||||
* 删除预约服务订单和商品订单评价信息
|
||||
*/
|
||||
@PreAuthorize("@ss.hasPermi('system:orderEvaluateInfo:remove')")
|
||||
@Log(title = "预约服务订单和商品订单评价信息", businessType = BusinessType.DELETE)
|
||||
@PostMapping("/{ids}")
|
||||
public AjaxResult remove(@PathVariable Long[] ids) {
|
||||
return toAjax(orderEvaluateInfoService.deleteOrderEvaluateInfoByIds(ids));
|
||||
}
|
||||
}
|
||||
@ -0,0 +1,62 @@
|
||||
package com.xinelu.manage.mapper.orderevaluatepictureinfo;
|
||||
|
||||
import com.xinelu.manage.domain.orderevaluatepictureinfo.OrderEvaluatePictureInfo;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
|
||||
/**
|
||||
* 订单评价图片信息Mapper接口
|
||||
*
|
||||
* @author xinyilu
|
||||
* @date 2022-11-18
|
||||
*/
|
||||
public interface OrderEvaluatePictureInfoMapper {
|
||||
/**
|
||||
* 查询订单评价图片信息
|
||||
*
|
||||
* @param id 订单评价图片信息主键
|
||||
* @return 订单评价图片信息
|
||||
*/
|
||||
OrderEvaluatePictureInfo selectOrderEvaluatePictureInfoById(Long id);
|
||||
|
||||
/**
|
||||
* 查询订单评价图片信息列表
|
||||
*
|
||||
* @param orderEvaluatePictureInfo 订单评价图片信息
|
||||
* @return 订单评价图片信息集合
|
||||
*/
|
||||
List<OrderEvaluatePictureInfo> selectOrderEvaluatePictureInfoList(OrderEvaluatePictureInfo orderEvaluatePictureInfo);
|
||||
|
||||
/**
|
||||
* 新增订单评价图片信息
|
||||
*
|
||||
* @param orderEvaluatePictureInfo 订单评价图片信息
|
||||
* @return 结果
|
||||
*/
|
||||
int insertOrderEvaluatePictureInfo(OrderEvaluatePictureInfo orderEvaluatePictureInfo);
|
||||
|
||||
/**
|
||||
* 修改订单评价图片信息
|
||||
*
|
||||
* @param orderEvaluatePictureInfo 订单评价图片信息
|
||||
* @return 结果
|
||||
*/
|
||||
int updateOrderEvaluatePictureInfo(OrderEvaluatePictureInfo orderEvaluatePictureInfo);
|
||||
|
||||
/**
|
||||
* 删除订单评价图片信息
|
||||
*
|
||||
* @param id 订单评价图片信息主键
|
||||
* @return 结果
|
||||
*/
|
||||
int deleteOrderEvaluatePictureInfoById(Long id);
|
||||
|
||||
/**
|
||||
* 批量删除订单评价图片信息
|
||||
*
|
||||
* @param ids 需要删除的数据主键集合
|
||||
* @return 结果
|
||||
*/
|
||||
int deleteOrderEvaluatePictureInfoByIds(Long[] ids);
|
||||
}
|
||||
@ -0,0 +1,57 @@
|
||||
package com.xinelu.manage.service.orderevaluateinfo;
|
||||
|
||||
|
||||
import com.xinelu.manage.domain.orderevaluateinfo.OrderEvaluateInfo;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
|
||||
/**
|
||||
* 预约服务订单和商品订单评价信息Service接口
|
||||
*
|
||||
* @author xinyilu
|
||||
* @date 2022-11-17
|
||||
*/
|
||||
public interface IOrderEvaluateInfoService {
|
||||
|
||||
/**
|
||||
* 查询预约服务订单和商品订单评价信息
|
||||
*
|
||||
* @param id 预约服务订单和商品订单评价信息主键
|
||||
* @return 预约服务订单和商品订单评价信息
|
||||
*/
|
||||
OrderEvaluateInfo selectOrderEvaluateInfoById(Long id);
|
||||
|
||||
/**
|
||||
* 查询预约服务订单和商品订单评价信息列表
|
||||
*
|
||||
* @param orderEvaluateInfo 预约服务订单和商品订单评价信息
|
||||
* @return 预约服务订单和商品订单评价信息集合
|
||||
*/
|
||||
List<OrderEvaluateInfo> selectOrderEvaluateInfoList(OrderEvaluateInfo orderEvaluateInfo);
|
||||
|
||||
/**
|
||||
* 新增预约服务订单和商品订单评价信息
|
||||
*
|
||||
* @param orderEvaluateInfo 预约服务订单和商品订单评价信息
|
||||
* @return 结果
|
||||
*/
|
||||
int insertOrderEvaluateInfo(OrderEvaluateInfo orderEvaluateInfo);
|
||||
|
||||
/**
|
||||
* 修改预约服务订单和商品订单评价信息
|
||||
*
|
||||
* @param orderEvaluateInfo 预约服务订单和商品订单评价信息
|
||||
* @return 结果
|
||||
*/
|
||||
int updateOrderEvaluateInfo(OrderEvaluateInfo orderEvaluateInfo);
|
||||
|
||||
/**
|
||||
* 批量删除预约服务订单和商品订单评价信息
|
||||
*
|
||||
* @param ids 需要删除的预约服务订单和商品订单评价信息主键集合
|
||||
* @return 结果
|
||||
*/
|
||||
int deleteOrderEvaluateInfoByIds(Long[] ids);
|
||||
|
||||
}
|
||||
@ -0,0 +1,80 @@
|
||||
package com.xinelu.manage.service.orderevaluateinfo.impl;
|
||||
|
||||
import com.xinelu.manage.domain.orderevaluateinfo.OrderEvaluateInfo;
|
||||
import com.xinelu.manage.mapper.orderevaluateinfo.OrderEvaluateInfoMapper;
|
||||
import com.xinelu.manage.service.orderevaluateinfo.IOrderEvaluateInfoService;
|
||||
import org.springframework.stereotype.Service;
|
||||
|
||||
import javax.annotation.Resource;
|
||||
import java.time.LocalDateTime;
|
||||
import java.util.List;
|
||||
|
||||
|
||||
/**
|
||||
* 预约服务订单和商品订单评价信息Service业务层处理
|
||||
*
|
||||
* @author xinyilu
|
||||
* @date 2022-11-17
|
||||
*/
|
||||
@Service
|
||||
public class OrderEvaluateInfoServiceImpl implements IOrderEvaluateInfoService {
|
||||
@Resource
|
||||
private OrderEvaluateInfoMapper orderEvaluateInfoMapper;
|
||||
|
||||
/**
|
||||
* 查询预约服务订单和商品订单评价信息
|
||||
*
|
||||
* @param id 预约服务订单和商品订单评价信息主键
|
||||
* @return 预约服务订单和商品订单评价信息
|
||||
*/
|
||||
@Override
|
||||
public OrderEvaluateInfo selectOrderEvaluateInfoById(Long id) {
|
||||
return orderEvaluateInfoMapper.selectOrderEvaluateInfoById(id, null);
|
||||
}
|
||||
|
||||
/**
|
||||
* 查询预约服务订单和商品订单评价信息列表
|
||||
*
|
||||
* @param orderEvaluateInfo 预约服务订单和商品订单评价信息
|
||||
* @return 预约服务订单和商品订单评价信息
|
||||
*/
|
||||
@Override
|
||||
public List<OrderEvaluateInfo> selectOrderEvaluateInfoList(OrderEvaluateInfo orderEvaluateInfo) {
|
||||
return orderEvaluateInfoMapper.selectOrderEvaluateInfoList(orderEvaluateInfo);
|
||||
}
|
||||
|
||||
/**
|
||||
* 新增预约服务订单和商品订单评价信息
|
||||
*
|
||||
* @param orderEvaluateInfo 预约服务订单和商品订单评价信息
|
||||
* @return 结果
|
||||
*/
|
||||
@Override
|
||||
public int insertOrderEvaluateInfo(OrderEvaluateInfo orderEvaluateInfo) {
|
||||
orderEvaluateInfo.setCreateTime(LocalDateTime.now());
|
||||
return orderEvaluateInfoMapper.insertOrderEvaluateInfo(orderEvaluateInfo);
|
||||
}
|
||||
|
||||
/**
|
||||
* 修改预约服务订单和商品订单评价信息
|
||||
*
|
||||
* @param orderEvaluateInfo 预约服务订单和商品订单评价信息
|
||||
* @return 结果
|
||||
*/
|
||||
@Override
|
||||
public int updateOrderEvaluateInfo(OrderEvaluateInfo orderEvaluateInfo) {
|
||||
orderEvaluateInfo.setUpdateTime(LocalDateTime.now());
|
||||
return orderEvaluateInfoMapper.updateOrderEvaluateInfo(orderEvaluateInfo);
|
||||
}
|
||||
|
||||
/**
|
||||
* 批量删除预约服务订单和商品订单评价信息
|
||||
*
|
||||
* @param ids 需要删除的预约服务订单和商品订单评价信息主键
|
||||
* @return 结果
|
||||
*/
|
||||
@Override
|
||||
public int deleteOrderEvaluateInfoByIds(Long[] ids) {
|
||||
return orderEvaluateInfoMapper.deleteOrderEvaluateInfoByIds(ids);
|
||||
}
|
||||
}
|
||||
@ -0,0 +1,55 @@
|
||||
package com.xinelu.manage.service.orderevaluatepictureinfo;
|
||||
|
||||
|
||||
import com.xinelu.manage.domain.orderevaluatepictureinfo.OrderEvaluatePictureInfo;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
/**
|
||||
* 订单评价图片信息Service接口
|
||||
*
|
||||
* @author xinyilu
|
||||
* @date 2022-11-18
|
||||
*/
|
||||
public interface IOrderEvaluatePictureInfoService {
|
||||
|
||||
/**
|
||||
* 查询订单评价图片信息
|
||||
*
|
||||
* @param id 订单评价图片信息主键
|
||||
* @return 订单评价图片信息
|
||||
*/
|
||||
OrderEvaluatePictureInfo selectOrderEvaluatePictureInfoById(Long id);
|
||||
|
||||
/**
|
||||
* 查询订单评价图片信息列表
|
||||
*
|
||||
* @param orderEvaluatePictureInfo 订单评价图片信息
|
||||
* @return 订单评价图片信息集合
|
||||
*/
|
||||
List<OrderEvaluatePictureInfo> selectOrderEvaluatePictureInfoList(OrderEvaluatePictureInfo orderEvaluatePictureInfo);
|
||||
|
||||
/**
|
||||
* 新增订单评价图片信息
|
||||
*
|
||||
* @param orderEvaluatePictureInfo 订单评价图片信息
|
||||
* @return 结果
|
||||
*/
|
||||
int insertOrderEvaluatePictureInfo(OrderEvaluatePictureInfo orderEvaluatePictureInfo);
|
||||
|
||||
/**
|
||||
* 修改订单评价图片信息
|
||||
*
|
||||
* @param orderEvaluatePictureInfo 订单评价图片信息
|
||||
* @return 结果
|
||||
*/
|
||||
int updateOrderEvaluatePictureInfo(OrderEvaluatePictureInfo orderEvaluatePictureInfo);
|
||||
|
||||
/**
|
||||
* 批量删除订单评价图片信息
|
||||
*
|
||||
* @param ids 需要删除的订单评价图片信息主键集合
|
||||
* @return 结果
|
||||
*/
|
||||
int deleteOrderEvaluatePictureInfoByIds(Long[] ids);
|
||||
}
|
||||
@ -0,0 +1,79 @@
|
||||
package com.xinelu.manage.service.orderevaluatepictureinfo.impl;
|
||||
|
||||
import com.xinelu.manage.domain.orderevaluatepictureinfo.OrderEvaluatePictureInfo;
|
||||
import com.xinelu.manage.mapper.orderevaluatepictureinfo.OrderEvaluatePictureInfoMapper;
|
||||
import com.xinelu.manage.service.orderevaluatepictureinfo.IOrderEvaluatePictureInfoService;
|
||||
import org.springframework.stereotype.Service;
|
||||
|
||||
import javax.annotation.Resource;
|
||||
import java.time.LocalDateTime;
|
||||
import java.util.List;
|
||||
|
||||
/**
|
||||
* 订单评价图片信息Service业务层处理
|
||||
*
|
||||
* @author xinyilu
|
||||
* @date 2022-11-18
|
||||
*/
|
||||
@Service
|
||||
public class OrderEvaluatePictureInfoServiceImpl implements IOrderEvaluatePictureInfoService {
|
||||
@Resource
|
||||
private OrderEvaluatePictureInfoMapper orderEvaluatePictureInfoMapper;
|
||||
|
||||
/**
|
||||
* 查询订单评价图片信息
|
||||
*
|
||||
* @param id 订单评价图片信息主键
|
||||
* @return 订单评价图片信息
|
||||
*/
|
||||
@Override
|
||||
public OrderEvaluatePictureInfo selectOrderEvaluatePictureInfoById(Long id) {
|
||||
return orderEvaluatePictureInfoMapper.selectOrderEvaluatePictureInfoById(id);
|
||||
}
|
||||
|
||||
/**
|
||||
* 查询订单评价图片信息列表
|
||||
*
|
||||
* @param orderEvaluatePictureInfo 订单评价图片信息
|
||||
* @return 订单评价图片信息
|
||||
*/
|
||||
@Override
|
||||
public List<OrderEvaluatePictureInfo> selectOrderEvaluatePictureInfoList(OrderEvaluatePictureInfo orderEvaluatePictureInfo) {
|
||||
return orderEvaluatePictureInfoMapper.selectOrderEvaluatePictureInfoList(orderEvaluatePictureInfo);
|
||||
}
|
||||
|
||||
/**
|
||||
* 新增订单评价图片信息
|
||||
*
|
||||
* @param orderEvaluatePictureInfo 订单评价图片信息
|
||||
* @return 结果
|
||||
*/
|
||||
@Override
|
||||
public int insertOrderEvaluatePictureInfo(OrderEvaluatePictureInfo orderEvaluatePictureInfo) {
|
||||
orderEvaluatePictureInfo.setCreateTime(LocalDateTime.now());
|
||||
return orderEvaluatePictureInfoMapper.insertOrderEvaluatePictureInfo(orderEvaluatePictureInfo);
|
||||
}
|
||||
|
||||
/**
|
||||
* 修改订单评价图片信息
|
||||
*
|
||||
* @param orderEvaluatePictureInfo 订单评价图片信息
|
||||
* @return 结果
|
||||
*/
|
||||
@Override
|
||||
public int updateOrderEvaluatePictureInfo(OrderEvaluatePictureInfo orderEvaluatePictureInfo) {
|
||||
orderEvaluatePictureInfo.setUpdateTime(LocalDateTime.now());
|
||||
return orderEvaluatePictureInfoMapper.updateOrderEvaluatePictureInfo(orderEvaluatePictureInfo);
|
||||
}
|
||||
|
||||
/**
|
||||
* 批量删除订单评价图片信息
|
||||
*
|
||||
* @param ids 需要删除的订单评价图片信息主键
|
||||
* @return 结果
|
||||
*/
|
||||
@Override
|
||||
public int deleteOrderEvaluatePictureInfoByIds(Long[] ids) {
|
||||
return orderEvaluatePictureInfoMapper.deleteOrderEvaluatePictureInfoByIds(ids);
|
||||
}
|
||||
}
|
||||
@ -103,6 +103,9 @@ public class ScreeningRecordServiceImpl implements IScreeningRecordService {
|
||||
if(registerVo == null) {
|
||||
throw new Exception("用户未注册");
|
||||
}
|
||||
if(StringUtils.isBlank(body.getPatientId())) {
|
||||
body.setPatientId(String.valueOf(registerVo.getId()));
|
||||
}
|
||||
// 查询 同一机构的同一筛查项目在同一天是否有预约
|
||||
ScreeningRecordDTO query = new ScreeningRecordDTO();
|
||||
query.setPatientId(body.getPatientId());
|
||||
@ -121,8 +124,12 @@ public class ScreeningRecordServiceImpl implements IScreeningRecordService {
|
||||
recordBody.setScreeningStatus("1");
|
||||
recordBody.setApplyCode(generateCode());
|
||||
recordBody.setScreeningType("1");
|
||||
try {
|
||||
// 预约条码
|
||||
recordBody.setApplyBarcode(generateBarcode(xinELuConfig.getApplyBarcodePitureUrl(), recordBody.getScreeningId(), recordBody.getApplyCode()));
|
||||
} catch (Exception e) {
|
||||
e.printStackTrace();
|
||||
}
|
||||
int flag = screeningRecordMapper.insert(recordBody);
|
||||
if(flag > 0) {
|
||||
// 推送消息
|
||||
|
||||
@ -135,10 +135,9 @@
|
||||
|
||||
<select id="selectNurseStationItemList" parameterType="NurseStationItem"
|
||||
resultType="com.xinelu.manage.vo.nursestationitem.NurseStationItemVO">
|
||||
select nst.* ,ns.nurse_station_name, nci.classify_name, nt.nurse_type_name
|
||||
select nst.* ,ns.nurse_station_name, nci.classify_name
|
||||
from nurse_station_item nst
|
||||
LEFT JOIN nurse_station ns on ns.id=nst.nurse_station_id
|
||||
LEFT JOIN nurse_type nt on nt.id=nst.nurse_type_id
|
||||
LEFT JOIN nurse_classify_info nci ON nci.id = nst.nurse_classify_id
|
||||
<where>
|
||||
<if test="nurseStationId != null ">
|
||||
|
||||
@ -0,0 +1,111 @@
|
||||
<?xml version="1.0" encoding="UTF-8" ?>
|
||||
<!DOCTYPE mapper
|
||||
PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
||||
"http://mybatis.org/dtd/mybatis-3-mapper.dtd">
|
||||
<mapper namespace="com.xinelu.manage.mapper.orderevaluatepictureinfo.OrderEvaluatePictureInfoMapper">
|
||||
|
||||
<resultMap type="OrderEvaluatePictureInfo" id="OrderEvaluatePictureInfoResult">
|
||||
<result property="id" column="id"/>
|
||||
<result property="orderEvaluateId" column="order_evaluate_id"/>
|
||||
<result property="evaluatePictureUrl" column="evaluate_picture_url"/>
|
||||
<result property="createBy" column="create_by"/>
|
||||
<result property="createTime" column="create_time"/>
|
||||
<result property="updateBy" column="update_by"/>
|
||||
<result property="updateTime" column="update_time"/>
|
||||
</resultMap>
|
||||
|
||||
<sql id="selectOrderEvaluatePictureInfoVo">
|
||||
select id, order_evaluate_id, evaluate_picture_url, create_by, create_time, update_by, update_time
|
||||
from order_evaluate_picture_info
|
||||
</sql>
|
||||
|
||||
<select id="selectOrderEvaluatePictureInfoList" parameterType="OrderEvaluatePictureInfo"
|
||||
resultMap="OrderEvaluatePictureInfoResult">
|
||||
<include refid="selectOrderEvaluatePictureInfoVo"/>
|
||||
<where>
|
||||
<if test="orderEvaluateId != null ">
|
||||
and order_evaluate_id = #{orderEvaluateId}
|
||||
</if>
|
||||
<if test="evaluatePictureUrl != null and evaluatePictureUrl != ''">
|
||||
and evaluate_picture_url = #{evaluatePictureUrl}
|
||||
</if>
|
||||
</where>
|
||||
</select>
|
||||
|
||||
<select id="selectOrderEvaluatePictureInfoById" parameterType="Long"
|
||||
resultMap="OrderEvaluatePictureInfoResult">
|
||||
<include refid="selectOrderEvaluatePictureInfoVo"/>
|
||||
where id = #{id}
|
||||
</select>
|
||||
|
||||
<insert id="insertOrderEvaluatePictureInfo" parameterType="OrderEvaluatePictureInfo" useGeneratedKeys="true"
|
||||
keyProperty="id">
|
||||
insert into order_evaluate_picture_info
|
||||
<trim prefix="(" suffix=")" suffixOverrides=",">
|
||||
<if test="orderEvaluateId != null">order_evaluate_id,
|
||||
</if>
|
||||
<if test="evaluatePictureUrl != null">evaluate_picture_url,
|
||||
</if>
|
||||
<if test="createBy != null">create_by,
|
||||
</if>
|
||||
<if test="createTime != null">create_time,
|
||||
</if>
|
||||
<if test="updateBy != null">update_by,
|
||||
</if>
|
||||
<if test="updateTime != null">update_time,
|
||||
</if>
|
||||
</trim>
|
||||
<trim prefix="values (" suffix=")" suffixOverrides=",">
|
||||
<if test="orderEvaluateId != null">#{orderEvaluateId},
|
||||
</if>
|
||||
<if test="evaluatePictureUrl != null">#{evaluatePictureUrl},
|
||||
</if>
|
||||
<if test="createBy != null">#{createBy},
|
||||
</if>
|
||||
<if test="createTime != null">#{createTime},
|
||||
</if>
|
||||
<if test="updateBy != null">#{updateBy},
|
||||
</if>
|
||||
<if test="updateTime != null">#{updateTime},
|
||||
</if>
|
||||
</trim>
|
||||
</insert>
|
||||
|
||||
<update id="updateOrderEvaluatePictureInfo" parameterType="OrderEvaluatePictureInfo">
|
||||
update order_evaluate_picture_info
|
||||
<trim prefix="SET" suffixOverrides=",">
|
||||
<if test="orderEvaluateId != null">order_evaluate_id =
|
||||
#{orderEvaluateId},
|
||||
</if>
|
||||
<if test="evaluatePictureUrl != null">evaluate_picture_url =
|
||||
#{evaluatePictureUrl},
|
||||
</if>
|
||||
<if test="createBy != null">create_by =
|
||||
#{createBy},
|
||||
</if>
|
||||
<if test="createTime != null">create_time =
|
||||
#{createTime},
|
||||
</if>
|
||||
<if test="updateBy != null">update_by =
|
||||
#{updateBy},
|
||||
</if>
|
||||
<if test="updateTime != null">update_time =
|
||||
#{updateTime},
|
||||
</if>
|
||||
</trim>
|
||||
where id = #{id}
|
||||
</update>
|
||||
|
||||
<delete id="deleteOrderEvaluatePictureInfoById" parameterType="Long">
|
||||
delete
|
||||
from order_evaluate_picture_info
|
||||
where id = #{id}
|
||||
</delete>
|
||||
|
||||
<delete id="deleteOrderEvaluatePictureInfoByIds" parameterType="String">
|
||||
delete from order_evaluate_picture_info where id in
|
||||
<foreach item="id" collection="array" open="(" separator="," close=")">
|
||||
#{id}
|
||||
</foreach>
|
||||
</delete>
|
||||
</mapper>
|
||||
Loading…
Reference in New Issue
Block a user