feat(emergency): 新增大屏一人一案移动端接口
根据当前登录用户身份证号,从安眼库 EMP_PERSON_FILE 关联表 查询最新档案详情,供移动端展示一人一案健康数据。
This commit is contained in:
+8
@@ -308,6 +308,14 @@ public class LargeScreenNewController {
|
|||||||
return Result.ok(largeScreenDataService.isLiaisonUser());
|
return Result.ok(largeScreenDataService.isLiaisonUser());
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 一人一案(移动端)
|
||||||
|
*/
|
||||||
|
@GetMapping("onePersonCase")
|
||||||
|
public Result<OnePersonCaseVO> onePersonCase(){
|
||||||
|
return Result.ok(largeScreenDataService.onePersonCase());
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* 或者安眼平台访问token
|
* 或者安眼平台访问token
|
||||||
|
|||||||
+279
@@ -0,0 +1,279 @@
|
|||||||
|
package com.renkang.emergency.largeScreen.entity.vo;
|
||||||
|
|
||||||
|
import io.swagger.v3.oas.annotations.media.Schema;
|
||||||
|
import lombok.Data;
|
||||||
|
|
||||||
|
import java.time.LocalDate;
|
||||||
|
import java.time.Period;
|
||||||
|
import java.time.format.DateTimeFormatter;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 一人一案详情出参
|
||||||
|
* 数据来源:安眼库 AYGC_YWK.EMP_PERSON_FILE 及关联表
|
||||||
|
*/
|
||||||
|
@Data
|
||||||
|
public class OnePersonCaseVO {
|
||||||
|
|
||||||
|
@Schema(title = "ID")
|
||||||
|
private String id;
|
||||||
|
|
||||||
|
@Schema(title = "员工ID")
|
||||||
|
private String empId;
|
||||||
|
|
||||||
|
@Schema(title = "员工姓名")
|
||||||
|
private String name;
|
||||||
|
|
||||||
|
@Schema(title = "年龄")
|
||||||
|
private Integer age;
|
||||||
|
|
||||||
|
@Schema(title = "性别")
|
||||||
|
private String sexCode;
|
||||||
|
|
||||||
|
@Schema(title = "身份证号")
|
||||||
|
private String idNo;
|
||||||
|
|
||||||
|
@Schema(title = "手机号")
|
||||||
|
private String phone;
|
||||||
|
|
||||||
|
@Schema(title = "关爱状态")
|
||||||
|
private String careStatus;
|
||||||
|
|
||||||
|
@Schema(title = "工作单位")
|
||||||
|
private String workUnit ;
|
||||||
|
|
||||||
|
@Schema(title = "单位ID")
|
||||||
|
private String workUnitId;
|
||||||
|
|
||||||
|
@Schema(title = "创建时间")
|
||||||
|
private String createDate;
|
||||||
|
|
||||||
|
@Schema(title = "修改时间")
|
||||||
|
private String updateDate;
|
||||||
|
|
||||||
|
@Schema(title = "数据级别")
|
||||||
|
private Integer dataLevel;
|
||||||
|
|
||||||
|
@Schema(title = "负面清单")
|
||||||
|
private String negativeList;
|
||||||
|
|
||||||
|
@Schema(title = "一人一案")
|
||||||
|
private String caseInfo;
|
||||||
|
|
||||||
|
@Schema(title = "肥胖人员标识(1,是,2-否)")
|
||||||
|
private Integer flagFat;
|
||||||
|
|
||||||
|
@Schema(title = "BMI")
|
||||||
|
private Double bmi;
|
||||||
|
|
||||||
|
@Schema(title = "身高")
|
||||||
|
private Double height;
|
||||||
|
|
||||||
|
@Schema(title = "体重")
|
||||||
|
private Double weight;
|
||||||
|
|
||||||
|
@Schema(title = "体重管理目标")
|
||||||
|
private Double targetWeight;
|
||||||
|
|
||||||
|
@Schema(title = "目标BMI")
|
||||||
|
private Double targetBmi;
|
||||||
|
|
||||||
|
@Schema(title = "目前BMI监测值")
|
||||||
|
private String bmiCurrent;
|
||||||
|
|
||||||
|
@Schema(title = "最新腰围")
|
||||||
|
private String waistNew;
|
||||||
|
|
||||||
|
@Schema(title = "最新体脂率")
|
||||||
|
private String bodyFatPercentNew;
|
||||||
|
|
||||||
|
@Schema(title = "体重风险类型")
|
||||||
|
private String weightRiskType;
|
||||||
|
|
||||||
|
@Schema(title = "高血压(0-否,1-是)")
|
||||||
|
private Integer hypertension;
|
||||||
|
|
||||||
|
@Schema(title = "收缩压均值")
|
||||||
|
private String systolicPressureAvg;
|
||||||
|
|
||||||
|
@Schema(title = "收缩压控制目标")
|
||||||
|
private String systolicPressureTarget;
|
||||||
|
|
||||||
|
@Schema(title = "目前收缩压检测值")
|
||||||
|
private String systolicPressureCurrent;
|
||||||
|
|
||||||
|
@Schema(title = "舒张压平均值")
|
||||||
|
private String diastolicPressureAvg;
|
||||||
|
|
||||||
|
@Schema(title = "舒张压控制目标值")
|
||||||
|
private String diastolicPressureTarget;
|
||||||
|
|
||||||
|
@Schema(title = "舒张压当前检测值")
|
||||||
|
private String diastolicPressureCurrent;
|
||||||
|
|
||||||
|
@Schema(title = "糖尿病标识(0-否,1-是)")
|
||||||
|
private Integer diabetes;
|
||||||
|
|
||||||
|
@Schema(title = "空腹葡萄糖(GLU)")
|
||||||
|
private String glu;
|
||||||
|
|
||||||
|
@Schema(title = "血糖控制目标值")
|
||||||
|
private String bloodSugarTarget;
|
||||||
|
|
||||||
|
@Schema(title = "目前血糖监测值:")
|
||||||
|
private String bloodSugarCurrent;
|
||||||
|
|
||||||
|
@Schema(title = "低密度脂蛋白")
|
||||||
|
private String ldl;
|
||||||
|
|
||||||
|
@Schema(title = "低密度脂蛋白目标控制值")
|
||||||
|
private String ldlTarget;
|
||||||
|
|
||||||
|
@Schema(title = "低密度脂蛋白当前检测值")
|
||||||
|
private String ldlCurrent;
|
||||||
|
|
||||||
|
@Schema(title = "总胆固醇")
|
||||||
|
private String tc;
|
||||||
|
|
||||||
|
@Schema(title = "总胆固醇目标控制值")
|
||||||
|
private String tcTarget;
|
||||||
|
|
||||||
|
@Schema(title = "总胆固醇目前监测值")
|
||||||
|
private String tcCurrent;
|
||||||
|
|
||||||
|
@Schema(title = "甘油三酯")
|
||||||
|
private String tg;
|
||||||
|
|
||||||
|
@Schema(title = "甘油三酯目标控制值")
|
||||||
|
private String tgTarget;
|
||||||
|
|
||||||
|
@Schema(title = "甘油三酯当前监测值")
|
||||||
|
private String tgCurrent;
|
||||||
|
|
||||||
|
@Schema(title = "尿酸")
|
||||||
|
private String uricAcid;
|
||||||
|
|
||||||
|
@Schema(title = "尿酸目标控制值")
|
||||||
|
private String uricAcidTarget;
|
||||||
|
|
||||||
|
@Schema(title = "尿酸当前监测值")
|
||||||
|
private String uricAcidCurrent;
|
||||||
|
|
||||||
|
@Schema(title = "同型半胱氨酸")
|
||||||
|
private String homocysteine;
|
||||||
|
|
||||||
|
@Schema(title = "同型半胱氨酸目标控制值")
|
||||||
|
private String homocysteineTarget;
|
||||||
|
|
||||||
|
@Schema(title = "同型半胱氨酸当前监测值")
|
||||||
|
private String homocysteineCurrent;
|
||||||
|
|
||||||
|
@Schema(title = "血钾")
|
||||||
|
private String bloodK;
|
||||||
|
|
||||||
|
@Schema(title = "冠心病")
|
||||||
|
private String chd;
|
||||||
|
|
||||||
|
@Schema(title = "脑血管")
|
||||||
|
private String cvd;
|
||||||
|
|
||||||
|
@Schema(title = "心房颤动")
|
||||||
|
private String af;
|
||||||
|
|
||||||
|
@Schema(title = "恶性肿瘤")
|
||||||
|
private String ca;
|
||||||
|
|
||||||
|
@Schema(title = "检测指标列表")
|
||||||
|
private String indicatorListStr;
|
||||||
|
|
||||||
|
@Schema(title = "导入指标列表")
|
||||||
|
private String indicatorListStrOrigin;
|
||||||
|
|
||||||
|
@Schema(title = "风险等级")
|
||||||
|
private String riskLevel;
|
||||||
|
|
||||||
|
@Schema(title = "年度")
|
||||||
|
private String year;
|
||||||
|
|
||||||
|
@Schema(title = "筛查项目汇总")
|
||||||
|
private String screeningProjects;
|
||||||
|
|
||||||
|
@Schema(title = "关爱联络员姓名")
|
||||||
|
private String careLiaisonName;
|
||||||
|
|
||||||
|
@Schema(title = "治疗方案")
|
||||||
|
private String treatPlan;
|
||||||
|
|
||||||
|
@Schema(title = "治疗方案反馈")
|
||||||
|
private String treatPlanResponse;
|
||||||
|
|
||||||
|
@Schema(title = "饮食建议")
|
||||||
|
private String dietSuggestion;
|
||||||
|
|
||||||
|
@Schema(title = "饮食建议反馈")
|
||||||
|
private String dietSuggestionResponse;
|
||||||
|
|
||||||
|
@Schema(title = "运动指导")
|
||||||
|
private String sportGuide;
|
||||||
|
|
||||||
|
@Schema(title = "运动指导反馈")
|
||||||
|
private String sportGuideResponse;
|
||||||
|
|
||||||
|
@Schema(title = "日常生活管理")
|
||||||
|
private String lifeManage;
|
||||||
|
|
||||||
|
@Schema(title = "日常生活管理反馈")
|
||||||
|
private String lifeManageResponse;
|
||||||
|
|
||||||
|
@Schema(title = "小屋意见")
|
||||||
|
private String cabinOpinion;
|
||||||
|
|
||||||
|
@Schema(title = "小屋意见时间")
|
||||||
|
private String cabinOpinionTime;
|
||||||
|
|
||||||
|
@Schema(title = "小屋意见员工姓名")
|
||||||
|
private String cabinOpinionUserName;
|
||||||
|
|
||||||
|
@Schema(title = "专家意见")
|
||||||
|
private String expertOpinion;
|
||||||
|
|
||||||
|
@Schema(title = "专家意见时间")
|
||||||
|
private String expertOpinionTime;
|
||||||
|
|
||||||
|
@Schema(title = "专家意见员工姓名")
|
||||||
|
private String expertOpinionUserName;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* BMI 保留一位小数
|
||||||
|
*/
|
||||||
|
public Double getBmi() {
|
||||||
|
if (bmi == null) {
|
||||||
|
return null;
|
||||||
|
}
|
||||||
|
return Math.round(bmi * 10) / 10.0;
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 年龄:优先取库中值,为空时根据身份证号计算
|
||||||
|
*/
|
||||||
|
public Integer getAge() {
|
||||||
|
if (age != null) {
|
||||||
|
return age;
|
||||||
|
}
|
||||||
|
if (idNo == null || idNo.length() != 18) {
|
||||||
|
return null; // 身份证号无效时返回null
|
||||||
|
}
|
||||||
|
try {
|
||||||
|
// 截取出生日期字符串
|
||||||
|
String birthDateStr = idNo.substring(6, 14);
|
||||||
|
DateTimeFormatter formatter = DateTimeFormatter.ofPattern("yyyyMMdd");
|
||||||
|
LocalDate birthDate = LocalDate.parse(birthDateStr, formatter);
|
||||||
|
LocalDate now = LocalDate.now();
|
||||||
|
if (birthDate.isAfter(now)) {
|
||||||
|
return null; // 出生日期在未来,返回null
|
||||||
|
}
|
||||||
|
return Period.between(birthDate, now).getYears();
|
||||||
|
} catch (Exception e) {
|
||||||
|
return null; // 解析异常返回null
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
+10
@@ -2,6 +2,7 @@ package com.renkang.emergency.largeScreen.mapper;
|
|||||||
|
|
||||||
import com.github.yulichang.base.MPJBaseMapper;
|
import com.github.yulichang.base.MPJBaseMapper;
|
||||||
import com.renkang.emergency.entity.LargeScreenData;
|
import com.renkang.emergency.entity.LargeScreenData;
|
||||||
|
import com.renkang.emergency.largeScreen.entity.vo.OnePersonCaseVO;
|
||||||
import org.apache.ibatis.annotations.Param;
|
import org.apache.ibatis.annotations.Param;
|
||||||
import org.apache.ibatis.annotations.Select;
|
import org.apache.ibatis.annotations.Select;
|
||||||
|
|
||||||
@@ -22,4 +23,13 @@ public interface LargeScreenDataMapper extends MPJBaseMapper<LargeScreenData> {
|
|||||||
@Select("SELECT COUNT(1) FROM AYGC_YWK.HYT_RELATION_CARE_NEW WHERE ADMIN_NUM = #{workNo}")
|
@Select("SELECT COUNT(1) FROM AYGC_YWK.HYT_RELATION_CARE_NEW WHERE ADMIN_NUM = #{workNo}")
|
||||||
int countByAdminNum(@Param("workNo") String workNo);
|
int countByAdminNum(@Param("workNo") String workNo);
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 一人一案:根据身份证号查询最新一条档案详情
|
||||||
|
* SQL 见同包 xml/LargeScreenDataMapper.xml
|
||||||
|
*
|
||||||
|
* @param idCard 身份证号
|
||||||
|
* @return 一人一案详情,无数据时返回 null
|
||||||
|
*/
|
||||||
|
OnePersonCaseVO selectOnePersonCase(@Param("idCard") String idCard);
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|||||||
+191
@@ -0,0 +1,191 @@
|
|||||||
|
<?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.renkang.emergency.largeScreen.mapper.LargeScreenDataMapper">
|
||||||
|
|
||||||
|
<!-- 一人一案:根据身份证号取最新一条档案详情 -->
|
||||||
|
<select id="selectOnePersonCase" resultType="com.renkang.emergency.largeScreen.entity.vo.OnePersonCaseVO">
|
||||||
|
SELECT
|
||||||
|
f.ID AS "id",
|
||||||
|
f.EMP_ID AS "empId",
|
||||||
|
b.NAME AS "name",
|
||||||
|
b.ID_NO AS "idNo",
|
||||||
|
b.AGE AS "age",
|
||||||
|
b.PHONE AS "phone",
|
||||||
|
b.IS_HEART_BRAIN_BLOOD_CARE_EMP AS "careStatus",
|
||||||
|
f.DATA_LEVEL AS "dataLevel",
|
||||||
|
f.NEGATIVE_LIST AS "negativeList",
|
||||||
|
f.CASE_INFO AS "caseInfo",
|
||||||
|
f.FLAG_FAT AS "flagFat",
|
||||||
|
f.BMI AS "bmi",
|
||||||
|
f.HEIGHT AS "height",
|
||||||
|
f.WEIGHT AS "weight",
|
||||||
|
f.WEIGHT_TARGET AS "targetWeight",
|
||||||
|
CASE
|
||||||
|
WHEN f.HEIGHT > 0
|
||||||
|
AND REGEXP_LIKE (f.WEIGHT_TARGET, '^[0-9]+(\.[0-9]+)?$') THEN ROUND(
|
||||||
|
TO_NUMBER (f.WEIGHT_TARGET) / POWER(f.HEIGHT / 100.0, 2),
|
||||||
|
2
|
||||||
|
)
|
||||||
|
ELSE NULL
|
||||||
|
END AS "targetBmi",
|
||||||
|
f.HYPERTENSION AS "hypertension",
|
||||||
|
f.SYSTOLIC_PRESSURE_AVG AS "systolicPressureAvg",
|
||||||
|
f.SYSTOLIC_PRESSURE_TARGET AS "systolicPressureTarget",
|
||||||
|
f.DIASTOLIC_PRESSURE_AVG AS "diastolicPressureAvg",
|
||||||
|
f.DIASTOLIC_PRESSURE_TARGET AS "diastolicPressureTarget",
|
||||||
|
f.DIABETES AS "diabetes",
|
||||||
|
f.GLU AS "glu",
|
||||||
|
f.BLOOD_SUGAR_TARGET AS "bloodSugarTarget",
|
||||||
|
f.LDL AS "ldl",
|
||||||
|
f.LDL_TARGET AS "ldlTarget",
|
||||||
|
f.TC AS "tc",
|
||||||
|
f.TC_TARGET AS "tcTarget",
|
||||||
|
f.TG AS "tg",
|
||||||
|
f.TG_TARGET AS "tgTarget",
|
||||||
|
f.URIC_ACID AS "uricAcid",
|
||||||
|
f.URIC_ACID_TARGET AS "uricAcidTarget",
|
||||||
|
f.HOMOCYSTEINE AS "homocysteine",
|
||||||
|
f.HOMOCYSTEINE_TARGET AS "homocysteineTarget",
|
||||||
|
f.BLOOD_K AS "bloodK",
|
||||||
|
f.CHD AS "chd",
|
||||||
|
f.CVD AS "cvd",
|
||||||
|
f.AF AS "af",
|
||||||
|
f.CA AS "ca",
|
||||||
|
f.INDICATOR_LIST_STR AS "indicatorListStr",
|
||||||
|
f.INDICATOR_LIST_STR_ORIGIN AS "indicatorListStrOrigin",
|
||||||
|
f.TREAT_PLAN AS "treatPlan",
|
||||||
|
f.TREAT_PLAN_RESPONSE AS "treatPlanResponse",
|
||||||
|
f.DIET_SUGGESTION AS "dietSuggestion",
|
||||||
|
f.DIET_SUGGESTION_RESPONSE AS "dietSuggestionResponse",
|
||||||
|
f.SPORT_GUIDE AS "sportGuide",
|
||||||
|
f.SPORT_GUIDE_RESPONSE AS "sportGuideResponse",
|
||||||
|
f.LIFE_MANAGE AS "lifeManage",
|
||||||
|
f.LIFE_MANAGE_RESPONSE AS "lifeManageResponse",
|
||||||
|
f.RISK_LEVEL AS "riskLevel",
|
||||||
|
f.YEAR AS "year",
|
||||||
|
w.BMI_NEW AS "bmiCurrent",
|
||||||
|
w.WAIST_NEW AS "waistNew",
|
||||||
|
w.BODY_FAT_PERCENT_NEW AS "bodyFatPercentNew",
|
||||||
|
w.TYPE AS "weightRiskType",
|
||||||
|
ft.PROJECTS AS "screeningProjects",
|
||||||
|
-- 小屋意见
|
||||||
|
(
|
||||||
|
SELECT d.RESPONSE_CONTENT
|
||||||
|
FROM (
|
||||||
|
SELECT
|
||||||
|
RESPONSE_CONTENT,
|
||||||
|
CREATE_DATE,
|
||||||
|
CREATE_BY,
|
||||||
|
ROW_NUMBER() OVER (ORDER BY CREATE_DATE DESC) as rn
|
||||||
|
FROM AYGC_YWK.EMP_PERSON_FILE_DETAIL
|
||||||
|
WHERE EMP_ID = f.EMP_ID
|
||||||
|
AND DEL_FLAG = '0'
|
||||||
|
AND RESPONSE_TYPE = '小屋意见'
|
||||||
|
) d
|
||||||
|
WHERE d.rn = 1
|
||||||
|
) AS "cabinOpinion",
|
||||||
|
-- 小屋意见时间
|
||||||
|
(
|
||||||
|
SELECT d.CREATE_DATE
|
||||||
|
FROM (
|
||||||
|
SELECT
|
||||||
|
RESPONSE_CONTENT,
|
||||||
|
CREATE_DATE,
|
||||||
|
CREATE_BY,
|
||||||
|
ROW_NUMBER() OVER (ORDER BY CREATE_DATE DESC) as rn
|
||||||
|
FROM AYGC_YWK.EMP_PERSON_FILE_DETAIL
|
||||||
|
WHERE EMP_ID = f.EMP_ID
|
||||||
|
AND DEL_FLAG = '0'
|
||||||
|
AND RESPONSE_TYPE = '小屋意见'
|
||||||
|
) d
|
||||||
|
WHERE d.rn = 1
|
||||||
|
) AS "cabinOpinionTime",
|
||||||
|
-- 小屋意见员工姓名
|
||||||
|
(
|
||||||
|
SELECT u.NAME
|
||||||
|
FROM (
|
||||||
|
SELECT
|
||||||
|
CREATE_BY,
|
||||||
|
ROW_NUMBER() OVER (ORDER BY CREATE_DATE DESC) as rn
|
||||||
|
FROM AYGC_YWK.EMP_PERSON_FILE_DETAIL
|
||||||
|
WHERE EMP_ID = f.EMP_ID
|
||||||
|
AND DEL_FLAG = '0'
|
||||||
|
AND RESPONSE_TYPE = '小屋意见'
|
||||||
|
) d
|
||||||
|
LEFT JOIN AYGC_XTK.SYS_USER u ON u.ID = d.CREATE_BY
|
||||||
|
WHERE d.rn = 1
|
||||||
|
) AS "cabinOpinionUserName",
|
||||||
|
-- 专家意见
|
||||||
|
(
|
||||||
|
SELECT d.RESPONSE_CONTENT
|
||||||
|
FROM (
|
||||||
|
SELECT
|
||||||
|
RESPONSE_CONTENT,
|
||||||
|
CREATE_DATE,
|
||||||
|
CREATE_BY,
|
||||||
|
ROW_NUMBER() OVER (ORDER BY CREATE_DATE DESC) as rn
|
||||||
|
FROM AYGC_YWK.EMP_PERSON_FILE_DETAIL
|
||||||
|
WHERE EMP_ID = f.EMP_ID
|
||||||
|
AND DEL_FLAG = '0'
|
||||||
|
AND RESPONSE_TYPE = '专家意见'
|
||||||
|
) d
|
||||||
|
WHERE d.rn = 1
|
||||||
|
) AS "expertOpinion",
|
||||||
|
-- 专家意见时间
|
||||||
|
(
|
||||||
|
SELECT d.CREATE_DATE
|
||||||
|
FROM (
|
||||||
|
SELECT
|
||||||
|
RESPONSE_CONTENT,
|
||||||
|
CREATE_DATE,
|
||||||
|
CREATE_BY,
|
||||||
|
ROW_NUMBER() OVER (ORDER BY CREATE_DATE DESC) as rn
|
||||||
|
FROM AYGC_YWK.EMP_PERSON_FILE_DETAIL
|
||||||
|
WHERE EMP_ID = f.EMP_ID
|
||||||
|
AND DEL_FLAG = '0'
|
||||||
|
AND RESPONSE_TYPE = '专家意见'
|
||||||
|
) d
|
||||||
|
WHERE d.rn = 1
|
||||||
|
) AS "expertOpinionTime",
|
||||||
|
-- 专家意见员工姓名
|
||||||
|
(
|
||||||
|
SELECT u.NAME
|
||||||
|
FROM (
|
||||||
|
SELECT
|
||||||
|
CREATE_BY,
|
||||||
|
ROW_NUMBER() OVER (ORDER BY CREATE_DATE DESC) as rn
|
||||||
|
FROM AYGC_YWK.EMP_PERSON_FILE_DETAIL
|
||||||
|
WHERE EMP_ID = f.EMP_ID
|
||||||
|
AND DEL_FLAG = '0'
|
||||||
|
AND RESPONSE_TYPE = '专家意见'
|
||||||
|
) d
|
||||||
|
LEFT JOIN AYGC_XTK.SYS_USER u ON u.ID = d.CREATE_BY
|
||||||
|
WHERE d.rn = 1
|
||||||
|
) AS "expertOpinionUserName"
|
||||||
|
FROM
|
||||||
|
AYGC_YWK.EMP_PERSON_FILE f
|
||||||
|
LEFT JOIN AYGC_YWK.EMP_BASIC_INFO b ON b.ID = f.EMP_ID AND b.DEL_FLAG = '0'
|
||||||
|
LEFT JOIN AYGC_YWK.WEIGHT_MANAGEMENT w ON w.EMP_ID = f.EMP_ID AND w.DEL_FLAG = '2'
|
||||||
|
AND w.YEAR = f.YEAR
|
||||||
|
LEFT JOIN (
|
||||||
|
SELECT
|
||||||
|
EMP_ID,
|
||||||
|
LISTAGG (PROJECT || ':' || NVL (CHECK_RESULT, ''), ';') WITHIN GROUP (
|
||||||
|
ORDER BY
|
||||||
|
CHECK_DATE DESC
|
||||||
|
) AS PROJECTS
|
||||||
|
FROM
|
||||||
|
AYGC_YWK.EMP_FIVE_THREE
|
||||||
|
WHERE
|
||||||
|
DEL_FLAG = 2
|
||||||
|
GROUP BY
|
||||||
|
EMP_ID
|
||||||
|
) ft ON ft.EMP_ID = f.EMP_ID
|
||||||
|
WHERE
|
||||||
|
f.DEL_FLAG = '0'
|
||||||
|
AND b.ID_NO = #{idCard}
|
||||||
|
ORDER BY f.CREATE_DATE DESC
|
||||||
|
FETCH FIRST 1 ROWS ONLY
|
||||||
|
</select>
|
||||||
|
|
||||||
|
</mapper>
|
||||||
+3
@@ -13,6 +13,7 @@ import com.renkang.emergency.entity.dto.LargeScreenDataValueDTO;
|
|||||||
import com.renkang.emergency.entity.vo.DataDetailVO;
|
import com.renkang.emergency.entity.vo.DataDetailVO;
|
||||||
import com.renkang.emergency.entity.vo.MedicalDataVO;
|
import com.renkang.emergency.entity.vo.MedicalDataVO;
|
||||||
import com.renkang.emergency.largeScreen.entity.dto.TodayEmergencyDTO;
|
import com.renkang.emergency.largeScreen.entity.dto.TodayEmergencyDTO;
|
||||||
|
import com.renkang.emergency.largeScreen.entity.vo.OnePersonCaseVO;
|
||||||
import com.renkang.emergency.largeScreen.entity.vo.TodayEmergencyVO;
|
import com.renkang.emergency.largeScreen.entity.vo.TodayEmergencyVO;
|
||||||
|
|
||||||
import java.util.List;
|
import java.util.List;
|
||||||
@@ -53,6 +54,8 @@ public interface ILargeScreenDataService extends IService<LargeScreenData> {
|
|||||||
|
|
||||||
Boolean isLiaisonUser();
|
Boolean isLiaisonUser();
|
||||||
|
|
||||||
|
OnePersonCaseVO onePersonCase();
|
||||||
|
|
||||||
IPage<AnYanHealthCheckNew> queryAnYanHealthCheckNew(AnYanHealthCheckNewParam param);
|
IPage<AnYanHealthCheckNew> queryAnYanHealthCheckNew(AnYanHealthCheckNewParam param);
|
||||||
|
|
||||||
AnYanEmpHealthCheckNew queryCheckNewByCheckId(String id);
|
AnYanEmpHealthCheckNew queryCheckNewByCheckId(String id);
|
||||||
|
|||||||
+11
@@ -22,6 +22,7 @@ import com.renkang.emergency.entity.vo.DataDetailVO;
|
|||||||
import com.renkang.emergency.entity.vo.MedicalDataVO;
|
import com.renkang.emergency.entity.vo.MedicalDataVO;
|
||||||
import com.renkang.emergency.largeScreen.entity.dto.TodayEmergencyDTO;
|
import com.renkang.emergency.largeScreen.entity.dto.TodayEmergencyDTO;
|
||||||
import com.renkang.emergency.largeScreen.entity.vo.LargeScreenMap;
|
import com.renkang.emergency.largeScreen.entity.vo.LargeScreenMap;
|
||||||
|
import com.renkang.emergency.largeScreen.entity.vo.OnePersonCaseVO;
|
||||||
import com.renkang.emergency.largeScreen.entity.vo.TodayEmergencyVO;
|
import com.renkang.emergency.largeScreen.entity.vo.TodayEmergencyVO;
|
||||||
import com.renkang.emergency.largeScreen.mapper.LargeScreenDataMapper;
|
import com.renkang.emergency.largeScreen.mapper.LargeScreenDataMapper;
|
||||||
import com.renkang.emergency.largeScreen.service.ILargeScreenDataService;
|
import com.renkang.emergency.largeScreen.service.ILargeScreenDataService;
|
||||||
@@ -938,6 +939,16 @@ public class LargeScreenDataServiceImpl extends ServiceImpl<LargeScreenDataMappe
|
|||||||
return baseMapper.countByAdminNum(workNo) > 0;
|
return baseMapper.countByAdminNum(workNo) > 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public OnePersonCaseVO onePersonCase(){
|
||||||
|
LoginUser loginUser = GlobalUtils.getLoginUser();
|
||||||
|
String idCard = loginUser.getIdCard();
|
||||||
|
if (StrUtil.isEmpty(idCard)) {
|
||||||
|
return null;
|
||||||
|
}
|
||||||
|
return baseMapper.selectOnePersonCase(idCard);
|
||||||
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public IPage<AnYanHealthCheckNew> queryAnYanHealthCheckNew(AnYanHealthCheckNewParam param) {
|
public IPage<AnYanHealthCheckNew> queryAnYanHealthCheckNew(AnYanHealthCheckNewParam param) {
|
||||||
return anYanClient.queryAnYanHealthCheckNew(param);
|
return anYanClient.queryAnYanHealthCheckNew(param);
|
||||||
|
|||||||
Reference in New Issue
Block a user