Compare commits
32
Commits
master
...
7fac46f308
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
7fac46f308 | ||
|
|
25e3b27c34 | ||
|
|
42b16f70b9 | ||
|
|
a9d92dd9a3 | ||
|
|
1380c846f5 | ||
|
|
df2b136b3e | ||
|
|
d5cfc9e76f | ||
|
|
d842bb1dbb | ||
|
|
f28b1e755b | ||
|
|
e64091efde | ||
|
|
34adc1a5e2 | ||
|
|
ac42d99bd2 | ||
|
|
e19f3f57b9 | ||
|
|
7c69912296 | ||
|
|
75d0775ca9 | ||
|
|
ec897c0567 | ||
|
|
19addb4469 | ||
|
|
65b15b8dbd | ||
|
|
2b25e0bf99 | ||
|
|
3a43716e9b | ||
|
|
e93fb4de8d | ||
|
|
5a1d6d828b | ||
|
|
c342a77af1 | ||
|
|
3bd73a6eb8 | ||
|
|
58f859bcac | ||
|
|
7e83999711 | ||
|
|
7fb0ac6aa6 | ||
|
|
909c083e51 | ||
|
|
e15aae5a26 | ||
|
|
2804df2af3 | ||
|
|
c91978f42a | ||
|
|
68fd95a017 |
@@ -38,6 +38,7 @@
|
|||||||
<dependency>
|
<dependency>
|
||||||
<groupId>org.jeecgframework.boot</groupId>
|
<groupId>org.jeecgframework.boot</groupId>
|
||||||
<artifactId>jeecg-boot-base-core</artifactId>
|
<artifactId>jeecg-boot-base-core</artifactId>
|
||||||
|
<classifier>xj</classifier>
|
||||||
<scope>provided</scope>
|
<scope>provided</scope>
|
||||||
</dependency>
|
</dependency>
|
||||||
</dependencies>
|
</dependencies>
|
||||||
|
|||||||
@@ -33,6 +33,7 @@
|
|||||||
<dependency>
|
<dependency>
|
||||||
<groupId>org.jeecgframework.boot</groupId>
|
<groupId>org.jeecgframework.boot</groupId>
|
||||||
<artifactId>jeecg-boot-base-core</artifactId>
|
<artifactId>jeecg-boot-base-core</artifactId>
|
||||||
|
<classifier>xj</classifier>
|
||||||
<scope>provided</scope>
|
<scope>provided</scope>
|
||||||
</dependency>
|
</dependency>
|
||||||
</dependencies>
|
</dependencies>
|
||||||
|
|||||||
@@ -13,6 +13,7 @@
|
|||||||
<dependency>
|
<dependency>
|
||||||
<groupId>org.jeecgframework.boot</groupId>
|
<groupId>org.jeecgframework.boot</groupId>
|
||||||
<artifactId>jeecg-boot-base-core</artifactId>
|
<artifactId>jeecg-boot-base-core</artifactId>
|
||||||
|
<classifier>xj</classifier>
|
||||||
</dependency>
|
</dependency>
|
||||||
|
|
||||||
<!-- feign -->
|
<!-- feign -->
|
||||||
|
|||||||
+1
-1
@@ -112,7 +112,7 @@ public class ConNotice implements Serializable {
|
|||||||
* 咨询类型
|
* 咨询类型
|
||||||
*/
|
*/
|
||||||
@Excel(name = "咨询类型", width = 15, dicCode = "notice_type")
|
@Excel(name = "咨询类型", width = 15, dicCode = "notice_type")
|
||||||
@Schema(title = "咨询类型(notice_type 0:图文咨询 1:音视频咨询)")
|
@Schema(title = "咨询类型(notice_type 0:视屏咨询 1:图文频咨询)")
|
||||||
@Dict(dicCode = "notice_type")
|
@Dict(dicCode = "notice_type")
|
||||||
private String noticeType;
|
private String noticeType;
|
||||||
|
|
||||||
|
|||||||
+1
-1
@@ -58,7 +58,7 @@ public class ConDoctorVO {
|
|||||||
private String doctorStatus;
|
private String doctorStatus;
|
||||||
|
|
||||||
@Excel(name = "医生是否开启咨询(z_doct_sta(1:开启 3:关闭))", width = 15)
|
@Excel(name = "医生是否开启咨询(z_doct_sta(1:开启 3:关闭))", width = 15)
|
||||||
@Dict(dicCode = "doc_accept_flag")
|
@Dict(dicCode = "z_doct_sta")
|
||||||
@Schema(title = "医生是否开启咨询(z_doct_sta(1:开启 3:关闭))")
|
@Schema(title = "医生是否开启咨询(z_doct_sta(1:开启 3:关闭))")
|
||||||
private String isAccept;
|
private String isAccept;
|
||||||
|
|
||||||
|
|||||||
+1
-1
@@ -34,5 +34,5 @@ public class ConNoticeVO {
|
|||||||
|
|
||||||
@Dict(dicCode = "notice_type")
|
@Dict(dicCode = "notice_type")
|
||||||
@Schema(title = "咨询类型(notice_type 0:图文咨询 1:音视频咨询)")
|
@Schema(title = "咨询类型(notice_type 0:图文咨询 1:音视频咨询)")
|
||||||
private String type;
|
private String noticeType;
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -13,18 +13,22 @@
|
|||||||
<dependency>
|
<dependency>
|
||||||
<groupId>com.renkang</groupId>
|
<groupId>com.renkang</groupId>
|
||||||
<artifactId>health-consultation-api</artifactId>
|
<artifactId>health-consultation-api</artifactId>
|
||||||
|
<classifier>xj</classifier>
|
||||||
</dependency>
|
</dependency>
|
||||||
<dependency>
|
<dependency>
|
||||||
<groupId>com.renkang</groupId>
|
<groupId>com.renkang</groupId>
|
||||||
<artifactId>health-emergency-api</artifactId>
|
<artifactId>health-emergency-api</artifactId>
|
||||||
|
<classifier>xj</classifier>
|
||||||
</dependency>
|
</dependency>
|
||||||
<dependency>
|
<dependency>
|
||||||
<groupId>com.renkang</groupId>
|
<groupId>com.renkang</groupId>
|
||||||
<artifactId>health-im-api</artifactId>
|
<artifactId>health-im-api</artifactId>
|
||||||
|
<classifier>xj</classifier>
|
||||||
</dependency>
|
</dependency>
|
||||||
<dependency>
|
<dependency>
|
||||||
<groupId>org.jeecgframework.boot</groupId>
|
<groupId>org.jeecgframework.boot</groupId>
|
||||||
<artifactId>jeecg-system-cloud-api</artifactId>
|
<artifactId>jeecg-system-cloud-api</artifactId>
|
||||||
|
<classifier>xj</classifier>
|
||||||
</dependency>
|
</dependency>
|
||||||
|
|
||||||
<dependency>
|
<dependency>
|
||||||
@@ -50,4 +54,21 @@
|
|||||||
</plugin>
|
</plugin>
|
||||||
</plugins>
|
</plugins>
|
||||||
</build>
|
</build>
|
||||||
|
<profiles>
|
||||||
|
<profile>
|
||||||
|
<id>biz-obf</id>
|
||||||
|
<build>
|
||||||
|
<plugins>
|
||||||
|
<plugin>
|
||||||
|
<groupId>com.github.wvengen</groupId>
|
||||||
|
<artifactId>proguard-maven-plugin</artifactId>
|
||||||
|
</plugin>
|
||||||
|
<plugin>
|
||||||
|
<groupId>org.codehaus.mojo</groupId>
|
||||||
|
<artifactId>build-helper-maven-plugin</artifactId>
|
||||||
|
</plugin>
|
||||||
|
</plugins>
|
||||||
|
</build>
|
||||||
|
</profile>
|
||||||
|
</profiles>
|
||||||
</project>
|
</project>
|
||||||
|
|||||||
@@ -0,0 +1,38 @@
|
|||||||
|
-keepattributes *Annotation*, Signature, InnerClasses, EnclosingMethod, Exceptions, MethodParameters
|
||||||
|
-keep @org.springframework.stereotype.Service class *
|
||||||
|
-keep @org.springframework.web.bind.annotation.RestController class *
|
||||||
|
-keep @org.springframework.context.annotation.Configuration class * { *; }
|
||||||
|
-keep @org.springframework.stereotype.Component class *
|
||||||
|
-keep class lombok.** { *; }
|
||||||
|
-keepclassmembers enum * { # 保留枚举结构
|
||||||
|
public static **[] values();
|
||||||
|
public static ** valueOf(java.lang.String);
|
||||||
|
}
|
||||||
|
-keepclassmembers class * implements java.io.Serializable { *; }
|
||||||
|
-keepclassmembers class * {
|
||||||
|
@org.springframework.web.bind.annotation.*Mapping *;
|
||||||
|
}
|
||||||
|
-keepclassmembers class * {
|
||||||
|
private static synthetic java.lang.Object $deserializeLambda$(java.lang.invoke.SerializedLambda);
|
||||||
|
}
|
||||||
|
-keepclassmembers class * {
|
||||||
|
@lombok.Getter *;
|
||||||
|
@lombok.Setter *;
|
||||||
|
}
|
||||||
|
# MyBatis 专用保留规则
|
||||||
|
-keep interface com.renkang.**.mapper.** { *; }
|
||||||
|
-keep class com.renkang.**.entity.** { *; }
|
||||||
|
-keep class com.renkang.**.bean.** { *; }
|
||||||
|
-keep class com.renkang.**.model.** { *; }
|
||||||
|
-keep class com.renkang.**.vo.** { *; }
|
||||||
|
-keepparameternames
|
||||||
|
|
||||||
|
# 关闭优化和压缩(避免框架兼容性问题)
|
||||||
|
-dontshrink # 不删除未使用代码
|
||||||
|
-dontoptimize # 不优化字节码[5,6](@ref)
|
||||||
|
-keepdirectories
|
||||||
|
-dontusemixedcaseclassnames
|
||||||
|
-adaptclassstrings
|
||||||
|
# 混淆选项
|
||||||
|
-useuniqueclassmembernames # 成员名称唯一化
|
||||||
|
-ignorewarnings
|
||||||
+40
-7
@@ -1,21 +1,27 @@
|
|||||||
package com.renkang.consultation.api.service.impl;
|
package com.renkang.consultation.api.service.impl;
|
||||||
|
|
||||||
|
import cn.hutool.core.date.DateUtil;
|
||||||
|
import cn.hutool.core.util.ObjUtil;
|
||||||
import com.alibaba.druid.util.StringUtils;
|
import com.alibaba.druid.util.StringUtils;
|
||||||
|
import com.alibaba.fastjson.JSONArray;
|
||||||
|
import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper;
|
||||||
import com.renkang.consultation.api.service.ConDoctorSchedulingDateApiService;
|
import com.renkang.consultation.api.service.ConDoctorSchedulingDateApiService;
|
||||||
import com.renkang.consultation.entity.ConDoctor;
|
import com.renkang.consultation.entity.ConDoctor;
|
||||||
import com.renkang.consultation.entity.ConDoctorSchedulingDateListDO;
|
import com.renkang.consultation.entity.ConDoctorSchedulingDateListDO;
|
||||||
|
import com.renkang.consultation.entity.ConService;
|
||||||
import com.renkang.consultation.mapper.ConDoctorMapper;
|
import com.renkang.consultation.mapper.ConDoctorMapper;
|
||||||
import com.renkang.consultation.mapper.ConDoctorSchedulingDateMapper;
|
import com.renkang.consultation.mapper.ConDoctorSchedulingDateMapper;
|
||||||
import com.renkang.consultation.mapper.ConServiceMapper;
|
import com.renkang.consultation.mapper.ConServiceMapper;
|
||||||
|
import com.renkang.consultation.service.IConServiceService;
|
||||||
import org.jeecg.common.api.vo.Result;
|
import org.jeecg.common.api.vo.Result;
|
||||||
|
import org.jeecg.common.constant.CommonConstant;
|
||||||
import org.jeecg.common.util.DateUtils;
|
import org.jeecg.common.util.DateUtils;
|
||||||
|
import org.jeecg.common.util.RedisUtil;
|
||||||
import org.springframework.beans.factory.annotation.Autowired;
|
import org.springframework.beans.factory.annotation.Autowired;
|
||||||
import org.springframework.stereotype.Service;
|
import org.springframework.stereotype.Service;
|
||||||
import org.springframework.util.CollectionUtils;
|
import org.springframework.util.CollectionUtils;
|
||||||
|
|
||||||
import java.util.Date;
|
import java.util.*;
|
||||||
import java.util.Iterator;
|
|
||||||
import java.util.List;
|
|
||||||
|
|
||||||
@Service("conDoctorSchedulingDateApiService")
|
@Service("conDoctorSchedulingDateApiService")
|
||||||
public class ConDoctorSchedulingDateApiServiceImpl implements ConDoctorSchedulingDateApiService {
|
public class ConDoctorSchedulingDateApiServiceImpl implements ConDoctorSchedulingDateApiService {
|
||||||
@@ -29,6 +35,9 @@ public class ConDoctorSchedulingDateApiServiceImpl implements ConDoctorSchedulin
|
|||||||
@Autowired
|
@Autowired
|
||||||
private ConServiceMapper conServiceMapper;
|
private ConServiceMapper conServiceMapper;
|
||||||
|
|
||||||
|
@Autowired
|
||||||
|
private RedisUtil redisUtil;
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public Result<List<ConDoctorSchedulingDateListDO>> selectSchedulingDateListByDoctorId(String doctorId) {
|
public Result<List<ConDoctorSchedulingDateListDO>> selectSchedulingDateListByDoctorId(String doctorId) {
|
||||||
|
|
||||||
@@ -39,8 +48,8 @@ public class ConDoctorSchedulingDateApiServiceImpl implements ConDoctorSchedulin
|
|||||||
if (conDoctor == null) {
|
if (conDoctor == null) {
|
||||||
return Result.error("医生不存在");
|
return Result.error("医生不存在");
|
||||||
}
|
}
|
||||||
|
// 为空 或者已经暂停服务 情况下 生成默认排班
|
||||||
if (CollectionUtils.isEmpty(list) || StringUtils.equals(conDoctor.getDoctorStatus(), "3")) {
|
if (CollectionUtils.isEmpty(list) || "3".equals(conDoctor.getDoctorStatus())) {
|
||||||
Date date = new Date();
|
Date date = new Date();
|
||||||
for (int i = 0; i < 7; i++) {
|
for (int i = 0; i < 7; i++) {
|
||||||
int week = DateUtils.dateToWeek(date);
|
int week = DateUtils.dateToWeek(date);
|
||||||
@@ -56,8 +65,32 @@ public class ConDoctorSchedulingDateApiServiceImpl implements ConDoctorSchedulin
|
|||||||
}
|
}
|
||||||
return Result.ok(list);
|
return Result.ok(list);
|
||||||
}
|
}
|
||||||
|
// 查询暂停服务列表
|
||||||
|
ConService conService = conServiceMapper.selectOne(new LambdaQueryWrapper<ConService>()
|
||||||
|
.eq(ConService::getDoctorId, doctorId)
|
||||||
|
.eq(ConService::getStatus, 1)
|
||||||
|
.eq(ConService::getServiceStatus, 0), false);
|
||||||
|
if (ObjUtil.isNotEmpty(conService)) {
|
||||||
|
// 判断暂停时间是否包含排班
|
||||||
|
for (ConDoctorSchedulingDateListDO dateDO : list) {
|
||||||
|
if (DateUtil.isIn(dateDO.getSchedulingDate(),conService.getStartDay(),conService.getEndDay())) {
|
||||||
|
dateDO.setSchedulingNum("0");
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
if ("1".equals(conDoctor.getTfJumpHoliday())){
|
||||||
|
Object o = redisUtil.get(CommonConstant.CONSULT_HOLIDAY_KEY + Calendar.getInstance().get(Calendar.YEAR));
|
||||||
|
List<String> holidayList = new ArrayList<>();
|
||||||
|
if (o instanceof List<?>) {
|
||||||
|
List<?> tempList = (List<?>) o;
|
||||||
|
for (Object item : tempList) {
|
||||||
|
if (item instanceof String) {
|
||||||
|
holidayList.add((String) item);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
// 将list匹配到的数据数量置0
|
||||||
|
}
|
||||||
Iterator<ConDoctorSchedulingDateListDO> iterator = list.iterator();
|
Iterator<ConDoctorSchedulingDateListDO> iterator = list.iterator();
|
||||||
|
|
||||||
Date date = DateUtils.formatDateToAnother(new Date(), "yyyy-MM-dd");
|
Date date = DateUtils.formatDateToAnother(new Date(), "yyyy-MM-dd");
|
||||||
|
|||||||
+20
-30
@@ -1,73 +1,63 @@
|
|||||||
package com.renkang.consultation.api.service.impl;
|
package com.renkang.consultation.api.service.impl;
|
||||||
|
|
||||||
import cn.hutool.core.bean.BeanUtil;
|
import cn.hutool.core.bean.BeanUtil;
|
||||||
|
import cn.hutool.core.util.StrUtil;
|
||||||
import com.baomidou.mybatisplus.core.conditions.update.LambdaUpdateWrapper;
|
import com.baomidou.mybatisplus.core.conditions.update.LambdaUpdateWrapper;
|
||||||
import com.renkang.consultation.api.RedisConstants;
|
|
||||||
import com.renkang.consultation.api.service.ConNoticeApiService;
|
import com.renkang.consultation.api.service.ConNoticeApiService;
|
||||||
import com.renkang.consultation.dto.NoticeOnOrOff;
|
import com.renkang.consultation.dto.NoticeOnOrOff;
|
||||||
import com.renkang.consultation.entity.ConNotice;
|
import com.renkang.consultation.entity.ConNotice;
|
||||||
import com.renkang.consultation.entity.ConNoticeDO;
|
import com.renkang.consultation.entity.ConNoticeDO;
|
||||||
import com.renkang.consultation.mapper.ConNoticeMapper;
|
import com.renkang.consultation.mapper.ConNoticeMapper;
|
||||||
import org.apache.shiro.SecurityUtils;
|
import lombok.RequiredArgsConstructor;
|
||||||
import org.jeecg.common.api.vo.Result;
|
import org.jeecg.common.api.vo.Result;
|
||||||
import org.jeecg.common.constant.CommonConstant;
|
import org.jeecg.common.constant.CommonConstant;
|
||||||
import org.jeecg.common.system.vo.LoginUser;
|
import org.jeecg.global.GlobalUtils;
|
||||||
import org.springframework.beans.factory.annotation.Autowired;
|
import org.jeecg.util.RedisClientUtil;
|
||||||
import org.springframework.data.redis.core.RedisTemplate;
|
import org.jeecg.util.RedisKeyPrefix;
|
||||||
import org.springframework.stereotype.Service;
|
import org.springframework.stereotype.Service;
|
||||||
import org.springframework.transaction.annotation.Transactional;
|
import org.springframework.transaction.annotation.Transactional;
|
||||||
|
|
||||||
@Service("conNoticeApiService")
|
@Service("conNoticeApiService")
|
||||||
|
@RequiredArgsConstructor
|
||||||
public class ConNoticeServiceApiImpl implements ConNoticeApiService {
|
public class ConNoticeServiceApiImpl implements ConNoticeApiService {
|
||||||
|
private final ConNoticeMapper conNoticeMapper;
|
||||||
|
private final String NOTICE_KEY_1 = "consultation:notice:1:";
|
||||||
@Autowired
|
private final String NOTICE_KEY_0 = "consultation:notice:0:";
|
||||||
private ConNoticeMapper conNoticeMapper;
|
private final RedisClientUtil redisClientUtil;
|
||||||
|
|
||||||
@Autowired
|
|
||||||
private RedisTemplate redisTemplate;
|
|
||||||
|
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public Result<ConNoticeDO> selectUserNotice(String type) {
|
public Result<ConNoticeDO> selectUserNotice(String type) {
|
||||||
LoginUser sysUser = (LoginUser) SecurityUtils.getSubject().getPrincipal();
|
String userId = GlobalUtils.getLoginUser().getId();
|
||||||
String userId = sysUser.getId();
|
String keyPrefix = "0".equals(type)? NOTICE_KEY_0 : NOTICE_KEY_1;
|
||||||
|
String flag = redisClientUtil.get(new RedisKeyPrefix(keyPrefix), userId, String.class);
|
||||||
if (redisTemplate.hasKey(RedisConstants.NOTICE_USER_TF.getKey(userId, type))) {
|
if (StrUtil.isNotEmpty(flag)) {
|
||||||
return Result.ok();
|
return Result.ok();
|
||||||
}
|
}
|
||||||
|
|
||||||
ConNotice conNotice = conNoticeMapper.selectNoticeByType(type);
|
ConNotice conNotice = conNoticeMapper.selectNoticeByType(type);
|
||||||
|
|
||||||
if (conNotice != null) {
|
if (conNotice != null) {
|
||||||
return Result.ok(BeanUtil.copyProperties(conNotice, ConNoticeDO.class));
|
return Result.ok(BeanUtil.copyProperties(conNotice, ConNoticeDO.class));
|
||||||
}
|
}
|
||||||
|
|
||||||
return Result.ok();
|
return Result.ok();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public Result<String> chooseToDontShowUp(String id, String notShow) {
|
public Result<String> chooseToDontShowUp(String id, String notShow) {
|
||||||
RedisConstants redisKey = RedisConstants.NOTICE_USER_TF;
|
String userId = GlobalUtils.getLoginUser().getId();
|
||||||
LoginUser sysUser = (LoginUser) SecurityUtils.getSubject().getPrincipal();
|
|
||||||
String userId = sysUser.getId();
|
|
||||||
|
|
||||||
ConNotice conNotice = conNoticeMapper.selectById(id);
|
ConNotice conNotice = conNoticeMapper.selectById(id);
|
||||||
if (conNotice == null) {
|
if (conNotice == null) {
|
||||||
return Result.error("信息不存在");
|
return Result.error("信息不存在");
|
||||||
}
|
}
|
||||||
|
String keyPrefix = "0".equals(conNotice.getNoticeType())? NOTICE_KEY_0 : NOTICE_KEY_1;
|
||||||
redisTemplate.opsForValue().set(redisKey.getKey(userId, conNotice.getType()), "1");
|
//2-不在提醒,1-一个月,0-7天
|
||||||
|
|
||||||
if ("0".equals(notShow)) {
|
if ("0".equals(notShow)) {
|
||||||
redisTemplate.expire(redisKey.getKey(userId, conNotice.getType()), 7, redisKey.getTimeUnit());
|
redisClientUtil.set(new RedisKeyPrefix(604800,keyPrefix), userId,String.valueOf(1));
|
||||||
}
|
}
|
||||||
if ("1".equals(notShow)) {
|
if ("1".equals(notShow)) {
|
||||||
redisTemplate.expire(redisKey.getKey(userId, conNotice.getType()), 30, redisKey.getTimeUnit());
|
redisClientUtil.set(new RedisKeyPrefix(2592000,keyPrefix), userId,String.valueOf(1));
|
||||||
}
|
}
|
||||||
if ("2".equals(notShow)) {
|
if ("2".equals(notShow)) {
|
||||||
redisTemplate.expire(redisKey.getKey(userId, conNotice.getType()), 180, redisKey.getTimeUnit());
|
redisClientUtil.set(new RedisKeyPrefix(-1,keyPrefix), userId,String.valueOf(1));
|
||||||
}
|
}
|
||||||
|
|
||||||
return Result.ok();
|
return Result.ok();
|
||||||
|
|||||||
+9
-4
@@ -1,5 +1,7 @@
|
|||||||
package com.renkang.consultation.api.service.impl;
|
package com.renkang.consultation.api.service.impl;
|
||||||
|
|
||||||
|
import cn.hutool.core.date.DateField;
|
||||||
|
import cn.hutool.core.date.DateUtil;
|
||||||
import cn.hutool.core.util.ObjectUtil;
|
import cn.hutool.core.util.ObjectUtil;
|
||||||
import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper;
|
import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper;
|
||||||
import com.renkang.consultation.api.service.ConServiceApiService;
|
import com.renkang.consultation.api.service.ConServiceApiService;
|
||||||
@@ -39,7 +41,10 @@ public class ConServiceApiServiceImpl implements ConServiceApiService {
|
|||||||
throw new RuntimeException("请确认事件后重新提交");
|
throw new RuntimeException("请确认事件后重新提交");
|
||||||
}
|
}
|
||||||
|
|
||||||
|
data.setEndDay(DateUtil.endOfDay(data.getEndDay()).offset(DateField.MILLISECOND,-999));
|
||||||
|
|
||||||
LoginUser loginUser = GlobalUtils.getLoginUser();
|
LoginUser loginUser = GlobalUtils.getLoginUser();
|
||||||
|
loginUser.setId("1940949295719591937");
|
||||||
List<ConService> list = getConService(loginUser);
|
List<ConService> list = getConService(loginUser);
|
||||||
// if (CollectionUtils.isEmpty(list)) {
|
// if (CollectionUtils.isEmpty(list)) {
|
||||||
// conServiceMapper.insert(data);
|
// conServiceMapper.insert(data);
|
||||||
@@ -47,19 +52,19 @@ public class ConServiceApiServiceImpl implements ConServiceApiService {
|
|||||||
// }
|
// }
|
||||||
|
|
||||||
for (ConService service : list) {
|
for (ConService service : list) {
|
||||||
boolean startContain = DateUtils.contain(service.getStartDay(), service.getEndDay(), data.getStartDay());
|
boolean startContain = DateUtils.contain(service.getStartDay(), DateUtil.endOfDay(service.getEndDay()), data.getStartDay());
|
||||||
boolean endContain = DateUtils.contain(service.getStartDay(), service.getEndDay(), data.getEndDay());
|
boolean endContain = DateUtils.contain(service.getStartDay(), DateUtil.endOfDay(service.getEndDay()), data.getEndDay());
|
||||||
if (startContain || endContain) {
|
if (startContain || endContain) {
|
||||||
throw new RuntimeException("时间有重叠,请检查已有停诊时间");
|
throw new RuntimeException("时间有重叠,请检查已有停诊时间");
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
data.setDoctorName(loginUser.getRealname());
|
||||||
data.setDoctorId(loginUser.getId());
|
data.setDoctorId(loginUser.getId());
|
||||||
// 新增
|
// 新增
|
||||||
conServiceMapper.insert(data);
|
conServiceMapper.insert(data);
|
||||||
|
|
||||||
Date startDate = data.getStartDay();
|
Date startDate = data.getStartDay();
|
||||||
Date endDate = data.getEndDay();
|
Date endDate = DateUtil.endOfDay(data.getEndDay());
|
||||||
Date date = com.renkang.consultation.util.DateUtils.changeDate(new Date());
|
Date date = com.renkang.consultation.util.DateUtils.changeDate(new Date());
|
||||||
if (date.getTime() >= startDate.getTime() && date.getTime() <= endDate.getTime()) {
|
if (date.getTime() >= startDate.getTime() && date.getTime() <= endDate.getTime()) {
|
||||||
conDoctorMapper.changeDoctorStatus(loginUser.getId());
|
conDoctorMapper.changeDoctorStatus(loginUser.getId());
|
||||||
|
|||||||
+10
-11
@@ -36,7 +36,6 @@ import org.jeecg.common.system.vo.LoginUser;
|
|||||||
import org.jeecg.common.system.vo.LoginUserNew;
|
import org.jeecg.common.system.vo.LoginUserNew;
|
||||||
import org.jeecg.common.util.AgeCalculateUtil;
|
import org.jeecg.common.util.AgeCalculateUtil;
|
||||||
import org.jeecg.config.shiro.ClientSignThreadLocal;
|
import org.jeecg.config.shiro.ClientSignThreadLocal;
|
||||||
import org.jeecg.global.GlobalUtils;
|
|
||||||
import org.springframework.beans.BeanUtils;
|
import org.springframework.beans.BeanUtils;
|
||||||
import org.springframework.beans.factory.annotation.Autowired;
|
import org.springframework.beans.factory.annotation.Autowired;
|
||||||
import org.springframework.beans.factory.annotation.Value;
|
import org.springframework.beans.factory.annotation.Value;
|
||||||
@@ -394,7 +393,7 @@ public class ConSessionApiServiceImpl implements ConSessionApiService {
|
|||||||
ClientSignThreadLocal.setClientSign(CommonConstant.QUARRY);
|
ClientSignThreadLocal.setClientSign(CommonConstant.QUARRY);
|
||||||
}
|
}
|
||||||
//如果是用户咨询全科医生 并且是青海
|
//如果是用户咨询全科医生 并且是青海
|
||||||
if (StrUtil.equals(conSession.getSessionType(), "2") && StrUtil.equals(conSession.getTfQh(), "1")) {
|
if (StrUtil.equals(conSession.getSessionType(), "2")) {
|
||||||
//如果用户发验 并且小助手在休息时间 那么自动发送消息
|
//如果用户发验 并且小助手在休息时间 那么自动发送消息
|
||||||
this.helperSendMessage(conSession.getImId(), fromAccount, conSession.getToAccount());
|
this.helperSendMessage(conSession.getImId(), fromAccount, conSession.getToAccount());
|
||||||
}
|
}
|
||||||
@@ -1868,12 +1867,12 @@ public class ConSessionApiServiceImpl implements ConSessionApiService {
|
|||||||
@Override
|
@Override
|
||||||
public Result<List<ConSessionDO>> selectSessionListByDoctorIdUnit(int pageNo, int pageSize) {
|
public Result<List<ConSessionDO>> selectSessionListByDoctorIdUnit(int pageNo, int pageSize) {
|
||||||
|
|
||||||
if (!GlobalUtils.isQh()) {
|
/* if (!GlobalUtils.isQh()) {
|
||||||
return new Result(403, "权限错误");
|
return new Result(403, "权限错误");
|
||||||
}
|
}*/
|
||||||
|
|
||||||
LoginUser sysUser = (LoginUser) SecurityUtils.getSubject().getPrincipal();
|
LoginUser sysUser = (LoginUser) SecurityUtils.getSubject().getPrincipal();
|
||||||
com.baomidou.mybatisplus.extension.plugins.pagination.Page<ConSessionDO> page = new com.baomidou.mybatisplus.extension.plugins.pagination.Page<ConSessionDO>(pageNo, pageSize);
|
Page<ConSessionDO> page = new Page<ConSessionDO>(pageNo, pageSize);
|
||||||
List<ConSessionDO> list = conSessionMapper.selectSessionListByUserIdHelperAnother(page, null, null, sysUser.getId());
|
List<ConSessionDO> list = conSessionMapper.selectSessionListByUserIdHelperAnother(page, null, null, sysUser.getId());
|
||||||
|
|
||||||
|
|
||||||
@@ -1886,9 +1885,9 @@ public class ConSessionApiServiceImpl implements ConSessionApiService {
|
|||||||
@Override
|
@Override
|
||||||
public Result<List<ConSessionDO>> selectSessionListByDoctorIdHelper(int pageNo, int pageSize) {
|
public Result<List<ConSessionDO>> selectSessionListByDoctorIdHelper(int pageNo, int pageSize) {
|
||||||
|
|
||||||
if (!GlobalUtils.isQh()) {
|
/* if (!GlobalUtils.isQh()) {
|
||||||
return new Result(403, "权限错误");
|
return new Result(403, "权限错误");
|
||||||
}
|
}*/
|
||||||
|
|
||||||
LoginUser sysUser = (LoginUser) SecurityUtils.getSubject().getPrincipal();
|
LoginUser sysUser = (LoginUser) SecurityUtils.getSubject().getPrincipal();
|
||||||
com.baomidou.mybatisplus.extension.plugins.pagination.Page<ConSessionDO> page = new com.baomidou.mybatisplus.extension.plugins.pagination.Page<ConSessionDO>(pageNo, pageSize);
|
com.baomidou.mybatisplus.extension.plugins.pagination.Page<ConSessionDO> page = new com.baomidou.mybatisplus.extension.plugins.pagination.Page<ConSessionDO>(pageNo, pageSize);
|
||||||
@@ -1912,9 +1911,9 @@ public class ConSessionApiServiceImpl implements ConSessionApiService {
|
|||||||
|
|
||||||
@Override
|
@Override
|
||||||
public Result<Integer> selectDoctorCardExpireTime(Long sendTime) {
|
public Result<Integer> selectDoctorCardExpireTime(Long sendTime) {
|
||||||
if (!GlobalUtils.isQh()) {
|
/* if (!GlobalUtils.isQh()) {
|
||||||
return new Result(403, "权限错误");
|
return new Result(403, "权限错误");
|
||||||
}
|
}*/
|
||||||
|
|
||||||
if (sendTime == null) {
|
if (sendTime == null) {
|
||||||
return Result.error("时间错误");
|
return Result.error("时间错误");
|
||||||
@@ -1950,9 +1949,9 @@ public class ConSessionApiServiceImpl implements ConSessionApiService {
|
|||||||
|
|
||||||
@Override
|
@Override
|
||||||
public Result<Map<String, Object>> insertUserAndHelperSessionNew() {
|
public Result<Map<String, Object>> insertUserAndHelperSessionNew() {
|
||||||
if (!GlobalUtils.isQh()) {
|
/* if (!GlobalUtils.isQh()) {
|
||||||
return new Result(403, "权限错误");
|
return new Result(403, "权限错误");
|
||||||
}
|
}*/
|
||||||
LoginUser sysUser = (LoginUser) SecurityUtils.getSubject().getPrincipal();
|
LoginUser sysUser = (LoginUser) SecurityUtils.getSubject().getPrincipal();
|
||||||
|
|
||||||
ConSession conSessionOnly = conSessionMapper.selectSessioningByProfessorIdNew(sysUser.getId(), "2");
|
ConSession conSessionOnly = conSessionMapper.selectSessioningByProfessorIdNew(sysUser.getId(), "2");
|
||||||
|
|||||||
+2
-2
@@ -4,11 +4,11 @@ import com.renkang.consultation.api.storge.redis.ConHealthInfoRedisTunnel;
|
|||||||
import com.renkang.consultation.entity.ConHealthInfo;
|
import com.renkang.consultation.entity.ConHealthInfo;
|
||||||
import com.renkang.consultation.mapper.ConHealthInfoMapper;
|
import com.renkang.consultation.mapper.ConHealthInfoMapper;
|
||||||
import org.springframework.beans.factory.annotation.Autowired;
|
import org.springframework.beans.factory.annotation.Autowired;
|
||||||
import org.springframework.stereotype.Repository;
|
import org.springframework.stereotype.Component;
|
||||||
|
|
||||||
import java.util.List;
|
import java.util.List;
|
||||||
|
|
||||||
@Repository
|
@Component
|
||||||
public class ComposeConHealthInfo {
|
public class ComposeConHealthInfo {
|
||||||
|
|
||||||
|
|
||||||
|
|||||||
+2
-2
@@ -5,9 +5,9 @@ import com.renkang.consultation.entity.ConKnowledge;
|
|||||||
import com.renkang.consultation.mapper.ConKnowledgeMapper;
|
import com.renkang.consultation.mapper.ConKnowledgeMapper;
|
||||||
import org.springframework.beans.factory.annotation.Autowired;
|
import org.springframework.beans.factory.annotation.Autowired;
|
||||||
import org.springframework.data.redis.core.RedisTemplate;
|
import org.springframework.data.redis.core.RedisTemplate;
|
||||||
import org.springframework.stereotype.Repository;
|
import org.springframework.stereotype.Component;
|
||||||
|
|
||||||
@Repository
|
@Component
|
||||||
public class ComposeConKnowledge {
|
public class ComposeConKnowledge {
|
||||||
|
|
||||||
|
|
||||||
|
|||||||
+2
-2
@@ -4,11 +4,11 @@ import com.renkang.consultation.api.storge.db.ConKnowledgeCategoryDbTunnel;
|
|||||||
import com.renkang.consultation.api.storge.redis.ConKnowledgeCategoryRedisTunnel;
|
import com.renkang.consultation.api.storge.redis.ConKnowledgeCategoryRedisTunnel;
|
||||||
import com.renkang.consultation.entity.ConKnowledgeCategory;
|
import com.renkang.consultation.entity.ConKnowledgeCategory;
|
||||||
import org.springframework.beans.factory.annotation.Autowired;
|
import org.springframework.beans.factory.annotation.Autowired;
|
||||||
import org.springframework.stereotype.Repository;
|
import org.springframework.stereotype.Component;
|
||||||
|
|
||||||
import java.util.List;
|
import java.util.List;
|
||||||
|
|
||||||
@Repository
|
@Component
|
||||||
public class ComposeConKnowledgeCategory {
|
public class ComposeConKnowledgeCategory {
|
||||||
|
|
||||||
@Autowired
|
@Autowired
|
||||||
|
|||||||
+2
-2
@@ -5,11 +5,11 @@ import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper;
|
|||||||
import com.renkang.consultation.entity.ConKnowledgeCategory;
|
import com.renkang.consultation.entity.ConKnowledgeCategory;
|
||||||
import com.renkang.consultation.mapper.ConKnowledgeCategoryMapper;
|
import com.renkang.consultation.mapper.ConKnowledgeCategoryMapper;
|
||||||
import org.springframework.beans.factory.annotation.Autowired;
|
import org.springframework.beans.factory.annotation.Autowired;
|
||||||
import org.springframework.stereotype.Repository;
|
import org.springframework.stereotype.Component;
|
||||||
|
|
||||||
import java.util.List;
|
import java.util.List;
|
||||||
|
|
||||||
@Repository
|
@Component
|
||||||
public class ConKnowledgeCategoryDbTunnel {
|
public class ConKnowledgeCategoryDbTunnel {
|
||||||
|
|
||||||
|
|
||||||
|
|||||||
+2
-2
@@ -5,9 +5,9 @@ import com.renkang.consultation.entity.ConDoctorFollow;
|
|||||||
import org.springframework.beans.factory.annotation.Autowired;
|
import org.springframework.beans.factory.annotation.Autowired;
|
||||||
import org.springframework.data.redis.core.RedisTemplate;
|
import org.springframework.data.redis.core.RedisTemplate;
|
||||||
import org.springframework.data.redis.core.ZSetOperations;
|
import org.springframework.data.redis.core.ZSetOperations;
|
||||||
import org.springframework.stereotype.Repository;
|
import org.springframework.stereotype.Component;
|
||||||
|
|
||||||
@Repository
|
@Component
|
||||||
public class ConDoctorFollowReidsTunnel {
|
public class ConDoctorFollowReidsTunnel {
|
||||||
|
|
||||||
@Autowired
|
@Autowired
|
||||||
|
|||||||
+2
-2
@@ -4,11 +4,11 @@ import com.renkang.consultation.api.RedisConstants;
|
|||||||
import com.renkang.consultation.entity.ConHealthInfo;
|
import com.renkang.consultation.entity.ConHealthInfo;
|
||||||
import org.springframework.beans.factory.annotation.Autowired;
|
import org.springframework.beans.factory.annotation.Autowired;
|
||||||
import org.springframework.data.redis.core.RedisTemplate;
|
import org.springframework.data.redis.core.RedisTemplate;
|
||||||
import org.springframework.stereotype.Repository;
|
import org.springframework.stereotype.Component;
|
||||||
|
|
||||||
import java.util.List;
|
import java.util.List;
|
||||||
|
|
||||||
@Repository
|
@Component
|
||||||
public class ConHealthInfoRedisTunnel {
|
public class ConHealthInfoRedisTunnel {
|
||||||
|
|
||||||
@Autowired
|
@Autowired
|
||||||
|
|||||||
+2
-2
@@ -5,9 +5,9 @@ import com.renkang.consultation.entity.ConHospitalFollow;
|
|||||||
import org.springframework.beans.factory.annotation.Autowired;
|
import org.springframework.beans.factory.annotation.Autowired;
|
||||||
import org.springframework.data.redis.core.RedisTemplate;
|
import org.springframework.data.redis.core.RedisTemplate;
|
||||||
import org.springframework.data.redis.core.ZSetOperations;
|
import org.springframework.data.redis.core.ZSetOperations;
|
||||||
import org.springframework.stereotype.Repository;
|
import org.springframework.stereotype.Component;
|
||||||
|
|
||||||
@Repository
|
@Component
|
||||||
public class ConHospitalFollowReidsTunnel {
|
public class ConHospitalFollowReidsTunnel {
|
||||||
|
|
||||||
@Autowired
|
@Autowired
|
||||||
|
|||||||
+2
-2
@@ -4,11 +4,11 @@ import com.renkang.consultation.api.RedisConstants;
|
|||||||
import com.renkang.consultation.entity.ConKnowledgeCategory;
|
import com.renkang.consultation.entity.ConKnowledgeCategory;
|
||||||
import org.springframework.beans.factory.annotation.Autowired;
|
import org.springframework.beans.factory.annotation.Autowired;
|
||||||
import org.springframework.data.redis.core.RedisTemplate;
|
import org.springframework.data.redis.core.RedisTemplate;
|
||||||
import org.springframework.stereotype.Repository;
|
import org.springframework.stereotype.Component;
|
||||||
|
|
||||||
import java.util.List;
|
import java.util.List;
|
||||||
|
|
||||||
@Repository
|
@Component
|
||||||
public class ConKnowledgeCategoryRedisTunnel {
|
public class ConKnowledgeCategoryRedisTunnel {
|
||||||
|
|
||||||
|
|
||||||
|
|||||||
+7
@@ -1,5 +1,6 @@
|
|||||||
package com.renkang.consultation.controller;
|
package com.renkang.consultation.controller;
|
||||||
|
|
||||||
|
import cn.hutool.core.util.StrUtil;
|
||||||
import com.baomidou.mybatisplus.core.metadata.IPage;
|
import com.baomidou.mybatisplus.core.metadata.IPage;
|
||||||
import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
|
import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
|
||||||
import com.renkang.consultation.entity.ConDoctorCard;
|
import com.renkang.consultation.entity.ConDoctorCard;
|
||||||
@@ -62,6 +63,12 @@ public class ConDoctorCardController extends JeecgController<ConDoctorCard, ICon
|
|||||||
// @RequiresPermissions("consultation:con_doctor_card:add")
|
// @RequiresPermissions("consultation:con_doctor_card:add")
|
||||||
@PostMapping(value = "/add")
|
@PostMapping(value = "/add")
|
||||||
public Result<String> add(@RequestBody ConDoctorCard conDoctorCard) {
|
public Result<String> add(@RequestBody ConDoctorCard conDoctorCard) {
|
||||||
|
if (StrUtil.isEmpty(conDoctorCard.getCardMsg())){
|
||||||
|
return Result.error("请填写开户行");
|
||||||
|
}
|
||||||
|
if (StrUtil.isEmpty(conDoctorCard.getCardNum())){
|
||||||
|
return Result.error("请填写银行卡号");
|
||||||
|
}
|
||||||
conDoctorCard.setCreateTime(new Date());
|
conDoctorCard.setCreateTime(new Date());
|
||||||
conDoctorCardService.save(conDoctorCard);
|
conDoctorCardService.save(conDoctorCard);
|
||||||
return Result.OK("添加成功!");
|
return Result.OK("添加成功!");
|
||||||
|
|||||||
+1
-1
@@ -22,7 +22,7 @@ public class HolidayManager {
|
|||||||
private RedisUtil redisUtil;
|
private RedisUtil redisUtil;
|
||||||
|
|
||||||
//@Scheduled(cron = "0 0 0 1 1 ? *")
|
//@Scheduled(cron = "0 0 0 1 1 ? *")
|
||||||
@Scheduled(cron = "0 0 0 1 1 ? *")
|
@Scheduled(cron = "0 0 0 1 1 ?")
|
||||||
@PostConstruct
|
@PostConstruct
|
||||||
public void setRedisHoliday() throws IOException {
|
public void setRedisHoliday() throws IOException {
|
||||||
//获取当前年份
|
//获取当前年份
|
||||||
|
|||||||
+1
-1
@@ -24,7 +24,7 @@ public interface ConNoticeMapper extends BaseMapper<ConNotice> {
|
|||||||
*/
|
*/
|
||||||
IPage<ConNotice> queryPageList(IPage<ConNotice> page, @Param("conNotice") ConNotice conNotice);
|
IPage<ConNotice> queryPageList(IPage<ConNotice> page, @Param("conNotice") ConNotice conNotice);
|
||||||
|
|
||||||
@Select("SELECT * FROM con_notice WHERE status = '1' and del_flag = '0' and type = #{type} order by create_time desc limit 1")
|
@Select("SELECT * FROM con_notice WHERE status = '1' and del_flag = '0' and notice_type = #{type} order by create_time desc limit 1")
|
||||||
public ConNotice selectNoticeByType(String type);
|
public ConNotice selectNoticeByType(String type);
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|||||||
+4
-1
@@ -104,7 +104,7 @@
|
|||||||
SELECT doctor_id, MIN(card_num) as min_card_num
|
SELECT doctor_id, MIN(card_num) as min_card_num
|
||||||
FROM con_doctor_card
|
FROM con_doctor_card
|
||||||
GROUP BY doctor_id
|
GROUP BY doctor_id
|
||||||
) cdc_min ON cdc.doctor_id = cdc_min.doctor_id AND cdc.card_num = cdc_min.min_card_num
|
) cdc_min ON cdc.doctor_id = cdc_min.doctor_id AND cdc.del_flag = 0 AND cdc.card_num = cdc_min.min_card_num
|
||||||
GROUP BY cdc.doctor_id
|
GROUP BY cdc.doctor_id
|
||||||
) cdc_first ON a.id = cdc_first.doctor_id
|
) cdc_first ON a.id = cdc_first.doctor_id
|
||||||
WHERE a.del_flag = 0 AND a.status = 1
|
WHERE a.del_flag = 0 AND a.status = 1
|
||||||
@@ -137,6 +137,9 @@
|
|||||||
<if test="conDoctor.type != null and conDoctor.type != ''">
|
<if test="conDoctor.type != null and conDoctor.type != ''">
|
||||||
AND a.type = #{conDoctor.type}
|
AND a.type = #{conDoctor.type}
|
||||||
</if>
|
</if>
|
||||||
|
<if test="conDoctor.doctorJob != null and conDoctor.doctorJob != ''">
|
||||||
|
AND a.doctor_job = #{conDoctor.doctorJob}
|
||||||
|
</if>
|
||||||
<if test="conDoctor.isAccept != null and conDoctor.isAccept != ''">
|
<if test="conDoctor.isAccept != null and conDoctor.isAccept != ''">
|
||||||
AND a.is_accept = #{conDoctor.isAccept}
|
AND a.is_accept = #{conDoctor.isAccept}
|
||||||
</if>
|
</if>
|
||||||
|
|||||||
+1
-1
@@ -26,7 +26,7 @@
|
|||||||
#{item}
|
#{item}
|
||||||
</foreach>
|
</foreach>
|
||||||
)
|
)
|
||||||
and status = 1 and del_flag = 0
|
and status = 1 and del_flag = 0 and family_relation != '1'
|
||||||
GROUP BY group_id
|
GROUP BY group_id
|
||||||
</select>
|
</select>
|
||||||
<select id="selectFamilyGroupId" parameterType="list" resultType="com.renkang.consultation.vo.ConFamilyNumVO">
|
<select id="selectFamilyGroupId" parameterType="list" resultType="com.renkang.consultation.vo.ConFamilyNumVO">
|
||||||
|
|||||||
+5
-4
@@ -104,7 +104,7 @@
|
|||||||
<if test="conSession.orgCodes != null and conSession.orgCodes != ''">
|
<if test="conSession.orgCodes != null and conSession.orgCodes != ''">
|
||||||
AND (
|
AND (
|
||||||
<foreach item="item" index="index" collection="conSession.orgCodes" separator=" OR ">
|
<foreach item="item" index="index" collection="conSession.orgCodes" separator=" OR ">
|
||||||
c.org_code LIKE CONCAT('%', #{item}, '%')
|
c.org_code LIKE CONCAT(#{item}, '%')
|
||||||
</foreach>
|
</foreach>
|
||||||
)
|
)
|
||||||
</if>
|
</if>
|
||||||
@@ -537,7 +537,8 @@
|
|||||||
WHERE del_flag = 0
|
WHERE del_flag = 0
|
||||||
AND status = 1
|
AND status = 1
|
||||||
AND tf_reply = 1
|
AND tf_reply = 1
|
||||||
AND from_account IN
|
AND session_type = 1
|
||||||
|
AND to_account IN
|
||||||
<foreach item="id" collection="doctorIds" open="(" separator="," close=")">
|
<foreach item="id" collection="doctorIds" open="(" separator="," close=")">
|
||||||
#{id}
|
#{id}
|
||||||
</foreach>
|
</foreach>
|
||||||
@@ -629,7 +630,7 @@
|
|||||||
INNER JOIN (
|
INNER JOIN (
|
||||||
SELECT from_account, MAX(create_time) AS max_create_time
|
SELECT from_account, MAX(create_time) AS max_create_time
|
||||||
FROM con_session
|
FROM con_session
|
||||||
WHERE del_flag = 0 AND status = '1'
|
WHERE del_flag = 0 AND status = '1' AND session_type = '1'
|
||||||
GROUP BY from_account
|
GROUP BY from_account
|
||||||
) AS subquery ON c.from_account = subquery.from_account AND c.create_time = subquery.max_create_time
|
) AS subquery ON c.from_account = subquery.from_account AND c.create_time = subquery.max_create_time
|
||||||
WHERE c.del_flag = 0 AND c.status = '1'
|
WHERE c.del_flag = 0 AND c.status = '1'
|
||||||
@@ -1078,7 +1079,7 @@
|
|||||||
<if test="state != null and state != '' and state == '5'.toString()">
|
<if test="state != null and state != '' and state == '5'.toString()">
|
||||||
and (content_status = 5 or content_status = 6 or content_status = 7 or content_status = 8)
|
and (content_status = 5 or content_status = 6 or content_status = 7 or content_status = 8)
|
||||||
</if>
|
</if>
|
||||||
order by create_time desc
|
order by content_status asc ,create_time desc
|
||||||
</select>
|
</select>
|
||||||
|
|
||||||
|
|
||||||
|
|||||||
+13
-6
@@ -3,6 +3,7 @@ package com.renkang.consultation.service.impl;
|
|||||||
|
|
||||||
import cn.hutool.core.util.ObjectUtil;
|
import cn.hutool.core.util.ObjectUtil;
|
||||||
import cn.hutool.core.util.StrUtil;
|
import cn.hutool.core.util.StrUtil;
|
||||||
|
import cn.hutool.http.HtmlUtil;
|
||||||
import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper;
|
import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper;
|
||||||
import com.baomidou.mybatisplus.core.conditions.update.LambdaUpdateWrapper;
|
import com.baomidou.mybatisplus.core.conditions.update.LambdaUpdateWrapper;
|
||||||
import com.baomidou.mybatisplus.core.metadata.IPage;
|
import com.baomidou.mybatisplus.core.metadata.IPage;
|
||||||
@@ -17,6 +18,8 @@ import com.renkang.consultation.entity.*;
|
|||||||
import com.renkang.consultation.manager.ConsultCloudManager;
|
import com.renkang.consultation.manager.ConsultCloudManager;
|
||||||
import com.renkang.consultation.mapper.*;
|
import com.renkang.consultation.mapper.*;
|
||||||
import com.renkang.consultation.service.IConDoctorChangeLogService;
|
import com.renkang.consultation.service.IConDoctorChangeLogService;
|
||||||
|
import com.renkang.consultation.service.IConDoctorSchedulingDateService;
|
||||||
|
import com.renkang.consultation.service.IConDoctorSchedulingService;
|
||||||
import com.renkang.consultation.service.IConDoctorService;
|
import com.renkang.consultation.service.IConDoctorService;
|
||||||
import com.renkang.consultation.vo.*;
|
import com.renkang.consultation.vo.*;
|
||||||
import com.renkang.im.api.IMHelloApi;
|
import com.renkang.im.api.IMHelloApi;
|
||||||
@@ -109,6 +112,9 @@ public class ConDoctorServiceImpl extends ServiceImpl<ConDoctorMapper, ConDoctor
|
|||||||
@Autowired
|
@Autowired
|
||||||
private ConSessionServiceImpl conSessionServiceImpl;
|
private ConSessionServiceImpl conSessionServiceImpl;
|
||||||
|
|
||||||
|
@Autowired
|
||||||
|
private IConDoctorSchedulingDateService conDoctorSchedulingDateService;
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
/**
|
/**
|
||||||
@@ -150,7 +156,7 @@ public class ConDoctorServiceImpl extends ServiceImpl<ConDoctorMapper, ConDoctor
|
|||||||
conDoctor.setDoctorTitle(dto.getDoctorTitle());
|
conDoctor.setDoctorTitle(dto.getDoctorTitle());
|
||||||
}
|
}
|
||||||
// 通过Mapper查询并获取分页数据
|
// 通过Mapper查询并获取分页数据
|
||||||
if (dto.getDepartmentId() != null && !"".equals(dto.getDepartmentId())) {
|
if (dto.getDepartmentId() != null && !dto.getDepartmentId().isEmpty()) {
|
||||||
//查询出当前科室
|
//查询出当前科室
|
||||||
ConDepartment conDepartment = conDepartmentMapper.selectById(dto.getDepartmentId());
|
ConDepartment conDepartment = conDepartmentMapper.selectById(dto.getDepartmentId());
|
||||||
List<ConDepartment> departments = new ArrayList<>();
|
List<ConDepartment> departments = new ArrayList<>();
|
||||||
@@ -243,6 +249,9 @@ public class ConDoctorServiceImpl extends ServiceImpl<ConDoctorMapper, ConDoctor
|
|||||||
if (StringUtils.hasLength(dto.getHospitalName())) {
|
if (StringUtils.hasLength(dto.getHospitalName())) {
|
||||||
conDoctor.setResourceId(dto.getHospitalName());
|
conDoctor.setResourceId(dto.getHospitalName());
|
||||||
}
|
}
|
||||||
|
if (StrUtil.isNotEmpty(dto.getDoctorName())){
|
||||||
|
conDoctor.setDoctorName(HtmlUtil.unescape(dto.getDoctorName()));
|
||||||
|
}
|
||||||
IPage<ConDoctor> conDoctorIPage = conDoctorMapper.queryPageList(page, conDoctor);
|
IPage<ConDoctor> conDoctorIPage = conDoctorMapper.queryPageList(page, conDoctor);
|
||||||
List<ConDoctor> conDoctorList = conDoctorIPage.getRecords();
|
List<ConDoctor> conDoctorList = conDoctorIPage.getRecords();
|
||||||
if (CollectionUtils.isEmpty(conDoctorList)) {
|
if (CollectionUtils.isEmpty(conDoctorList)) {
|
||||||
@@ -302,10 +311,6 @@ public class ConDoctorServiceImpl extends ServiceImpl<ConDoctorMapper, ConDoctor
|
|||||||
// 创建一个ConDoctor对象,并从dto复制属性
|
// 创建一个ConDoctor对象,并从dto复制属性
|
||||||
ConDoctor conDoctor = new ConDoctor();
|
ConDoctor conDoctor = new ConDoctor();
|
||||||
BeanUtils.copyProperties(dto, conDoctor);
|
BeanUtils.copyProperties(dto, conDoctor);
|
||||||
conDoctor.setStartTime(null);
|
|
||||||
conDoctor.setEndTime(null);
|
|
||||||
|
|
||||||
boolean tfQh = GlobalUtils.isQh();
|
|
||||||
|
|
||||||
// 通过Mapper查询并获取分页数据
|
// 通过Mapper查询并获取分页数据
|
||||||
IPage<ConDoctor> conDoctorIPage = conDoctorMapper.queryPageList(page, conDoctor);
|
IPage<ConDoctor> conDoctorIPage = conDoctorMapper.queryPageList(page, conDoctor);
|
||||||
@@ -1042,7 +1047,9 @@ public class ConDoctorServiceImpl extends ServiceImpl<ConDoctorMapper, ConDoctor
|
|||||||
public Integer updateJumpHoliday(DoctorJumpHolidayDTO dto) {
|
public Integer updateJumpHoliday(DoctorJumpHolidayDTO dto) {
|
||||||
LambdaUpdateWrapper<ConDoctor> updateWrapper = new LambdaUpdateWrapper<>();
|
LambdaUpdateWrapper<ConDoctor> updateWrapper = new LambdaUpdateWrapper<>();
|
||||||
updateWrapper.eq(ConDoctor::getId, dto.getId()).set(ConDoctor::getTfJumpHoliday, dto.getTfJumpHoliday());
|
updateWrapper.eq(ConDoctor::getId, dto.getId()).set(ConDoctor::getTfJumpHoliday, dto.getTfJumpHoliday());
|
||||||
return conDoctorMapper.update(null, updateWrapper);
|
int update = conDoctorMapper.update(null, updateWrapper);
|
||||||
|
conDoctorSchedulingDateService.generateDoctorSchedulingDate(dto.getId());
|
||||||
|
return update;
|
||||||
}
|
}
|
||||||
|
|
||||||
@Transactional(rollbackFor = Exception.class)
|
@Transactional(rollbackFor = Exception.class)
|
||||||
|
|||||||
+9
-5
@@ -1,5 +1,6 @@
|
|||||||
package com.renkang.consultation.service.impl;
|
package com.renkang.consultation.service.impl;
|
||||||
|
|
||||||
|
import cn.hutool.core.collection.CollUtil;
|
||||||
import com.alibaba.fastjson.JSONObject;
|
import com.alibaba.fastjson.JSONObject;
|
||||||
import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper;
|
import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper;
|
||||||
import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper;
|
import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper;
|
||||||
@@ -131,7 +132,7 @@ public class ConHealthInfoAnswerServiceImpl extends ServiceImpl<ConHealthInfoAns
|
|||||||
List<ConSession> conSessions1 = collect.get(item.getFromAccount());
|
List<ConSession> conSessions1 = collect.get(item.getFromAccount());
|
||||||
List<String> collect1 = conSessions1.stream()
|
List<String> collect1 = conSessions1.stream()
|
||||||
.map(ConSession::getMemberId)
|
.map(ConSession::getMemberId)
|
||||||
.filter(memberId -> memberId != null && !memberId.isEmpty())
|
.filter(memberId -> memberId != null && !memberId.isEmpty()).distinct()
|
||||||
.collect(Collectors.toList());
|
.collect(Collectors.toList());
|
||||||
item.setMemberIds(collect1);
|
item.setMemberIds(collect1);
|
||||||
});
|
});
|
||||||
@@ -215,10 +216,13 @@ public class ConHealthInfoAnswerServiceImpl extends ServiceImpl<ConHealthInfoAns
|
|||||||
vo.setWorkNo(loginUserNew.getWorkNo());
|
vo.setWorkNo(loginUserNew.getWorkNo());
|
||||||
|
|
||||||
}
|
}
|
||||||
if (item.getGroupId() != null && !"".equals(item.getGroupId())) {
|
if (item.getGroupId() != null && !item.getGroupId().isEmpty()) {
|
||||||
Integer count = Objects.requireNonNull(finalConFamilyNumVOList.stream()
|
if (CollUtil.isNotEmpty(finalConFamilyNumVOList)){
|
||||||
.filter(ite -> ite.getGroupId().equals(item.getGroupId())).findFirst().orElse(null)).getCount();
|
ConFamilyNumVO conFamilyNumVO = finalConFamilyNumVOList.stream().filter(ite -> ite.getGroupId().equals(item.getGroupId())).findFirst().orElse(null);
|
||||||
vo.setFamilyNum(count);
|
if (conFamilyNumVO != null) {
|
||||||
|
vo.setFamilyNum(conFamilyNumVO.getCount());
|
||||||
|
}
|
||||||
|
}
|
||||||
}
|
}
|
||||||
vo.setId(item.getId());
|
vo.setId(item.getId());
|
||||||
voList.add(vo);
|
voList.add(vo);
|
||||||
|
|||||||
+7
-3
@@ -102,6 +102,7 @@ public class ConHelperServiceImpl extends ServiceImpl<ConHelperMapper, ConHelper
|
|||||||
// sysUserModel.setSecondDepartment(secondDepartOrgCode.getId());
|
// sysUserModel.setSecondDepartment(secondDepartOrgCode.getId());
|
||||||
// sysUserModel.setThirdDepartment(thirdDepartOrgCode.getId());
|
// sysUserModel.setThirdDepartment(thirdDepartOrgCode.getId());
|
||||||
sysUserModel.setRealname(conHelperExAndUser.getConHelper().getHelperName());
|
sysUserModel.setRealname(conHelperExAndUser.getConHelper().getHelperName());
|
||||||
|
sysUserModel.setUserRoleCode("helper");
|
||||||
String userId = sysBaseAPI.addUserToEx(sysUserModel);
|
String userId = sysBaseAPI.addUserToEx(sysUserModel);
|
||||||
|
|
||||||
if (!StringUtils.hasLength(userId)) {
|
if (!StringUtils.hasLength(userId)) {
|
||||||
@@ -368,10 +369,13 @@ public class ConHelperServiceImpl extends ServiceImpl<ConHelperMapper, ConHelper
|
|||||||
conHelperDoctorVO.setStatus(it.getDoctorStatus());
|
conHelperDoctorVO.setStatus(it.getDoctorStatus());
|
||||||
conHelperDoctorVO.setTimes("0");
|
conHelperDoctorVO.setTimes("0");
|
||||||
if (CollectionUtils.isNotEmpty(conSessions)) {
|
if (CollectionUtils.isNotEmpty(conSessions)) {
|
||||||
List<ConSession> collect = conSessions.stream().filter(i -> i.getToAccount().equals(it.getId())).filter(Objects::nonNull).distinct().collect(Collectors.toList());
|
int times = 0;
|
||||||
if (CollectionUtils.isNotEmpty(collect)) {
|
for (ConSession conSession : conSessions) {
|
||||||
conHelperDoctorVO.setTimes(String.valueOf(collect.size()));
|
if (conSession.getToAccount().equals(it.getId())) {
|
||||||
|
times++;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
conHelperDoctorVO.setTimes(String.valueOf(times));
|
||||||
}
|
}
|
||||||
conHelperDoctorVOList.add(conHelperDoctorVO);
|
conHelperDoctorVOList.add(conHelperDoctorVO);
|
||||||
});
|
});
|
||||||
|
|||||||
+3
-2
@@ -11,8 +11,9 @@ public class TempUtil {
|
|||||||
|
|
||||||
public static void reversalDocInfo(ConDoctorDO conDoctor){
|
public static void reversalDocInfo(ConDoctorDO conDoctor){
|
||||||
String isAccept = conDoctor.getIsAccept();
|
String isAccept = conDoctor.getIsAccept();
|
||||||
conDoctor.setIsAccept(conDoctor.getDoctorStatus());
|
// TODO 移动端说状态不对 先注掉试试
|
||||||
conDoctor.setDoctorStatus(isAccept);
|
// conDoctor.setIsAccept(conDoctor.getDoctorStatus());
|
||||||
|
// conDoctor.setDoctorStatus(isAccept);
|
||||||
}
|
}
|
||||||
|
|
||||||
public static void reversalDocInfo(ConDoctor conDoctor){
|
public static void reversalDocInfo(ConDoctor conDoctor){
|
||||||
|
|||||||
@@ -0,0 +1,22 @@
|
|||||||
|
FROM anapsix/alpine-java:8_server-jre_unlimited
|
||||||
|
|
||||||
|
ENV PROFILE_NAME=dev \
|
||||||
|
SERVER_PORT=7010 \
|
||||||
|
NACOS_SERVER_ADDR=nacos250:8848 \
|
||||||
|
NACOS_USERNAME=xjuser \
|
||||||
|
NACOS_PASSWORD=Aa135790!123 \
|
||||||
|
NACOS_NAMESPACE=3af98a54-4a44-4576-8e28-bf5781c0dccf \
|
||||||
|
NACOS_GROUP=dev
|
||||||
|
|
||||||
|
|
||||||
|
RUN ln -sf /usr/share/zoneinfo/Asia/Shanghai /etc/localtime
|
||||||
|
|
||||||
|
RUN mkdir -p /health-consultation-start
|
||||||
|
|
||||||
|
WORKDIR /health-consultation-start
|
||||||
|
|
||||||
|
EXPOSE 7010
|
||||||
|
|
||||||
|
COPY ./target/health-consultation-start-xj.jar ./
|
||||||
|
|
||||||
|
CMD sleep 1;java -Dfile.encoding=utf-8 -Djava.security.egd=file:/dev/./urandom -jar health-consultation-start-xj.jar
|
||||||
@@ -9,6 +9,11 @@
|
|||||||
<modelVersion>4.0.0</modelVersion>
|
<modelVersion>4.0.0</modelVersion>
|
||||||
|
|
||||||
<artifactId>health-consultation-start</artifactId>
|
<artifactId>health-consultation-start</artifactId>
|
||||||
|
|
||||||
|
<properties>
|
||||||
|
<maven.install.skip>true</maven.install.skip>
|
||||||
|
</properties>
|
||||||
|
|
||||||
<dependencies>
|
<dependencies>
|
||||||
<!--微服务启动 starter-->
|
<!--微服务启动 starter-->
|
||||||
<dependency>
|
<dependency>
|
||||||
@@ -24,6 +29,7 @@
|
|||||||
<dependency>
|
<dependency>
|
||||||
<groupId>com.renkang</groupId>
|
<groupId>com.renkang</groupId>
|
||||||
<artifactId>health-consultation-biz</artifactId>
|
<artifactId>health-consultation-biz</artifactId>
|
||||||
|
<classifier>${biz-classifier}</classifier>
|
||||||
</dependency>
|
</dependency>
|
||||||
|
|
||||||
</dependencies>
|
</dependencies>
|
||||||
|
|||||||
@@ -26,22 +26,3 @@ spring:
|
|||||||
server-addr: ${spring.cloud.nacos.server-addr}
|
server-addr: ${spring.cloud.nacos.server-addr}
|
||||||
username: ${spring.cloud.nacos.username}
|
username: ${spring.cloud.nacos.username}
|
||||||
password: ${spring.cloud.nacos.password}
|
password: ${spring.cloud.nacos.password}
|
||||||
|
|
||||||
|
|
||||||
jeecg:
|
|
||||||
dynamic:
|
|
||||||
tables:
|
|
||||||
- con_evaluate
|
|
||||||
- con_family_members
|
|
||||||
- con_health_info_answer
|
|
||||||
- con_health_info_child
|
|
||||||
- con_health_info
|
|
||||||
- con_helper_online
|
|
||||||
- con_helper
|
|
||||||
- con_helper_scheduling_history
|
|
||||||
- con_helper_scheduling
|
|
||||||
- con_hospital_follow
|
|
||||||
- con_session
|
|
||||||
- con_doctor_satisfy
|
|
||||||
- con_doctor_follow
|
|
||||||
- con_medical_records
|
|
||||||
@@ -13,10 +13,6 @@
|
|||||||
<version>2.0.0</version>
|
<version>2.0.0</version>
|
||||||
<packaging>pom</packaging>
|
<packaging>pom</packaging>
|
||||||
|
|
||||||
<properties>
|
|
||||||
<maven.install.skip>true</maven.install.skip>
|
|
||||||
</properties>
|
|
||||||
|
|
||||||
<!--项目子模块-->
|
<!--项目子模块-->
|
||||||
<modules>
|
<modules>
|
||||||
<module>health-consultation-api</module>
|
<module>health-consultation-api</module>
|
||||||
|
|||||||
@@ -13,6 +13,7 @@
|
|||||||
<dependency>
|
<dependency>
|
||||||
<groupId>org.jeecgframework.boot</groupId>
|
<groupId>org.jeecgframework.boot</groupId>
|
||||||
<artifactId>jeecg-boot-base-core</artifactId>
|
<artifactId>jeecg-boot-base-core</artifactId>
|
||||||
|
<classifier>xj</classifier>
|
||||||
</dependency>
|
</dependency>
|
||||||
|
|
||||||
<!-- feign -->
|
<!-- feign -->
|
||||||
|
|||||||
+18
@@ -0,0 +1,18 @@
|
|||||||
|
package com.renkang.emergency.bean.response;
|
||||||
|
|
||||||
|
import lombok.Data;
|
||||||
|
|
||||||
|
import javax.validation.constraints.NotNull;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* @author Junqiang Zhu
|
||||||
|
* @date 2024-04-12 15:16
|
||||||
|
*/
|
||||||
|
@Data
|
||||||
|
public class FakerDataEnable {
|
||||||
|
@NotNull(message = "未知模块")
|
||||||
|
private Integer module;
|
||||||
|
@NotNull(message = "未知结果")
|
||||||
|
private Boolean enable;
|
||||||
|
private String centerId;
|
||||||
|
}
|
||||||
+38
@@ -0,0 +1,38 @@
|
|||||||
|
package com.renkang.emergency.bean.response;
|
||||||
|
|
||||||
|
import cn.hutool.core.util.ObjectUtil;
|
||||||
|
import lombok.Data;
|
||||||
|
|
||||||
|
import javax.validation.constraints.NotNull;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* @author Junqiang Zhu
|
||||||
|
* @date 2024-04-12 14:40
|
||||||
|
*/
|
||||||
|
@Data
|
||||||
|
public class GroupUserFakerData {
|
||||||
|
// 总人数
|
||||||
|
private Integer totalUser;
|
||||||
|
// 大病
|
||||||
|
@NotNull(message = "大病人数不能为空")
|
||||||
|
private Integer illnessNum;
|
||||||
|
// 慢病
|
||||||
|
@NotNull(message = "慢病人数不能为空")
|
||||||
|
private Integer slowVirusNum;
|
||||||
|
// 异常
|
||||||
|
@NotNull(message = "异常人数不能为空")
|
||||||
|
private Integer failNum;
|
||||||
|
// 风险
|
||||||
|
@NotNull(message = "风险人数不能为空")
|
||||||
|
private Integer riskNum;
|
||||||
|
// 健康
|
||||||
|
@NotNull(message = "健康人数不能为空")
|
||||||
|
private Integer healthNum;
|
||||||
|
|
||||||
|
public Integer getTotalUser() {
|
||||||
|
if (ObjectUtil.isAllNotEmpty(illnessNum, slowVirusNum, failNum, riskNum, healthNum)) {
|
||||||
|
return illnessNum + slowVirusNum + failNum + riskNum + healthNum;
|
||||||
|
}
|
||||||
|
return null;
|
||||||
|
}
|
||||||
|
}
|
||||||
+36
@@ -0,0 +1,36 @@
|
|||||||
|
package com.renkang.emergency.bean.response;
|
||||||
|
|
||||||
|
import cn.hutool.core.util.ObjectUtil;
|
||||||
|
import lombok.Data;
|
||||||
|
|
||||||
|
import javax.validation.constraints.NotNull;
|
||||||
|
import java.math.BigDecimal;
|
||||||
|
import java.math.RoundingMode;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 健康水平dto
|
||||||
|
*
|
||||||
|
* @author Junqiang Zhu
|
||||||
|
* @date 2024-04-12 14:40
|
||||||
|
*/
|
||||||
|
@Data
|
||||||
|
public class HealthLevelFakerData {
|
||||||
|
|
||||||
|
@NotNull(message = "健康值不能为空")
|
||||||
|
private Double health;
|
||||||
|
@NotNull(message = "亚健康值不能为空")
|
||||||
|
private Double sub;
|
||||||
|
@NotNull(message = "轻度心理问题值不能为空")
|
||||||
|
private Double mild;
|
||||||
|
@NotNull(message = "中度心理问题值不能为空")
|
||||||
|
private Double moderate;
|
||||||
|
@NotNull(message = "高度心理问题值不能为空")
|
||||||
|
private Double serious;
|
||||||
|
|
||||||
|
public Double getHealth() {
|
||||||
|
if (ObjectUtil.isAllNotEmpty(sub, mild, moderate, serious)) {
|
||||||
|
return BigDecimal.valueOf(100 - sub - mild - moderate - serious).setScale(2, RoundingMode.HALF_UP).doubleValue();
|
||||||
|
}
|
||||||
|
return null;
|
||||||
|
}
|
||||||
|
}
|
||||||
+53
@@ -0,0 +1,53 @@
|
|||||||
|
package com.renkang.emergency.bean.response;
|
||||||
|
|
||||||
|
import lombok.Data;
|
||||||
|
|
||||||
|
import javax.validation.constraints.NotNull;
|
||||||
|
import java.math.BigDecimal;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 小屋运动 压力
|
||||||
|
*
|
||||||
|
* @author Junqiang Zhu
|
||||||
|
* @since 2024-04-12 14:40
|
||||||
|
*/
|
||||||
|
@Data
|
||||||
|
public class HouseWatchStressFakerData {
|
||||||
|
// 运动
|
||||||
|
@NotNull(message = "小于两公里不能为空")
|
||||||
|
private BigDecimal ltOne;
|
||||||
|
@NotNull(message = "小于两公里不能为空")
|
||||||
|
private BigDecimal ltTwo;
|
||||||
|
@NotNull(message = "小于两公里不能为空")
|
||||||
|
private BigDecimal ltThree;
|
||||||
|
@NotNull(message = "小于两公里不能为空")
|
||||||
|
private BigDecimal ltFour;
|
||||||
|
|
||||||
|
@NotNull(message = "3-5公里不能为空")
|
||||||
|
private BigDecimal middleOne;
|
||||||
|
@NotNull(message = "3-5公里不能为空")
|
||||||
|
private BigDecimal middleTwo;
|
||||||
|
@NotNull(message = "3-5公里不能为空")
|
||||||
|
private BigDecimal middleThree;
|
||||||
|
@NotNull(message = "3-5公里不能为空")
|
||||||
|
private BigDecimal middleFour;
|
||||||
|
|
||||||
|
@NotNull(message = "5公里以上不能为空")
|
||||||
|
private BigDecimal gtOne;
|
||||||
|
@NotNull(message = "5公里以上不能为空")
|
||||||
|
private BigDecimal gtTwo;
|
||||||
|
@NotNull(message = "5公里以上不能为空")
|
||||||
|
private BigDecimal gtThree;
|
||||||
|
@NotNull(message = "5公里以上不能为空")
|
||||||
|
private BigDecimal gtFour;
|
||||||
|
|
||||||
|
// 压力
|
||||||
|
@NotNull(message = "压力放松不能为空")
|
||||||
|
private BigDecimal stressRelax;
|
||||||
|
@NotNull(message = "压力正常不能为空")
|
||||||
|
private BigDecimal stressNormal;
|
||||||
|
@NotNull(message = "压力中等不能为空")
|
||||||
|
private BigDecimal stressMedium;
|
||||||
|
@NotNull(message = "压力偏高不能为空")
|
||||||
|
private BigDecimal stressHigh;
|
||||||
|
}
|
||||||
+35
@@ -0,0 +1,35 @@
|
|||||||
|
package com.renkang.emergency.bean.response;
|
||||||
|
|
||||||
|
import lombok.Data;
|
||||||
|
|
||||||
|
import javax.validation.constraints.NotNull;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 心理干预dto
|
||||||
|
*
|
||||||
|
* @author Junqiang Zhu
|
||||||
|
* @date 2024-04-12 14:40
|
||||||
|
*/
|
||||||
|
@Data
|
||||||
|
public class InterveneFakerData {
|
||||||
|
|
||||||
|
@NotNull(message = "睡眠前值不能为空")
|
||||||
|
private Double sleepAgo;
|
||||||
|
@NotNull(message = "睡眠后值不能为空")
|
||||||
|
private Double sleepLater;
|
||||||
|
|
||||||
|
@NotNull(message = "冥想前值不能为空")
|
||||||
|
private Double meditationAgo;
|
||||||
|
@NotNull(message = "冥想后值不能为空")
|
||||||
|
private Double meditationLater;
|
||||||
|
|
||||||
|
@NotNull(message = "骑行前值不能为空")
|
||||||
|
private Double cyclingAgo;
|
||||||
|
@NotNull(message = "骑行后值不能为空")
|
||||||
|
private Double cyclingLater;
|
||||||
|
|
||||||
|
@NotNull(message = "总体改善率不能为空")
|
||||||
|
private Double total;
|
||||||
|
|
||||||
|
|
||||||
|
}
|
||||||
+25
@@ -0,0 +1,25 @@
|
|||||||
|
package com.renkang.emergency.bean.response;
|
||||||
|
|
||||||
|
import lombok.Data;
|
||||||
|
|
||||||
|
import javax.validation.constraints.NotNull;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* @author Junqiang Zhu
|
||||||
|
* @date 2024-04-12 14:40
|
||||||
|
*/
|
||||||
|
@Data
|
||||||
|
public class MedicalCenterFakerData {
|
||||||
|
// 本周就诊人数
|
||||||
|
@NotNull(message = "本周就诊人数不能为空")
|
||||||
|
private Integer weekNum;
|
||||||
|
// 累计就诊人数
|
||||||
|
@NotNull(message = "累计就诊人数不能为空")
|
||||||
|
private Integer totalNum;
|
||||||
|
// 本周救护车
|
||||||
|
@NotNull(message = "本周救护车出动次数不能为空")
|
||||||
|
private Integer weekAmbulanceNum;
|
||||||
|
// 累计救护车
|
||||||
|
@NotNull(message = "累计救护车出动次数不能为空")
|
||||||
|
private Integer totalAmbulanceNum;
|
||||||
|
}
|
||||||
+30
@@ -0,0 +1,30 @@
|
|||||||
|
package com.renkang.emergency.bean.response;
|
||||||
|
|
||||||
|
import lombok.Data;
|
||||||
|
|
||||||
|
import javax.validation.constraints.NotNull;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 员工营养监测dto
|
||||||
|
*
|
||||||
|
* @author Junqiang Zhu
|
||||||
|
* @date 2024-04-12 14:40
|
||||||
|
*/
|
||||||
|
@Data
|
||||||
|
public class NutritionFakerData {
|
||||||
|
|
||||||
|
@NotNull(message = "早餐总人数不能为空")
|
||||||
|
private Integer breakfastHeadCount;
|
||||||
|
@NotNull(message = "早餐超标不能为空")
|
||||||
|
private Integer breakfastOutOfLimits;
|
||||||
|
|
||||||
|
@NotNull(message = "午餐总人数不能为空")
|
||||||
|
private Integer lunchHeadCount;
|
||||||
|
@NotNull(message = "午餐超标不能为空")
|
||||||
|
private Integer lunchOutOfLimits;
|
||||||
|
|
||||||
|
@NotNull(message = "晚餐总人数不能为空")
|
||||||
|
private Integer dinnerHeadCount;
|
||||||
|
@NotNull(message = "晚餐超标不能为空")
|
||||||
|
private Integer dinnerOutOfLimits;
|
||||||
|
}
|
||||||
+10
@@ -0,0 +1,10 @@
|
|||||||
|
package com.renkang.emergency.bean.response;
|
||||||
|
|
||||||
|
import lombok.Data;
|
||||||
|
|
||||||
|
@Data
|
||||||
|
public class XjDemandTypeFakerData {
|
||||||
|
private String centerId;
|
||||||
|
private String emergencyCount;
|
||||||
|
private String hospitalCount;
|
||||||
|
}
|
||||||
+71
@@ -0,0 +1,71 @@
|
|||||||
|
package com.renkang.emergency.bean.response;
|
||||||
|
|
||||||
|
import io.swagger.v3.oas.annotations.media.Schema;
|
||||||
|
import lombok.Data;
|
||||||
|
|
||||||
|
@Data
|
||||||
|
public class XjHealthSignFakerData {
|
||||||
|
private String centerId;
|
||||||
|
/**
|
||||||
|
* 减重今日打卡人数
|
||||||
|
*/
|
||||||
|
@Schema(title = "减重今日打卡人数")
|
||||||
|
private Integer weightLossCountDay;
|
||||||
|
/**
|
||||||
|
* 减重本月打卡人数
|
||||||
|
*/
|
||||||
|
@Schema(title = "减重本月打卡人数")
|
||||||
|
private Integer weightLossCountMonth;
|
||||||
|
/**
|
||||||
|
* 减重今日异常人数
|
||||||
|
*/
|
||||||
|
@Schema(title = "减重今日异常人数")
|
||||||
|
private Integer weightLossAbnormalCountDay;
|
||||||
|
/**
|
||||||
|
* 减重本月异常人数
|
||||||
|
*/
|
||||||
|
@Schema(title = "减重本月异常人数")
|
||||||
|
private Integer weightLossAbnormalCountMonth;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 血糖今日打卡人数
|
||||||
|
*/
|
||||||
|
@Schema(title = "血糖今日打卡人数")
|
||||||
|
private Integer bloodSugarCountDay;
|
||||||
|
/**
|
||||||
|
* 血糖本月打卡人数
|
||||||
|
*/
|
||||||
|
@Schema(title = "血糖本月打卡人数")
|
||||||
|
private Integer bloodSugarCountMonth;
|
||||||
|
/**
|
||||||
|
* 血糖今日异常人数
|
||||||
|
*/
|
||||||
|
@Schema(title = "血糖今日异常人数")
|
||||||
|
private Integer bloodSugarAbnormalCountDay;
|
||||||
|
/**
|
||||||
|
* 血糖本月异常人数
|
||||||
|
*/
|
||||||
|
@Schema(title = "血糖本月异常人数")
|
||||||
|
private Integer bloodSugarAbnormalCountMonth;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 血压今日打卡人数
|
||||||
|
*/
|
||||||
|
@Schema(title = "血压今日打卡人数")
|
||||||
|
private Integer bloodPressureCountDay;
|
||||||
|
/**
|
||||||
|
* 血压本月打卡人数
|
||||||
|
*/
|
||||||
|
@Schema(title = "血压本月打卡人数")
|
||||||
|
private Integer bloodPressureCountMonth;
|
||||||
|
/**
|
||||||
|
* 血压今日异常人数
|
||||||
|
*/
|
||||||
|
@Schema(title = "血压今日异常人数")
|
||||||
|
private Integer bloodPressureAbnormalCountDay;
|
||||||
|
/**
|
||||||
|
* 血压本月异常人数
|
||||||
|
*/
|
||||||
|
@Schema(title = "血压本月异常人数")
|
||||||
|
private Integer bloodPressureAbnormalCountMonth;
|
||||||
|
}
|
||||||
+10
@@ -0,0 +1,10 @@
|
|||||||
|
package com.renkang.emergency.bean.response;
|
||||||
|
|
||||||
|
import lombok.Data;
|
||||||
|
|
||||||
|
@Data
|
||||||
|
public class XjMedicalCountFakerData {
|
||||||
|
private String centerId;
|
||||||
|
private String name;
|
||||||
|
private String count;
|
||||||
|
}
|
||||||
+15
@@ -0,0 +1,15 @@
|
|||||||
|
package com.renkang.emergency.bean.response;
|
||||||
|
|
||||||
|
import lombok.Data;
|
||||||
|
|
||||||
|
@Data
|
||||||
|
public class XjMedicalDataFakerData {
|
||||||
|
private String centerId;
|
||||||
|
private Integer totalCount;
|
||||||
|
// 心血管异常人数
|
||||||
|
private Integer cardiovaAbCount;
|
||||||
|
// 脑血管异常人数
|
||||||
|
private Integer cerebrovAbCount;
|
||||||
|
// 冠脉ct异常人数
|
||||||
|
private Integer cctaAbCount;
|
||||||
|
}
|
||||||
+108
@@ -0,0 +1,108 @@
|
|||||||
|
package com.renkang.emergency.entity;
|
||||||
|
|
||||||
|
import com.baomidou.mybatisplus.annotation.IdType;
|
||||||
|
import com.baomidou.mybatisplus.annotation.TableId;
|
||||||
|
import com.baomidou.mybatisplus.annotation.TableLogic;
|
||||||
|
import com.fasterxml.jackson.annotation.JsonFormat;
|
||||||
|
import io.swagger.v3.oas.annotations.media.Schema;
|
||||||
|
import lombok.Data;
|
||||||
|
import org.jeecgframework.poi.excel.annotation.Excel;
|
||||||
|
import org.springframework.format.annotation.DateTimeFormat;
|
||||||
|
|
||||||
|
import java.util.Date;
|
||||||
|
|
||||||
|
@Data
|
||||||
|
public class EmergencyHealthRoom {
|
||||||
|
|
||||||
|
/**
|
||||||
|
* id
|
||||||
|
*/
|
||||||
|
@TableId(type = IdType.ASSIGN_ID)
|
||||||
|
@Schema(title = "id")
|
||||||
|
private String id;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 建设地点名称
|
||||||
|
*/
|
||||||
|
@Schema(title = "建设地点名称")
|
||||||
|
private String name;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 单位code
|
||||||
|
*/
|
||||||
|
@Schema(title = "单位code")
|
||||||
|
private String orgCode;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 单位名称(冗余字段更新orgCode记得同步更新)
|
||||||
|
*/
|
||||||
|
@Schema(title = "单位名称(冗余字段更新orgCode记得同步更新)")
|
||||||
|
private String orgName;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 在岗人数
|
||||||
|
*/
|
||||||
|
@Schema(title = "在岗人数")
|
||||||
|
private Integer jobNum;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 运转时间(分钟)
|
||||||
|
*/
|
||||||
|
@Schema(title = "运转时间(分钟)")
|
||||||
|
private Integer runTime;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 经度
|
||||||
|
*/
|
||||||
|
@Schema(title = "经度")
|
||||||
|
private String longitude;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 纬度
|
||||||
|
*/
|
||||||
|
@Schema(title = "纬度")
|
||||||
|
private String latitude;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 状态(1-正常,2-冻结)
|
||||||
|
*/
|
||||||
|
@Schema(title = "状态(1-正常,2-冻结)")
|
||||||
|
private Integer status;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 删除状态(0-正常,1-已删除)
|
||||||
|
*/
|
||||||
|
@Schema(title = "删除状态(0-正常,1-已删除)")
|
||||||
|
@TableLogic
|
||||||
|
private Integer delFlag;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 创建人
|
||||||
|
*/
|
||||||
|
@Schema(title = "创建人")
|
||||||
|
private String createBy;
|
||||||
|
/**
|
||||||
|
* 创建时间
|
||||||
|
*/
|
||||||
|
@JsonFormat(timezone = "GMT+8", pattern = "yyyy-MM-dd HH:mm:ss")
|
||||||
|
@DateTimeFormat(pattern = "yyyy-MM-dd HH:mm:ss")
|
||||||
|
@Schema(title = "创建时间")
|
||||||
|
private Date createTime;
|
||||||
|
/**
|
||||||
|
* 更新人
|
||||||
|
*/
|
||||||
|
@Schema(title = "更新人")
|
||||||
|
private String updateBy;
|
||||||
|
/**
|
||||||
|
* 更新时间
|
||||||
|
*/
|
||||||
|
@JsonFormat(timezone = "GMT+8", pattern = "yyyy-MM-dd HH:mm:ss")
|
||||||
|
@DateTimeFormat(pattern = "yyyy-MM-dd HH:mm:ss")
|
||||||
|
@Schema(title = "更新时间")
|
||||||
|
private Date updateTime;
|
||||||
|
/**
|
||||||
|
* 备注
|
||||||
|
*/
|
||||||
|
@Schema(title = "备注")
|
||||||
|
private String memo;
|
||||||
|
}
|
||||||
+2
@@ -105,6 +105,7 @@ public class Order implements Serializable {
|
|||||||
*/
|
*/
|
||||||
@Excel(name = "发起人性别", width = 15)
|
@Excel(name = "发起人性别", width = 15)
|
||||||
@Schema(title = "发起人性别")
|
@Schema(title = "发起人性别")
|
||||||
|
@Dict(dicCode = "sex2")
|
||||||
private java.lang.String initiatorUserSex;
|
private java.lang.String initiatorUserSex;
|
||||||
/**
|
/**
|
||||||
* 发起人电话
|
* 发起人电话
|
||||||
@@ -159,6 +160,7 @@ public class Order implements Serializable {
|
|||||||
*/
|
*/
|
||||||
@Excel(name = "救助人性别", width = 15)
|
@Excel(name = "救助人性别", width = 15)
|
||||||
@Schema(title = "救助人性别")
|
@Schema(title = "救助人性别")
|
||||||
|
@Dict(dicCode = "sex2")
|
||||||
private java.lang.String salvageUserSex;
|
private java.lang.String salvageUserSex;
|
||||||
/**
|
/**
|
||||||
* 救助人电话
|
* 救助人电话
|
||||||
|
|||||||
+2
@@ -9,6 +9,7 @@ import io.swagger.v3.oas.annotations.media.Schema;
|
|||||||
import lombok.Data;
|
import lombok.Data;
|
||||||
import lombok.EqualsAndHashCode;
|
import lombok.EqualsAndHashCode;
|
||||||
import lombok.experimental.Accessors;
|
import lombok.experimental.Accessors;
|
||||||
|
import org.jeecg.common.aspect.annotation.Dict;
|
||||||
import org.jeecgframework.poi.excel.annotation.Excel;
|
import org.jeecgframework.poi.excel.annotation.Excel;
|
||||||
import org.springframework.format.annotation.DateTimeFormat;
|
import org.springframework.format.annotation.DateTimeFormat;
|
||||||
|
|
||||||
@@ -113,6 +114,7 @@ public class Resource implements Serializable {
|
|||||||
*/
|
*/
|
||||||
@Excel(name = "医院等级", width = 15)
|
@Excel(name = "医院等级", width = 15)
|
||||||
@Schema(title = "医院等级")
|
@Schema(title = "医院等级")
|
||||||
|
@Dict(dicCode = "hospital_level")
|
||||||
private String level;
|
private String level;
|
||||||
/**
|
/**
|
||||||
* 图片
|
* 图片
|
||||||
|
|||||||
@@ -9,6 +9,7 @@
|
|||||||
<modelVersion>4.0.0</modelVersion>
|
<modelVersion>4.0.0</modelVersion>
|
||||||
|
|
||||||
<artifactId>health-emergency-biz</artifactId>
|
<artifactId>health-emergency-biz</artifactId>
|
||||||
|
|
||||||
<dependencies>
|
<dependencies>
|
||||||
<!--定时任务-->
|
<!--定时任务-->
|
||||||
<dependency>
|
<dependency>
|
||||||
@@ -18,15 +19,18 @@
|
|||||||
<dependency>
|
<dependency>
|
||||||
<groupId>com.renkang</groupId>
|
<groupId>com.renkang</groupId>
|
||||||
<artifactId>health-emergency-api</artifactId>
|
<artifactId>health-emergency-api</artifactId>
|
||||||
|
<classifier>xj</classifier>
|
||||||
</dependency>
|
</dependency>
|
||||||
|
|
||||||
<dependency>
|
<dependency>
|
||||||
<groupId>org.jeecgframework.boot</groupId>
|
<groupId>org.jeecgframework.boot</groupId>
|
||||||
<artifactId>jeecg-system-cloud-api</artifactId>
|
<artifactId>jeecg-system-cloud-api</artifactId>
|
||||||
|
<classifier>xj</classifier>
|
||||||
</dependency>
|
</dependency>
|
||||||
<dependency>
|
<dependency>
|
||||||
<groupId>com.renkang</groupId>
|
<groupId>com.renkang</groupId>
|
||||||
<artifactId>health-im-api</artifactId>
|
<artifactId>health-im-api</artifactId>
|
||||||
|
<classifier>xj</classifier>
|
||||||
</dependency>
|
</dependency>
|
||||||
|
|
||||||
</dependencies>
|
</dependencies>
|
||||||
@@ -47,4 +51,21 @@
|
|||||||
</plugin>
|
</plugin>
|
||||||
</plugins>
|
</plugins>
|
||||||
</build>
|
</build>
|
||||||
|
<profiles>
|
||||||
|
<profile>
|
||||||
|
<id>biz-obf</id>
|
||||||
|
<build>
|
||||||
|
<plugins>
|
||||||
|
<plugin>
|
||||||
|
<groupId>com.github.wvengen</groupId>
|
||||||
|
<artifactId>proguard-maven-plugin</artifactId>
|
||||||
|
</plugin>
|
||||||
|
<plugin>
|
||||||
|
<groupId>org.codehaus.mojo</groupId>
|
||||||
|
<artifactId>build-helper-maven-plugin</artifactId>
|
||||||
|
</plugin>
|
||||||
|
</plugins>
|
||||||
|
</build>
|
||||||
|
</profile>
|
||||||
|
</profiles>
|
||||||
</project>
|
</project>
|
||||||
|
|||||||
@@ -0,0 +1,38 @@
|
|||||||
|
-keepattributes *Annotation*, Signature, InnerClasses, EnclosingMethod, Exceptions, MethodParameters
|
||||||
|
-keep @org.springframework.stereotype.Service class *
|
||||||
|
-keep @org.springframework.web.bind.annotation.RestController class *
|
||||||
|
-keep @org.springframework.context.annotation.Configuration class * { *; }
|
||||||
|
-keep @org.springframework.stereotype.Component class *
|
||||||
|
-keep class lombok.** { *; }
|
||||||
|
-keepclassmembers enum * { # 保留枚举结构
|
||||||
|
public static **[] values();
|
||||||
|
public static ** valueOf(java.lang.String);
|
||||||
|
}
|
||||||
|
-keepclassmembers class * implements java.io.Serializable { *; }
|
||||||
|
-keepclassmembers class * {
|
||||||
|
@org.springframework.web.bind.annotation.*Mapping *;
|
||||||
|
}
|
||||||
|
-keepclassmembers class * {
|
||||||
|
private static synthetic java.lang.Object $deserializeLambda$(java.lang.invoke.SerializedLambda);
|
||||||
|
}
|
||||||
|
-keepclassmembers class * {
|
||||||
|
@lombok.Getter *;
|
||||||
|
@lombok.Setter *;
|
||||||
|
}
|
||||||
|
# MyBatis 专用保留规则
|
||||||
|
-keep interface com.renkang.**.mapper.** { *; }
|
||||||
|
-keep class com.renkang.**.entity.** { *; }
|
||||||
|
-keep class com.renkang.**.bean.** { *; }
|
||||||
|
-keep class com.renkang.**.model.** { *; }
|
||||||
|
-keep class com.renkang.**.vo.** { *; }
|
||||||
|
-keepparameternames
|
||||||
|
|
||||||
|
# 关闭优化和压缩(避免框架兼容性问题)
|
||||||
|
-dontshrink # 不删除未使用代码
|
||||||
|
-dontoptimize # 不优化字节码[5,6](@ref)
|
||||||
|
-keepdirectories
|
||||||
|
-dontusemixedcaseclassnames
|
||||||
|
-adaptclassstrings
|
||||||
|
# 混淆选项
|
||||||
|
-useuniqueclassmembernames # 成员名称唯一化
|
||||||
|
-ignorewarnings
|
||||||
+13
@@ -10,6 +10,8 @@ import org.springframework.web.bind.annotation.RequestMapping;
|
|||||||
import org.springframework.web.bind.annotation.RequestParam;
|
import org.springframework.web.bind.annotation.RequestParam;
|
||||||
import org.springframework.web.bind.annotation.RestController;
|
import org.springframework.web.bind.annotation.RestController;
|
||||||
|
|
||||||
|
import java.util.List;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* 排班controller
|
* 排班controller
|
||||||
*
|
*
|
||||||
@@ -44,4 +46,15 @@ public class EmergencyScheduleApiController {
|
|||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 年/月值班 展示
|
||||||
|
*/
|
||||||
|
@GetMapping("/scheduleShow/v2")
|
||||||
|
public Result<List<Integer>> scheduleShowV2(@RequestParam Integer year,
|
||||||
|
@RequestParam Integer month,
|
||||||
|
@RequestParam(required = false) String userId) {
|
||||||
|
return Result.ok(emergencyScheduleApiService.scheduleShowV2(year, month, userId));
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|||||||
+4
@@ -2,6 +2,8 @@ package com.renkang.emergency.api.service;
|
|||||||
|
|
||||||
import com.renkang.emergency.bean.response.ScheduleRecordShow;
|
import com.renkang.emergency.bean.response.ScheduleRecordShow;
|
||||||
|
|
||||||
|
import java.util.List;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* @author Junqiang Zhu
|
* @author Junqiang Zhu
|
||||||
* @date 2023-04-25 13:07
|
* @date 2023-04-25 13:07
|
||||||
@@ -10,4 +12,6 @@ public interface EmergencyScheduleApiService {
|
|||||||
ScheduleRecordShow scheduleRecord(String year, String month, String userId);
|
ScheduleRecordShow scheduleRecord(String year, String month, String userId);
|
||||||
|
|
||||||
ScheduleRecordShow scheduleShow(Integer year, Integer month, String userId);
|
ScheduleRecordShow scheduleShow(Integer year, Integer month, String userId);
|
||||||
|
|
||||||
|
List<Integer> scheduleShowV2(Integer year, Integer month, String userId);
|
||||||
}
|
}
|
||||||
|
|||||||
+42
-20
@@ -7,6 +7,7 @@ import com.renkang.emergency.api.service.EmergencyResourceApiService;
|
|||||||
import com.renkang.emergency.bean.common.ResourceExt;
|
import com.renkang.emergency.bean.common.ResourceExt;
|
||||||
import com.renkang.emergency.bean.response.ResourceHome;
|
import com.renkang.emergency.bean.response.ResourceHome;
|
||||||
import com.renkang.emergency.constant.EmergencyConstants;
|
import com.renkang.emergency.constant.EmergencyConstants;
|
||||||
|
import com.renkang.emergency.entity.EmergencyHealthRoom;
|
||||||
import com.renkang.emergency.entity.EmergencyResourceDO;
|
import com.renkang.emergency.entity.EmergencyResourceDO;
|
||||||
import com.renkang.emergency.entity.Order;
|
import com.renkang.emergency.entity.Order;
|
||||||
import com.renkang.emergency.entity.Resource;
|
import com.renkang.emergency.entity.Resource;
|
||||||
@@ -14,6 +15,7 @@ import com.renkang.emergency.manager.EmergencyCloudManager;
|
|||||||
import com.renkang.emergency.manager.ResourceManager;
|
import com.renkang.emergency.manager.ResourceManager;
|
||||||
import com.renkang.emergency.mapper.OrderMapper;
|
import com.renkang.emergency.mapper.OrderMapper;
|
||||||
import com.renkang.emergency.mapper.ResourceMapper;
|
import com.renkang.emergency.mapper.ResourceMapper;
|
||||||
|
import com.renkang.emergency.service.IEmergencyHealthRoomService;
|
||||||
import com.renkang.emergency.util.ResourceUtils;;
|
import com.renkang.emergency.util.ResourceUtils;;
|
||||||
import org.apache.commons.collections4.CollectionUtils;
|
import org.apache.commons.collections4.CollectionUtils;
|
||||||
import org.apache.commons.lang3.ObjectUtils;
|
import org.apache.commons.lang3.ObjectUtils;
|
||||||
@@ -25,6 +27,7 @@ import org.springframework.beans.factory.annotation.Autowired;
|
|||||||
import org.springframework.data.geo.Point;
|
import org.springframework.data.geo.Point;
|
||||||
import org.springframework.stereotype.Service;
|
import org.springframework.stereotype.Service;
|
||||||
|
|
||||||
|
import java.math.BigDecimal;
|
||||||
import java.util.ArrayList;
|
import java.util.ArrayList;
|
||||||
import java.util.Collections;
|
import java.util.Collections;
|
||||||
import java.util.List;
|
import java.util.List;
|
||||||
@@ -45,6 +48,8 @@ public class EmergencyResourceApiServiceImpl implements EmergencyResourceApiServ
|
|||||||
private OrderMapper orderMapper;
|
private OrderMapper orderMapper;
|
||||||
@Autowired
|
@Autowired
|
||||||
private ResourceMapper resourceMapper;
|
private ResourceMapper resourceMapper;
|
||||||
|
@Autowired
|
||||||
|
private IEmergencyHealthRoomService roomService;
|
||||||
|
|
||||||
@Autowired
|
@Autowired
|
||||||
private ISysBaseAPI sysBaseAPI;
|
private ISysBaseAPI sysBaseAPI;
|
||||||
@@ -68,30 +73,47 @@ public class EmergencyResourceApiServiceImpl implements EmergencyResourceApiServ
|
|||||||
List<DictModel> dictItems = emergencyCloudManager.getDictItems(EmergencyConstants.EMERGENCY_RESOURCE_TYPE_DICT);
|
List<DictModel> dictItems = emergencyCloudManager.getDictItems(EmergencyConstants.EMERGENCY_RESOURCE_TYPE_DICT);
|
||||||
|
|
||||||
if (ObjectUtils.isEmpty(longitude) || ObjectUtils.isEmpty(latitude)) {
|
if (ObjectUtils.isEmpty(longitude) || ObjectUtils.isEmpty(latitude)) {
|
||||||
home.setDicts(dictItems);
|
if (!"3".equals(type)) {
|
||||||
|
home.setDicts(dictItems);
|
||||||
|
|
||||||
List<ResourceExt> list = this.listResource(type);
|
List<ResourceExt> list = this.listResource(type);
|
||||||
|
|
||||||
List<ResourceExt> resources = new ArrayList<>();
|
List<ResourceExt> resources = new ArrayList<>();
|
||||||
if("3".equals(type) || "0".equals(type)){
|
if ("0".equals(type)) {
|
||||||
resources = this.selectResourceByLongitudeLatitude(null,null,null);
|
resources = this.selectResourceByLongitudeLatitude(null, null, null);
|
||||||
|
}
|
||||||
|
list.addAll(resources);
|
||||||
|
home.setResources(list);
|
||||||
|
return home;
|
||||||
|
}
|
||||||
|
}else {
|
||||||
|
if (!"3".equals(type)) {
|
||||||
|
// 资源数据
|
||||||
|
Point point = new Point(longitude, latitude);
|
||||||
|
List<ResourceExt> resources = resourceManager.geoSearch(point, 100000, type);
|
||||||
|
List<ResourceExt> resourcesLL = new ArrayList<>();
|
||||||
|
if ("0".equals(type)) {
|
||||||
|
resourcesLL = this.selectResourceByLongitudeLatitude(100000D, longitude, latitude);
|
||||||
|
}
|
||||||
|
resources.addAll(resourcesLL);
|
||||||
|
home.setDicts(dictItems);
|
||||||
|
home.setResources(resources);
|
||||||
|
return home;
|
||||||
}
|
}
|
||||||
|
|
||||||
list.addAll(resources);
|
|
||||||
home.setResources(list);
|
|
||||||
|
|
||||||
return home;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
// 资源数据
|
List<EmergencyHealthRoom> list = roomService.list();
|
||||||
Point point = new Point(longitude, latitude);
|
List<ResourceExt> resources = new ArrayList<>();
|
||||||
List<ResourceExt> resources = resourceManager.geoSearch(point, 100000, type);
|
for (EmergencyHealthRoom emergencyHealthRoom : list) {
|
||||||
List<ResourceExt> resourcesLL = new ArrayList<>();
|
ResourceExt ext = new ResourceExt();
|
||||||
if("3".equals(type) || "0".equals(type)){
|
ext.setId(emergencyHealthRoom.getId());
|
||||||
resourcesLL = this.selectResourceByLongitudeLatitude(100000D,longitude,latitude);
|
ext.setName(emergencyHealthRoom.getName());
|
||||||
|
ext.setAddress(emergencyHealthRoom.getOrgName());
|
||||||
|
ext.setLatitude(new BigDecimal(emergencyHealthRoom.getLatitude()));
|
||||||
|
ext.setLongitude(new BigDecimal(emergencyHealthRoom.getLongitude()));
|
||||||
|
ext.setType("3");
|
||||||
|
resources.add(ext);
|
||||||
}
|
}
|
||||||
resources.addAll(resourcesLL);
|
|
||||||
|
|
||||||
home.setDicts(dictItems);
|
home.setDicts(dictItems);
|
||||||
home.setResources(resources);
|
home.setResources(resources);
|
||||||
return home;
|
return home;
|
||||||
@@ -149,7 +171,7 @@ public class EmergencyResourceApiServiceImpl implements EmergencyResourceApiServ
|
|||||||
|
|
||||||
private List<ResourceExt> listResource(String type) {
|
private List<ResourceExt> listResource(String type) {
|
||||||
|
|
||||||
if("3".equals(type)){
|
if ("3".equals(type)) {
|
||||||
return Collections.emptyList();
|
return Collections.emptyList();
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -174,7 +196,7 @@ public class EmergencyResourceApiServiceImpl implements EmergencyResourceApiServ
|
|||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
public List<ResourceExt> selectResourceByLongitudeLatitude(Double distance,Double longitude,Double latitude){
|
public List<ResourceExt> selectResourceByLongitudeLatitude(Double distance, Double longitude, Double latitude) {
|
||||||
List<ResourceExt> resourceExtList = new ArrayList<>();
|
List<ResourceExt> resourceExtList = new ArrayList<>();
|
||||||
/* Point point = new Point(longitude, latitude);
|
/* Point point = new Point(longitude, latitude);
|
||||||
List<MedicalResource> list = medicalCenterApi.selectResourceByLongitudeLatitude(distance, longitude, latitude).getResult();
|
List<MedicalResource> list = medicalCenterApi.selectResourceByLongitudeLatitude(distance, longitude, latitude).getResult();
|
||||||
|
|||||||
+30
@@ -1,5 +1,6 @@
|
|||||||
package com.renkang.emergency.api.service.impl;
|
package com.renkang.emergency.api.service.impl;
|
||||||
|
|
||||||
|
import cn.hutool.core.collection.CollUtil;
|
||||||
import cn.hutool.core.date.DateUtil;
|
import cn.hutool.core.date.DateUtil;
|
||||||
import cn.hutool.core.util.ObjectUtil;
|
import cn.hutool.core.util.ObjectUtil;
|
||||||
import cn.hutool.core.util.StrUtil;
|
import cn.hutool.core.util.StrUtil;
|
||||||
@@ -12,6 +13,7 @@ import com.renkang.emergency.constant.EmergencyConstants;
|
|||||||
import com.renkang.emergency.entity.ScheduleCustom;
|
import com.renkang.emergency.entity.ScheduleCustom;
|
||||||
import com.renkang.emergency.entity.ScheduleDefault;
|
import com.renkang.emergency.entity.ScheduleDefault;
|
||||||
import com.renkang.emergency.entity.ScheduleRecord;
|
import com.renkang.emergency.entity.ScheduleRecord;
|
||||||
|
import com.renkang.emergency.mapper.EmergencySchedulesNewMapper;
|
||||||
import com.renkang.emergency.mapper.ScheduleCustomMapper;
|
import com.renkang.emergency.mapper.ScheduleCustomMapper;
|
||||||
import com.renkang.emergency.mapper.ScheduleDefaultMapper;
|
import com.renkang.emergency.mapper.ScheduleDefaultMapper;
|
||||||
import com.renkang.emergency.mapper.ScheduleRecordMapper;
|
import com.renkang.emergency.mapper.ScheduleRecordMapper;
|
||||||
@@ -37,6 +39,8 @@ public class EmergencyScheduleApiServiceImpl implements EmergencyScheduleApiServ
|
|||||||
private ScheduleCustomMapper scheduleCustomMapper;
|
private ScheduleCustomMapper scheduleCustomMapper;
|
||||||
@Autowired
|
@Autowired
|
||||||
private ScheduleDefaultMapper scheduleDefaultMapper;
|
private ScheduleDefaultMapper scheduleDefaultMapper;
|
||||||
|
@Autowired
|
||||||
|
private EmergencySchedulesNewMapper schedulesNewMapper;
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public ScheduleRecordShow scheduleRecord(String year, String month, String userId) {
|
public ScheduleRecordShow scheduleRecord(String year, String month, String userId) {
|
||||||
@@ -94,6 +98,32 @@ public class EmergencyScheduleApiServiceImpl implements EmergencyScheduleApiServ
|
|||||||
return show;
|
return show;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public List<Integer> scheduleShowV2(Integer year, Integer month, String userId) {
|
||||||
|
if (ObjectUtil.isNull(year)) {
|
||||||
|
throw new RuntimeException("参数缺失 year");
|
||||||
|
}
|
||||||
|
if (ObjectUtil.isNull(month)) {
|
||||||
|
throw new RuntimeException("参数缺失 month");
|
||||||
|
}
|
||||||
|
if (StrUtil.isBlank(userId)) {
|
||||||
|
userId = GlobalUtils.getLoginUser().getId();
|
||||||
|
}
|
||||||
|
// 查询排班记录
|
||||||
|
List<Date> schedules = schedulesNewMapper.scheduleTimes(year,month,userId);
|
||||||
|
return convertSchedules(schedules);
|
||||||
|
}
|
||||||
|
|
||||||
|
private List<Integer> convertSchedules(List<Date> schedules) {
|
||||||
|
if (CollUtil.isEmpty(schedules)) {
|
||||||
|
return Collections.emptyList();
|
||||||
|
}
|
||||||
|
return schedules.stream()
|
||||||
|
.map(DateUtil::dayOfMonth)
|
||||||
|
.distinct()
|
||||||
|
.sorted(Comparator.comparingInt(o -> o))
|
||||||
|
.collect(Collectors.toList());
|
||||||
|
}
|
||||||
|
|
||||||
private ScheduleMonth getFutureMonth(Integer year, Integer month, String userId) {
|
private ScheduleMonth getFutureMonth(Integer year, Integer month, String userId) {
|
||||||
// 默认排班
|
// 默认排班
|
||||||
|
|||||||
+16
-12
@@ -109,15 +109,16 @@ public class LargeScreenImpl {
|
|||||||
* Ps:新增type
|
* Ps:新增type
|
||||||
*/
|
*/
|
||||||
private void startPush(EmergencySocket socket, String busId, EmergencyCenter center,Integer type) {
|
private void startPush(EmergencySocket socket, String busId, EmergencyCenter center,Integer type) {
|
||||||
|
// Ps: 新疆不需要走旧版大屏逻辑
|
||||||
// 根据 center.getDefaultCenter() 状态 走不同逻辑 true:旧版逻辑 false:新版逻辑
|
// 根据 center.getDefaultCenter() 状态 走不同逻辑 true:旧版逻辑 false:新版逻辑
|
||||||
if (center.getDefaultCenter()) {
|
// if (center.getDefaultCenter()) {
|
||||||
this.defaultLargeScreenPush(socket);
|
// this.defaultLargeScreenPush(socket);
|
||||||
this.defaultSmsPush(socket, busId, center, type);
|
// this.defaultSmsPush(socket, busId, center, type);
|
||||||
} else {
|
// } else {
|
||||||
log.info("新版大屏推送... 执行时间: {}", System.currentTimeMillis());
|
log.info("新版大屏推送... 执行时间: {}", System.currentTimeMillis());
|
||||||
webSocket.pushMessageBase(socket);
|
webSocket.pushMessageBase(socket);
|
||||||
this.newSmsPush(socket, busId, center, type);
|
this.newSmsPush(socket, busId, center, type);
|
||||||
}
|
// }
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
@@ -244,6 +245,7 @@ public class LargeScreenImpl {
|
|||||||
hospitalSocketVo.setName(item.getName());
|
hospitalSocketVo.setName(item.getName());
|
||||||
hospitalSocketVo.setLon(item.getLon());
|
hospitalSocketVo.setLon(item.getLon());
|
||||||
hospitalSocketVo.setLat(item.getLat());
|
hospitalSocketVo.setLat(item.getLat());
|
||||||
|
hospitalSocketVo.setDistance(item.getDistance());
|
||||||
hospitalSocketVoList.add(hospitalSocketVo);
|
hospitalSocketVoList.add(hospitalSocketVo);
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
@@ -465,13 +467,15 @@ public class LargeScreenImpl {
|
|||||||
}
|
}
|
||||||
|
|
||||||
// 先对整个列表进行排序
|
// 先对整个列表进行排序
|
||||||
allList.sort(new Comparator<TblBaseHospitalVo>() {
|
allList.sort((h1, h2) -> {
|
||||||
@Override
|
double h1Lat = h1.getLat().doubleValue();
|
||||||
public int compare(TblBaseHospitalVo h1, TblBaseHospitalVo h2) {
|
double h1Lon = h1.getLon().doubleValue();
|
||||||
double dist1 = distance(lat, lon, h1.getLat().doubleValue(), h1.getLon().doubleValue());
|
double h2Lat = h2.getLat().doubleValue();
|
||||||
double dist2 = distance(lon, lat, h2.getLat().doubleValue(), h2.getLon().doubleValue());
|
double h2Lon = h2.getLon().doubleValue();
|
||||||
return Double.compare(dist1, dist2);
|
|
||||||
}
|
double dist1 = distance(lat, lon, h1Lat, h1Lon);
|
||||||
|
double dist2 = distance(lat, lon, h2Lat, h2Lon);
|
||||||
|
return Double.compare(dist1, dist2);
|
||||||
});
|
});
|
||||||
|
|
||||||
// 选择前三个最近的点
|
// 选择前三个最近的点
|
||||||
|
|||||||
+282
@@ -0,0 +1,282 @@
|
|||||||
|
package com.renkang.emergency.controller;
|
||||||
|
|
||||||
|
import com.renkang.emergency.bean.response.*;
|
||||||
|
import com.renkang.emergency.service.IFakerDataService;
|
||||||
|
import lombok.extern.slf4j.Slf4j;
|
||||||
|
import org.jeecg.common.api.dto.*;
|
||||||
|
import org.jeecg.common.api.vo.Result;
|
||||||
|
import org.springframework.beans.factory.annotation.Autowired;
|
||||||
|
import org.springframework.validation.annotation.Validated;
|
||||||
|
import org.springframework.web.bind.annotation.*;
|
||||||
|
|
||||||
|
import javax.validation.Valid;
|
||||||
|
import java.util.List;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 小屋大屏造假数据controller
|
||||||
|
*
|
||||||
|
* @author Junqiang Zhu
|
||||||
|
*/
|
||||||
|
@RestController
|
||||||
|
@RequestMapping("/emergency/fakerData")
|
||||||
|
@Slf4j
|
||||||
|
@Validated
|
||||||
|
public class FakerDataController {
|
||||||
|
@Autowired
|
||||||
|
private IFakerDataService fakerDataService;
|
||||||
|
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 设置展示假数据开关
|
||||||
|
*
|
||||||
|
* @param enable 开关
|
||||||
|
* @return success
|
||||||
|
*/
|
||||||
|
@PostMapping("fakerDataEnable")
|
||||||
|
public Result<String> fakerDataEnable(@RequestBody @Validated FakerDataEnable enable) {
|
||||||
|
fakerDataService.fakerDataEnable(enable);
|
||||||
|
return Result.OK("修改成功");
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 获取假数据
|
||||||
|
*
|
||||||
|
* @param module 模块
|
||||||
|
* @return data
|
||||||
|
*/
|
||||||
|
@PostMapping("getFakerData")
|
||||||
|
public Result<Object> getFakerData(@RequestParam Integer module,@RequestParam(required = false) String centerId) {
|
||||||
|
return Result.OK(fakerDataService.getFakerData(module,centerId));
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 获取所有开关状态
|
||||||
|
*/
|
||||||
|
@PostMapping("getFakerDataEnable")
|
||||||
|
public Result<?> getFakerDataEnable(@RequestParam(required = false) String centerId) {
|
||||||
|
return Result.OK(fakerDataService.getFakerDataEnable(centerId));
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 五类人群分布fakerData
|
||||||
|
*
|
||||||
|
* @param data data
|
||||||
|
* @return success
|
||||||
|
*/
|
||||||
|
@PostMapping("createGroupUserFakerData")
|
||||||
|
public Result<String> createGroupUserFakerData(@RequestBody @Validated GroupUserFakerData data) {
|
||||||
|
fakerDataService.createGroupUserFakerData(data);
|
||||||
|
return Result.OK("修改成功");
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 一线医疗工作fakerData
|
||||||
|
*
|
||||||
|
* @param data data
|
||||||
|
* @return success
|
||||||
|
*/
|
||||||
|
@PostMapping("createMedicalCenterFakerData")
|
||||||
|
public Result<String> createMedicalCenterFakerData(@RequestBody @Validated MedicalCenterFakerData data) {
|
||||||
|
fakerDataService.createMedicalCenterFakerData(data);
|
||||||
|
return Result.OK("修改成功");
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 员工营养监测fakerData
|
||||||
|
*
|
||||||
|
* @param data data
|
||||||
|
* @return success
|
||||||
|
*/
|
||||||
|
@PostMapping("createNutritionFakerData")
|
||||||
|
public Result<String> createNutritionFakerData(@RequestBody @Validated NutritionFakerData data) {
|
||||||
|
fakerDataService.createNutritionFakerData(data);
|
||||||
|
return Result.OK("修改成功");
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 健康水平fakerData
|
||||||
|
*
|
||||||
|
* @param data data
|
||||||
|
* @return success
|
||||||
|
*/
|
||||||
|
@PostMapping("createHealthLevelFakerData")
|
||||||
|
public Result<String> createHealthLevelFakerData(@RequestBody @Validated HealthLevelFakerData data) {
|
||||||
|
fakerDataService.createHealthLevelFakerData(data);
|
||||||
|
return Result.OK("修改成功");
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 心理干预效果fakerData
|
||||||
|
*
|
||||||
|
* @param data data
|
||||||
|
* @return success
|
||||||
|
*/
|
||||||
|
@PostMapping("createInterveneFakerData")
|
||||||
|
public Result<String> createInterveneFakerData(@RequestBody @Validated InterveneFakerData data) {
|
||||||
|
fakerDataService.createInterveneFakerData(data);
|
||||||
|
return Result.OK("修改成功");
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 服务详情fakerData
|
||||||
|
*
|
||||||
|
* @param data data
|
||||||
|
* @return success
|
||||||
|
*/
|
||||||
|
@PostMapping("createServiceFakerData")
|
||||||
|
public Result<String> createServiceFakerData(@RequestBody @Validated ServiceFakerData data) {
|
||||||
|
fakerDataService.createServiceFakerData(data);
|
||||||
|
return Result.OK("修改成功");
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 体检数据fakerData
|
||||||
|
*
|
||||||
|
* @param data data
|
||||||
|
* @return success
|
||||||
|
*/
|
||||||
|
@PostMapping("createMedicalFakerData")
|
||||||
|
public Result<String> createMedicalFakerData(@RequestBody @Validated MedicalFakerData data) {
|
||||||
|
fakerDataService.createMedicalFakerData(data);
|
||||||
|
return Result.OK("修改成功");
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 大病fakerData
|
||||||
|
*
|
||||||
|
* @param data data
|
||||||
|
* @return success
|
||||||
|
*/
|
||||||
|
@PostMapping("createBigIllFakerData")
|
||||||
|
public Result<String> createBigIllFakerData(@RequestBody @Validated BigIllFakerData data) {
|
||||||
|
fakerDataService.createBigIllFakerData(data);
|
||||||
|
return Result.OK("修改成功");
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 手表假数据
|
||||||
|
*
|
||||||
|
* @param data data
|
||||||
|
* @return success
|
||||||
|
*/
|
||||||
|
@PostMapping("createWatchFakerData")
|
||||||
|
public Result<String> createWatchFakerData(@RequestBody @Validated HouseWatchFakerData data) {
|
||||||
|
fakerDataService.createWatchFakerData(data);
|
||||||
|
return Result.OK("修改成功");
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 小屋运动 压力假数据
|
||||||
|
*
|
||||||
|
* @param data data
|
||||||
|
* @return success
|
||||||
|
*/
|
||||||
|
@PostMapping("createWatchStressFakerData")
|
||||||
|
public Result<String> createWatchStressFakerData(@RequestBody @Validated HouseWatchStressFakerData data) {
|
||||||
|
fakerDataService.createWatchStressFakerData(data);
|
||||||
|
return Result.OK("修改成功");
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 银川服务详情fakerData
|
||||||
|
*
|
||||||
|
* @param data data
|
||||||
|
* @return success
|
||||||
|
*/
|
||||||
|
@PostMapping("createYcServiceFakerData")
|
||||||
|
public Result<String> createYcServiceFakerData(@RequestBody @Validated ServiceFakerData data) {
|
||||||
|
fakerDataService.createYcServiceFakerData(data);
|
||||||
|
return Result.OK("修改成功");
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 银川体检数据fakerData
|
||||||
|
*
|
||||||
|
* @param data data
|
||||||
|
* @return success
|
||||||
|
*/
|
||||||
|
@PostMapping("createYcMedicalFakerData")
|
||||||
|
public Result<String> createYcMedicalFakerData(@RequestBody @Validated MedicalFakerData data) {
|
||||||
|
fakerDataService.createYcMedicalFakerData(data);
|
||||||
|
return Result.OK("修改成功");
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 银川一线医疗点数据fakerData
|
||||||
|
*
|
||||||
|
* @param data data
|
||||||
|
* @return success
|
||||||
|
*/
|
||||||
|
@PostMapping("createYcMedicalCenterFakerData")
|
||||||
|
public Result<String> createYcMedicalCenterFakerData(@RequestBody @Valid List<YcMedicalCenterFakerData> data,
|
||||||
|
@RequestParam(required = false) String centerId) {
|
||||||
|
fakerDataService.createYcMedicalCenterFakerData(data,centerId);
|
||||||
|
return Result.OK("修改成功");
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 银川员工健康状况fakerData
|
||||||
|
*
|
||||||
|
* @param data data
|
||||||
|
* @return success
|
||||||
|
*/
|
||||||
|
@PostMapping("createYcUserHealthFakerData")
|
||||||
|
public Result<String> createYcUserHealthFakerData(@RequestBody @Validated YcUserHealthFakerData data) {
|
||||||
|
fakerDataService.createYcUserHealthFakerData(data);
|
||||||
|
return Result.OK("修改成功");
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 新疆大屏 主诉分类
|
||||||
|
* @param data data
|
||||||
|
* @return success
|
||||||
|
*/
|
||||||
|
@PostMapping("createXjDemandTypeFakerData")
|
||||||
|
public Result<String> createXjDemandTypeFakerData(@RequestBody @Validated XjDemandTypeFakerData data) {
|
||||||
|
fakerDataService.createXjDemandTypeFakerData(data);
|
||||||
|
return Result.OK("修改成功");
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 新疆大屏 体检人数
|
||||||
|
* @param data data
|
||||||
|
* @return success
|
||||||
|
*/
|
||||||
|
@PostMapping("createXjMedicalCountFakerData")
|
||||||
|
public Result<String> createXjMedicalCountFakerData(@RequestBody @Validated List<XjMedicalCountFakerData> data,
|
||||||
|
@RequestParam(required = false) String centerId) {
|
||||||
|
fakerDataService.createXjMedicalCountFakerData(data,centerId);
|
||||||
|
return Result.OK("修改成功");
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 新疆大屏 健康打卡人数
|
||||||
|
* @param data data
|
||||||
|
* @return success
|
||||||
|
*/
|
||||||
|
@PostMapping("createXjHealthSignCountFakerData")
|
||||||
|
public Result<String> createXjHealthSignCountFakerData(@RequestBody @Validated XjHealthSignFakerData data) {
|
||||||
|
fakerDataService.createXjHealthSignCountFakerData(data);
|
||||||
|
return Result.OK("修改成功");
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 新疆大屏 体检数据
|
||||||
|
* @param data data
|
||||||
|
* @return success
|
||||||
|
*/
|
||||||
|
@PostMapping("createXjMedicalDataFakerData")
|
||||||
|
public Result<String> createXjMedicalDataFakerData(@RequestBody @Validated XjMedicalDataFakerData data) {
|
||||||
|
fakerDataService.createXjMedicalDataFakerData(data);
|
||||||
|
return Result.OK("修改成功");
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
||||||
+23
@@ -0,0 +1,23 @@
|
|||||||
|
package com.renkang.emergency.controller;
|
||||||
|
|
||||||
|
import com.renkang.emergency.entity.EmergencyHealthRoom;
|
||||||
|
import com.renkang.emergency.service.IEmergencyHealthRoomService;
|
||||||
|
import io.swagger.v3.oas.annotations.tags.Tag;
|
||||||
|
import lombok.extern.slf4j.Slf4j;
|
||||||
|
import org.jeecg.common.system.base.controller.JeecgController;
|
||||||
|
import org.springframework.web.bind.annotation.RequestMapping;
|
||||||
|
import org.springframework.web.bind.annotation.RestController;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* @Description: HealthRoom
|
||||||
|
* @Author: wang hao
|
||||||
|
* @Date: 2025-07-03
|
||||||
|
* @Version: V1.0
|
||||||
|
*/
|
||||||
|
@Tag(name = "health_room")
|
||||||
|
@RestController
|
||||||
|
@RequestMapping("/emergency/healthRoom")
|
||||||
|
@Slf4j
|
||||||
|
public class HealthRoomController extends JeecgController<EmergencyHealthRoom, IEmergencyHealthRoomService> {
|
||||||
|
|
||||||
|
}
|
||||||
-76
@@ -1,76 +0,0 @@
|
|||||||
package com.renkang.emergency.controller;
|
|
||||||
|
|
||||||
import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
|
|
||||||
import com.renkang.emergency.entity.TblUserHelp;
|
|
||||||
import com.renkang.emergency.entity.dto.*;
|
|
||||||
import com.renkang.emergency.service.ITbUserHelpMacService;
|
|
||||||
import com.renkang.emergency.service.ITblAmbulanceGpsService;
|
|
||||||
import com.renkang.emergency.service.YcLargeScreenService;
|
|
||||||
import io.swagger.v3.oas.annotations.Operation;
|
|
||||||
import io.swagger.v3.oas.annotations.Parameter;
|
|
||||||
import org.jeecg.common.api.dto.YcMedicalCenterFakerData;
|
|
||||||
import org.jeecg.common.api.dto.YcUserHealthFakerData;
|
|
||||||
import org.jeecg.common.api.vo.Result;
|
|
||||||
import org.springframework.beans.factory.annotation.Autowired;
|
|
||||||
import org.springframework.web.bind.annotation.*;
|
|
||||||
|
|
||||||
import javax.annotation.Resource;
|
|
||||||
import java.util.List;
|
|
||||||
|
|
||||||
@RestController
|
|
||||||
@RequestMapping("/emergency/LargeScreenNew")
|
|
||||||
public class LargeScreenNewController {
|
|
||||||
@Resource
|
|
||||||
private ITbUserHelpMacService tbUserHelpMacService;
|
|
||||||
@Resource
|
|
||||||
private YcLargeScreenService ycLargeScreenService;
|
|
||||||
@Resource
|
|
||||||
private ITblAmbulanceGpsService tblAmbulanceGpsService;
|
|
||||||
|
|
||||||
/**
|
|
||||||
* 服务详情数据-24.09.19 新版大屏接口
|
|
||||||
*/
|
|
||||||
@PostMapping("/statisticsNew")
|
|
||||||
@Operation(summary = "服务详情数据", description = "服务详情数据")
|
|
||||||
public Result<?> statisticsNew(@RequestBody StatisticsDTO dto) {
|
|
||||||
return Result.OK(tbUserHelpMacService.statisticsNew(dto));
|
|
||||||
}
|
|
||||||
|
|
||||||
/**
|
|
||||||
* 获取云坐席列表数据-24.09.19 新版大屏接口
|
|
||||||
*/
|
|
||||||
@PostMapping("/phoneListNew")
|
|
||||||
@Operation(summary = "获取云坐席列表数据", description = "获取云坐席列表数据")
|
|
||||||
public Result<?> getPhoneListNew(@RequestBody PhoneListDTO dto) {
|
|
||||||
return Result.ok(tbUserHelpMacService.getPhoneListNew(dto));
|
|
||||||
}
|
|
||||||
|
|
||||||
/**
|
|
||||||
* 一线医疗点每日工作动态-24.09.19 新版大屏接口
|
|
||||||
*/
|
|
||||||
@PostMapping("/medicalCenterNew")
|
|
||||||
@Operation(summary = "一线医疗点每日工作动态", description = "一线医疗点每日工作动态")
|
|
||||||
public Result<List<YcMedicalCenterFakerData>> medicalCenterNew(@RequestBody MedicalCenterDTO dto) {
|
|
||||||
return Result.ok(ycLargeScreenService.medicalCenterNew(dto));
|
|
||||||
}
|
|
||||||
|
|
||||||
/**
|
|
||||||
* 员工队伍健康状况数据-24.09.19 新版大屏接口
|
|
||||||
*/
|
|
||||||
@PostMapping("/userHealthCenterNew")
|
|
||||||
@Operation(summary = "员工队伍健康状况数据", description = "员工队伍健康状况数据")
|
|
||||||
public Result<YcUserHealthFakerData> userHealthCenterNew(@RequestBody UserHealthCenterDTO dto) {
|
|
||||||
return Result.ok(ycLargeScreenService.userHealthCenterNew(dto));
|
|
||||||
}
|
|
||||||
|
|
||||||
/**
|
|
||||||
* 获取所有资源-24.09.19 新版大屏接口
|
|
||||||
*/
|
|
||||||
@PostMapping("/getAllListNew")
|
|
||||||
@Operation(summary = "获取所有资源", description = "获取所有资源")
|
|
||||||
public Result<?> getAllListNew(@RequestBody ResourcesAllDTO dto) {
|
|
||||||
return Result.OK(tblAmbulanceGpsService.getAllListNew(dto));
|
|
||||||
}
|
|
||||||
|
|
||||||
|
|
||||||
}
|
|
||||||
+4
-2
@@ -26,8 +26,10 @@ public class TblHelpCenterController {
|
|||||||
|
|
||||||
@GetMapping("/sicknessTypeStatistic")
|
@GetMapping("/sicknessTypeStatistic")
|
||||||
@Operation(summary = "主诉分类统计", description = "主诉分类统计")
|
@Operation(summary = "主诉分类统计", description = "主诉分类统计")
|
||||||
public Result<?> sicknessTypeStatistic(@Parameter(description = "0:全部 1:女,2:男") @RequestParam(required = false) String sex, @Parameter(description = "部门id") @RequestParam(required = false) String depart) {
|
public Result<?> sicknessTypeStatistic(@Parameter(description = "0:全部 1:女,2:男") @RequestParam(required = false) String sex,
|
||||||
return Result.OK(tbHelpCenterService.sicknessTypeStatistic(sex,depart));
|
@Parameter(description = "部门id") @RequestParam(required = false) String depart,
|
||||||
|
@Parameter(description = "应急中心id",required = false) String centerId) {
|
||||||
|
return Result.OK(tbHelpCenterService.sicknessTypeStatistic(sex,depart,centerId));
|
||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|||||||
+155
@@ -0,0 +1,155 @@
|
|||||||
|
package com.renkang.emergency.largeScreen.controller;
|
||||||
|
|
||||||
|
import com.baomidou.mybatisplus.core.metadata.IPage;
|
||||||
|
import com.renkang.emergency.entity.dto.*;
|
||||||
|
import com.renkang.emergency.largeScreen.entity.dto.*;
|
||||||
|
import com.renkang.emergency.largeScreen.entity.vo.*;
|
||||||
|
import com.renkang.emergency.largeScreen.service.ILargeScreenService;
|
||||||
|
import com.renkang.emergency.service.ITbUserHelpMacService;
|
||||||
|
import com.renkang.emergency.service.ITblAmbulanceGpsService;
|
||||||
|
import com.renkang.emergency.service.YcLargeScreenService;
|
||||||
|
import io.swagger.v3.oas.annotations.Operation;
|
||||||
|
import io.swagger.v3.oas.annotations.tags.Tag;
|
||||||
|
import lombok.RequiredArgsConstructor;
|
||||||
|
import lombok.extern.slf4j.Slf4j;
|
||||||
|
import org.jeecg.common.api.dto.YcMedicalCenterFakerData;
|
||||||
|
import org.jeecg.common.api.dto.YcUserHealthFakerData;
|
||||||
|
import org.jeecg.common.api.vo.Result;
|
||||||
|
import org.springframework.web.bind.annotation.*;
|
||||||
|
|
||||||
|
import java.util.List;
|
||||||
|
|
||||||
|
@Tag(name = "大屏/主屏")
|
||||||
|
@RestController
|
||||||
|
@RequestMapping("/emergency/LargeScreenNew")
|
||||||
|
@RequiredArgsConstructor
|
||||||
|
@Slf4j
|
||||||
|
public class LargeScreenNewController {
|
||||||
|
|
||||||
|
private final ITbUserHelpMacService tbUserHelpMacService;
|
||||||
|
private final YcLargeScreenService ycLargeScreenService;
|
||||||
|
private final ITblAmbulanceGpsService tblAmbulanceGpsService;
|
||||||
|
private final ILargeScreenService largeScreenService;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 获取地图
|
||||||
|
* @param type 1:油田医院 2:健康小屋 5:救护车 不传则全部
|
||||||
|
* @return
|
||||||
|
*/
|
||||||
|
@GetMapping("/map")
|
||||||
|
public Result<List<LargeScreenMap>> map(@RequestParam(name = "type",required = false) String type) {
|
||||||
|
return Result.ok(largeScreenService.map(type));
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 服务详情数据-24.09.19 新版大屏接口
|
||||||
|
*/
|
||||||
|
@PostMapping("/statisticsNew")
|
||||||
|
@Operation(summary = "服务详情数据", description = "服务详情数据")
|
||||||
|
public Result<?> statisticsNew(@RequestBody StatisticsDTO dto) {
|
||||||
|
return Result.OK(tbUserHelpMacService.statisticsNew(dto));
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 获取云坐席列表数据-24.09.19 新版大屏接口
|
||||||
|
*/
|
||||||
|
@PostMapping("/phoneListNew")
|
||||||
|
@Operation(summary = "获取云坐席列表数据", description = "获取云坐席列表数据")
|
||||||
|
public Result<?> getPhoneListNew(@RequestBody PhoneListDTO dto) {
|
||||||
|
return Result.ok(tbUserHelpMacService.getPhoneListNew(dto));
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 一线医疗点每日工作动态-24.09.19 新版大屏接口
|
||||||
|
*/
|
||||||
|
@PostMapping("/medicalCenterNew")
|
||||||
|
@Operation(summary = "一线医疗点每日工作动态", description = "一线医疗点每日工作动态")
|
||||||
|
public Result<List<YcMedicalCenterFakerData>> medicalCenterNew(@RequestBody MedicalCenterDTO dto) {
|
||||||
|
return Result.ok(ycLargeScreenService.medicalCenterNew(dto));
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 员工队伍健康状况数据-24.09.19 新版大屏接口
|
||||||
|
*/
|
||||||
|
@PostMapping("/userHealthCenterNew")
|
||||||
|
@Operation(summary = "员工队伍健康状况数据", description = "员工队伍健康状况数据")
|
||||||
|
public Result<YcUserHealthFakerData> userHealthCenterNew(@RequestBody UserHealthCenterDTO dto) {
|
||||||
|
return Result.ok(ycLargeScreenService.userHealthCenterNew(dto));
|
||||||
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 获取所有资源-24.09.19 新版大屏接口
|
||||||
|
*/
|
||||||
|
@PostMapping("/getAllListNew")
|
||||||
|
@Operation(summary = "获取所有资源", description = "获取所有资源")
|
||||||
|
public Result<?> getAllListNew(@RequestBody ResourcesAllDTO dto) {
|
||||||
|
return Result.OK(tblAmbulanceGpsService.getAllListNew(dto));
|
||||||
|
}
|
||||||
|
|
||||||
|
@PostMapping("/healthRoomBase")
|
||||||
|
@Operation(summary = "健康小屋基础数据", description = "健康小屋基础数据")
|
||||||
|
public Result<List<HealthRoomBaseVO>> healthRoomBase(@RequestBody HealthRoomBaseDTO dto){
|
||||||
|
return Result.ok(largeScreenService.healthRoomBase(dto));
|
||||||
|
}
|
||||||
|
|
||||||
|
@PostMapping("/healthRoomDetail")
|
||||||
|
@Operation(summary = "健康小屋详情", description = "健康小屋详情")
|
||||||
|
public Result<IPage<HealthRoomVO>> healthRoomDetail(@RequestBody HealthRoomDTO dto){
|
||||||
|
return Result.ok(largeScreenService.healthRoomDetail(dto));
|
||||||
|
}
|
||||||
|
|
||||||
|
@PostMapping("/medicalAbnormal")
|
||||||
|
@Operation(summary = "体检异常数据详情列表", description = "体检异常数据详情列表")
|
||||||
|
public Result<IPage<MedicalAbnormalVO>> medicalAbnormal(@RequestBody MedicalAbnormalDTO dto){
|
||||||
|
return Result.ok(largeScreenService.medicalAbnormal(dto));
|
||||||
|
}
|
||||||
|
|
||||||
|
@PostMapping("/healthWeightLoss")
|
||||||
|
@Operation(summary = "健康打卡减重详情列表", description = "健康打卡减重详情列表")
|
||||||
|
public Result<IPage<HealthWeightLossVO>> healthWeightLoss(@RequestBody HealthWeightLossDTO dto){
|
||||||
|
return Result.ok(largeScreenService.healthWeightLoss(dto));
|
||||||
|
}
|
||||||
|
|
||||||
|
@PostMapping("/healthBloodSugar")
|
||||||
|
@Operation(summary = "健康打卡血糖详情列表", description = "健康打卡血糖详情列表")
|
||||||
|
public Result<IPage<HealthBloodSugarVO>> healthBloodSugar(@RequestBody HealthBloodSugarDTO dto){
|
||||||
|
return Result.ok(largeScreenService.healthBloodSugar(dto));
|
||||||
|
}
|
||||||
|
|
||||||
|
@PostMapping("/healthBloodPressure")
|
||||||
|
@Operation(summary = "健康打卡血压详情列表", description = "健康打卡血压详情列表")
|
||||||
|
public Result<IPage<HealthBloodPressureVO>> healthBloodPressure(@RequestBody HealthBloodPressureDTO dto){
|
||||||
|
return Result.ok(largeScreenService.healthBloodPressure(dto));
|
||||||
|
}
|
||||||
|
|
||||||
|
@PostMapping("/medicalPeopleNumStatistics")
|
||||||
|
@Operation(summary = "体检人数统计", description = "体检人数统计")
|
||||||
|
public Result<List<MedicalPeopleNumStatisticsVO>> medicalPeopleNumStatistics(@RequestBody MedicalPeopleNumStatisticsDTO dto){
|
||||||
|
return Result.ok(largeScreenService.medicalPeopleNumStatistics(dto));
|
||||||
|
}
|
||||||
|
|
||||||
|
@PostMapping("/medicalAbnormalStatistics")
|
||||||
|
@Operation(summary = "体检异常数据统计", description = "体检异常数据统计")
|
||||||
|
public Result<MedicalAbnormalStatisticsVO> medicalAbnormalStatistics(@RequestBody MedicalAbnormalStatisticsDTO dto){
|
||||||
|
return Result.ok(largeScreenService.medicalAbnormalStatistics(dto));
|
||||||
|
}
|
||||||
|
|
||||||
|
@PostMapping("/healthSign")
|
||||||
|
@Operation(summary = "健康打卡数据", description = "健康打卡数据")
|
||||||
|
public Result<HealthSignVO> healthSign(@RequestBody HealthSignDTO dto){
|
||||||
|
return Result.ok(largeScreenService.healthSign(dto));
|
||||||
|
}
|
||||||
|
|
||||||
|
@GetMapping("/hospital")
|
||||||
|
@Operation(summary = "医院数据", description = "医院数据")
|
||||||
|
public Result<List<HospitalVO>> hospital(){
|
||||||
|
return Result.ok(largeScreenService.hospital());
|
||||||
|
}
|
||||||
|
|
||||||
|
@GetMapping("runTest")
|
||||||
|
@Operation(summary = "推假数据", description = "推假数据")
|
||||||
|
public void runTest(){
|
||||||
|
largeScreenService.runTest();
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
||||||
+58
@@ -0,0 +1,58 @@
|
|||||||
|
package com.renkang.emergency.largeScreen.entity.dto;
|
||||||
|
|
||||||
|
import com.fasterxml.jackson.annotation.JsonFormat;
|
||||||
|
import io.swagger.v3.oas.annotations.media.Schema;
|
||||||
|
import lombok.Data;
|
||||||
|
import org.springframework.format.annotation.DateTimeFormat;
|
||||||
|
|
||||||
|
import java.util.Date;
|
||||||
|
|
||||||
|
@Data
|
||||||
|
public class HealthBloodPressureDTO {
|
||||||
|
/**
|
||||||
|
* 单位名称
|
||||||
|
*/
|
||||||
|
@Schema(title = "单位名称")
|
||||||
|
private String departName;
|
||||||
|
/**
|
||||||
|
* 员工姓名
|
||||||
|
*/
|
||||||
|
@Schema(title = "员工姓名")
|
||||||
|
private String name;
|
||||||
|
/**
|
||||||
|
* 填报开始时间起
|
||||||
|
*/
|
||||||
|
@JsonFormat(pattern = "yyyy-MM-dd", timezone = "GMT+8")
|
||||||
|
@DateTimeFormat(pattern = "yyyy-MM-dd")
|
||||||
|
@Schema(title = "填报开始时间起")
|
||||||
|
private Date inputDateBegin;
|
||||||
|
/**
|
||||||
|
* 填报开始时间止
|
||||||
|
*/
|
||||||
|
@JsonFormat(pattern = "yyyy-MM-dd", timezone = "GMT+8")
|
||||||
|
@DateTimeFormat(pattern = "yyyy-MM-dd")
|
||||||
|
@Schema(title = "填报开始时间止")
|
||||||
|
private Date inputDateEnd;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 异常标记 0:正常/1:异常/2:全部
|
||||||
|
*/
|
||||||
|
@Schema(title = "异常标记 0:正常/1:异常/2:全部")
|
||||||
|
private String abFlag;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 页码 从1开始
|
||||||
|
*/
|
||||||
|
@Schema(title = "页码 从1开始")
|
||||||
|
private Integer pageNo;
|
||||||
|
/**
|
||||||
|
* 每页数量
|
||||||
|
*/
|
||||||
|
@Schema(title = "每页数量")
|
||||||
|
private Integer pageSize;
|
||||||
|
|
||||||
|
public HealthBloodPressureDTO() {
|
||||||
|
this.pageNo = 1;
|
||||||
|
this.pageSize = 10;
|
||||||
|
}
|
||||||
|
}
|
||||||
+58
@@ -0,0 +1,58 @@
|
|||||||
|
package com.renkang.emergency.largeScreen.entity.dto;
|
||||||
|
|
||||||
|
import com.fasterxml.jackson.annotation.JsonFormat;
|
||||||
|
import io.swagger.v3.oas.annotations.media.Schema;
|
||||||
|
import lombok.Data;
|
||||||
|
import org.springframework.format.annotation.DateTimeFormat;
|
||||||
|
|
||||||
|
import java.util.Date;
|
||||||
|
|
||||||
|
@Data
|
||||||
|
public class HealthBloodSugarDTO {
|
||||||
|
/**
|
||||||
|
* 单位名称
|
||||||
|
*/
|
||||||
|
@Schema(title = "单位名称")
|
||||||
|
private String departName;
|
||||||
|
/**
|
||||||
|
* 员工姓名
|
||||||
|
*/
|
||||||
|
@Schema(title = "员工姓名")
|
||||||
|
private String name;
|
||||||
|
/**
|
||||||
|
* 填报开始时间起
|
||||||
|
*/
|
||||||
|
@JsonFormat(pattern = "yyyy-MM-dd", timezone = "GMT+8")
|
||||||
|
@DateTimeFormat(pattern = "yyyy-MM-dd")
|
||||||
|
@Schema(title = "填报开始时间起")
|
||||||
|
private Date inputDateBegin;
|
||||||
|
/**
|
||||||
|
* 填报开始时间止
|
||||||
|
*/
|
||||||
|
@JsonFormat(pattern = "yyyy-MM-dd", timezone = "GMT+8")
|
||||||
|
@DateTimeFormat(pattern = "yyyy-MM-dd")
|
||||||
|
@Schema(title = "填报开始时间止")
|
||||||
|
private Date inputDateEnd;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 异常标记 0:正常/1:异常/2:全部
|
||||||
|
*/
|
||||||
|
@Schema(title = "异常标记 0:正常/1:异常/2:全部")
|
||||||
|
private String abFlag;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 页码 从1开始
|
||||||
|
*/
|
||||||
|
@Schema(title = "页码 从1开始")
|
||||||
|
private Integer pageNo;
|
||||||
|
/**
|
||||||
|
* 每页数量
|
||||||
|
*/
|
||||||
|
@Schema(title = "每页数量")
|
||||||
|
private Integer pageSize;
|
||||||
|
|
||||||
|
public HealthBloodSugarDTO() {
|
||||||
|
this.pageNo = 1;
|
||||||
|
this.pageSize = 10;
|
||||||
|
}
|
||||||
|
}
|
||||||
+33
@@ -0,0 +1,33 @@
|
|||||||
|
package com.renkang.emergency.largeScreen.entity.dto;
|
||||||
|
|
||||||
|
import cn.hutool.core.date.DateUtil;
|
||||||
|
import com.fasterxml.jackson.annotation.JsonFormat;
|
||||||
|
import io.swagger.v3.oas.annotations.media.Schema;
|
||||||
|
import lombok.Data;
|
||||||
|
import org.springframework.format.annotation.DateTimeFormat;
|
||||||
|
|
||||||
|
import java.util.Date;
|
||||||
|
|
||||||
|
@Data
|
||||||
|
public class HealthRoomBaseDTO {
|
||||||
|
/**
|
||||||
|
* 检查日期起期 参数为空时,默认为今年第一天,如:2025-01-01
|
||||||
|
*/
|
||||||
|
@JsonFormat(pattern = "yyyy-MM-dd", timezone = "GMT+8")
|
||||||
|
@DateTimeFormat(pattern = "yyyy-MM-dd")
|
||||||
|
@Schema(title = "检查日期起期 参数为空时,默认为今年第一天,如:2025-01-01")
|
||||||
|
private Date checkInDateBegin;
|
||||||
|
/**
|
||||||
|
* 检查日期止期 参数为空时,默认为今天
|
||||||
|
*/
|
||||||
|
@JsonFormat(pattern = "yyyy-MM-dd", timezone = "GMT+8")
|
||||||
|
@DateTimeFormat(pattern = "yyyy-MM-dd")
|
||||||
|
@Schema(title = "检查日期止期 参数为空时,默认为今天")
|
||||||
|
private Date checkInDateEnd;
|
||||||
|
|
||||||
|
public HealthRoomBaseDTO() {
|
||||||
|
Date date = new Date();
|
||||||
|
this.checkInDateBegin = DateUtil.beginOfYear(date);
|
||||||
|
this.checkInDateEnd = DateUtil.endOfDay(date);
|
||||||
|
}
|
||||||
|
}
|
||||||
+74
@@ -0,0 +1,74 @@
|
|||||||
|
package com.renkang.emergency.largeScreen.entity.dto;
|
||||||
|
|
||||||
|
import cn.hutool.core.date.DateUtil;
|
||||||
|
import com.fasterxml.jackson.annotation.JsonFormat;
|
||||||
|
import io.swagger.v3.oas.annotations.media.Schema;
|
||||||
|
import lombok.Data;
|
||||||
|
import org.jeecg.common.aspect.annotation.Dict;
|
||||||
|
import org.springframework.format.annotation.DateTimeFormat;
|
||||||
|
|
||||||
|
import javax.validation.constraints.NotNull;
|
||||||
|
import java.util.Date;
|
||||||
|
|
||||||
|
@Data
|
||||||
|
public class HealthRoomDTO {
|
||||||
|
/**
|
||||||
|
* 健康小屋ID
|
||||||
|
*/
|
||||||
|
@Schema(title = "健康小屋ID")
|
||||||
|
@NotNull
|
||||||
|
private String healthRoomId;
|
||||||
|
/**
|
||||||
|
* 检查类型 11:BMI/21:收缩压/22:舒张压/31:血糖/41:低密度脂蛋白/42:总胆固醇/43:甘油三酯/51:尿酸/61:同型半胱氨酸 等等,缺失的可以继续加
|
||||||
|
*/
|
||||||
|
@Schema(title = "检查类型 11:BMI/21:收缩压/22:舒张压/31:血糖/41:低密度脂蛋白/42:总胆固醇/43:甘油三酯/51:尿酸/61:同型半胱氨酸 等等,缺失的可以继续加")
|
||||||
|
@Dict(dicCode = "xj_check_type")
|
||||||
|
private String checkType;
|
||||||
|
/**
|
||||||
|
* 单位名称
|
||||||
|
*/
|
||||||
|
@Schema(title = "单位名称")
|
||||||
|
private String departName;
|
||||||
|
/**
|
||||||
|
* 员工姓名
|
||||||
|
*/
|
||||||
|
@Schema(title = "员工姓名")
|
||||||
|
private String name;
|
||||||
|
/**
|
||||||
|
* 检查日期起期 参数为空时,默认为今年第一天,如:2025-01-01
|
||||||
|
*/
|
||||||
|
@JsonFormat(pattern = "yyyy-MM-dd", timezone = "GMT+8")
|
||||||
|
@DateTimeFormat(pattern = "yyyy-MM-dd")
|
||||||
|
@Schema(title = "检查日期起期 参数为空时,默认为今年第一天,如:2025-01-01")
|
||||||
|
private Date checkInDateBegin;
|
||||||
|
/**
|
||||||
|
* 检查日期止期 参数为空时,默认为今天
|
||||||
|
*/
|
||||||
|
@JsonFormat(pattern = "yyyy-MM-dd", timezone = "GMT+8")
|
||||||
|
@DateTimeFormat(pattern = "yyyy-MM-dd")
|
||||||
|
@Schema(title = "检查日期止期 参数为空时,默认为今天")
|
||||||
|
private Date checkInDateEnd;
|
||||||
|
/**
|
||||||
|
* 是否成功控降 是否成功空降,1:是/0.否
|
||||||
|
*/
|
||||||
|
@Schema(title = "是否成功控降 是否成功空降,1:是/0.否")
|
||||||
|
private String successFlag;
|
||||||
|
/**
|
||||||
|
* 页码 从1开始
|
||||||
|
*/
|
||||||
|
@Schema(title = "页码 从1开始")
|
||||||
|
private Integer pageNo;
|
||||||
|
/**
|
||||||
|
* 每页数量
|
||||||
|
*/
|
||||||
|
@Schema(title = "每页数量")
|
||||||
|
private Integer pageSize;
|
||||||
|
|
||||||
|
public HealthRoomDTO() {
|
||||||
|
Date date = new Date();
|
||||||
|
this.checkInDateBegin = DateUtil.beginOfYear(date);
|
||||||
|
this.checkInDateEnd = DateUtil.endOfDay(date);
|
||||||
|
this.pageNo = 1;
|
||||||
|
this.pageSize = 10;
|
||||||
|
}
|
||||||
|
}
|
||||||
+41
@@ -0,0 +1,41 @@
|
|||||||
|
package com.renkang.emergency.largeScreen.entity.dto;
|
||||||
|
|
||||||
|
import cn.hutool.core.date.DateUtil;
|
||||||
|
import com.fasterxml.jackson.annotation.JsonFormat;
|
||||||
|
import io.swagger.v3.oas.annotations.media.Schema;
|
||||||
|
import lombok.Data;
|
||||||
|
import org.springframework.format.annotation.DateTimeFormat;
|
||||||
|
|
||||||
|
import java.util.Date;
|
||||||
|
|
||||||
|
@Data
|
||||||
|
public class HealthSignDTO {
|
||||||
|
/**
|
||||||
|
* 数据类型 1.减重/2.血压/3.血糖 默认空则全部
|
||||||
|
*/
|
||||||
|
@Schema(title = "数据类型 1.减重/2.血压/3.血糖 默认空则全部")
|
||||||
|
private String dataType;
|
||||||
|
/**
|
||||||
|
* 填报开始时间起 参数为空时,默认为当天
|
||||||
|
*/
|
||||||
|
@JsonFormat(pattern = "yyyy-MM-dd", timezone = "GMT+8")
|
||||||
|
@DateTimeFormat(pattern = "yyyy-MM-dd")
|
||||||
|
@Schema(title = "填报开始时间起 参数为空时,默认为当天")
|
||||||
|
private Date inputDateBegin;
|
||||||
|
/**
|
||||||
|
* 填报开始时间止 参数为空时,默认为当天
|
||||||
|
*/
|
||||||
|
@JsonFormat(pattern = "yyyy-MM-dd", timezone = "GMT+8")
|
||||||
|
@DateTimeFormat(pattern = "yyyy-MM-dd")
|
||||||
|
@Schema(title = "填报开始时间止 参数为空时,默认为当天")
|
||||||
|
private Date inputDateEnd;
|
||||||
|
|
||||||
|
private String centerId;
|
||||||
|
|
||||||
|
public HealthSignDTO() {
|
||||||
|
this.dataType = "";
|
||||||
|
Date date = new Date();
|
||||||
|
this.inputDateBegin = DateUtil.beginOfDay(date);
|
||||||
|
this.inputDateEnd = DateUtil.endOfDay(date);
|
||||||
|
}
|
||||||
|
}
|
||||||
+58
@@ -0,0 +1,58 @@
|
|||||||
|
package com.renkang.emergency.largeScreen.entity.dto;
|
||||||
|
|
||||||
|
import com.fasterxml.jackson.annotation.JsonFormat;
|
||||||
|
import io.swagger.v3.oas.annotations.media.Schema;
|
||||||
|
import lombok.Data;
|
||||||
|
import org.springframework.format.annotation.DateTimeFormat;
|
||||||
|
|
||||||
|
import java.util.Date;
|
||||||
|
|
||||||
|
@Data
|
||||||
|
public class HealthWeightLossDTO {
|
||||||
|
/**
|
||||||
|
* 单位名称
|
||||||
|
*/
|
||||||
|
@Schema(title = "单位名称")
|
||||||
|
private String departName;
|
||||||
|
/**
|
||||||
|
* 员工姓名
|
||||||
|
*/
|
||||||
|
@Schema(title = "员工姓名")
|
||||||
|
private String name;
|
||||||
|
/**
|
||||||
|
* 填报开始时间起
|
||||||
|
*/
|
||||||
|
@JsonFormat(pattern = "yyyy-MM-dd", timezone = "GMT+8")
|
||||||
|
@DateTimeFormat(pattern = "yyyy-MM-dd")
|
||||||
|
@Schema(title = "填报开始时间起")
|
||||||
|
private Date inputDateBegin;
|
||||||
|
/**
|
||||||
|
* 填报开始时间止
|
||||||
|
*/
|
||||||
|
@JsonFormat(pattern = "yyyy-MM-dd", timezone = "GMT+8")
|
||||||
|
@DateTimeFormat(pattern = "yyyy-MM-dd")
|
||||||
|
@Schema(title = "填报开始时间止")
|
||||||
|
private Date inputDateEnd;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 异常标记
|
||||||
|
*/
|
||||||
|
@Schema(title = "异常标记")
|
||||||
|
private String abFlag;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 页码 从1开始
|
||||||
|
*/
|
||||||
|
@Schema(title = "页码 从1开始")
|
||||||
|
private Integer pageNo;
|
||||||
|
/**
|
||||||
|
* 每页数量
|
||||||
|
*/
|
||||||
|
@Schema(title = "每页数量")
|
||||||
|
private Integer pageSize;
|
||||||
|
|
||||||
|
public HealthWeightLossDTO() {
|
||||||
|
this.pageNo = 1;
|
||||||
|
this.pageSize = 10;
|
||||||
|
}
|
||||||
|
}
|
||||||
+60
@@ -0,0 +1,60 @@
|
|||||||
|
package com.renkang.emergency.largeScreen.entity.dto;
|
||||||
|
|
||||||
|
import cn.hutool.core.date.DateUtil;
|
||||||
|
import com.fasterxml.jackson.annotation.JsonFormat;
|
||||||
|
import io.swagger.v3.oas.annotations.media.Schema;
|
||||||
|
import lombok.Data;
|
||||||
|
import org.springframework.format.annotation.DateTimeFormat;
|
||||||
|
|
||||||
|
import javax.validation.constraints.NotNull;
|
||||||
|
import java.util.Date;
|
||||||
|
|
||||||
|
@Data
|
||||||
|
public class MedicalAbnormalDTO {
|
||||||
|
/**
|
||||||
|
* 单位名称
|
||||||
|
*/
|
||||||
|
private String departName;
|
||||||
|
/**
|
||||||
|
* 员工姓名
|
||||||
|
*/
|
||||||
|
private String name;
|
||||||
|
/**
|
||||||
|
* 检查日期起期 参数为空时,默认为今年第一天,如:2025-01-01
|
||||||
|
*/
|
||||||
|
@JsonFormat(pattern = "yyyy-MM-dd", timezone = "GMT+8")
|
||||||
|
@DateTimeFormat(pattern = "yyyy-MM-dd")
|
||||||
|
@Schema(title = "检查日期起期 参数为空时,默认为今年第一天,如:2025-01-01")
|
||||||
|
private Date checkInDateBegin;
|
||||||
|
/**
|
||||||
|
* 检查日期止期 参数为空时,默认为今天
|
||||||
|
*/
|
||||||
|
@JsonFormat(pattern = "yyyy-MM-dd", timezone = "GMT+8")
|
||||||
|
@DateTimeFormat(pattern = "yyyy-MM-dd")
|
||||||
|
@Schema(title = "检查日期止期 参数为空时,默认为今天")
|
||||||
|
private Date checkInDateEnd;
|
||||||
|
/**
|
||||||
|
* 查询类型 1:心血管异常/2:脑血管异常/3:冠脉CT异常
|
||||||
|
*/
|
||||||
|
@Schema(title = "查询类型 1:心血管异常/2:脑血管异常/3:冠脉CT异常")
|
||||||
|
@NotNull
|
||||||
|
private String queryType;
|
||||||
|
/**
|
||||||
|
* 页码 从1开始
|
||||||
|
*/
|
||||||
|
@Schema(title = "页码 从1开始")
|
||||||
|
private Integer pageNo;
|
||||||
|
/**
|
||||||
|
* 每页数量
|
||||||
|
*/
|
||||||
|
@Schema(title = "每页数量")
|
||||||
|
private Integer pageSize;
|
||||||
|
|
||||||
|
public MedicalAbnormalDTO() {
|
||||||
|
Date date = new Date();
|
||||||
|
this.checkInDateBegin = DateUtil.beginOfYear(date);
|
||||||
|
this.checkInDateEnd = DateUtil.endOfDay(date);
|
||||||
|
this.pageNo = 1;
|
||||||
|
this.pageSize = 10;
|
||||||
|
}
|
||||||
|
}
|
||||||
+34
@@ -0,0 +1,34 @@
|
|||||||
|
package com.renkang.emergency.largeScreen.entity.dto;
|
||||||
|
|
||||||
|
import cn.hutool.core.date.DateUtil;
|
||||||
|
import com.fasterxml.jackson.annotation.JsonFormat;
|
||||||
|
import io.swagger.v3.oas.annotations.media.Schema;
|
||||||
|
import lombok.Data;
|
||||||
|
import org.springframework.format.annotation.DateTimeFormat;
|
||||||
|
|
||||||
|
import java.util.Date;
|
||||||
|
|
||||||
|
@Data
|
||||||
|
public class MedicalAbnormalStatisticsDTO {
|
||||||
|
private String centerId;
|
||||||
|
/**
|
||||||
|
* 检查日期起期 参数为空时,默认为今年第一天
|
||||||
|
*/
|
||||||
|
@JsonFormat(pattern = "yyyy-MM-dd", timezone = "GMT+8")
|
||||||
|
@DateTimeFormat(pattern = "yyyy-MM-dd")
|
||||||
|
@Schema(title = "检查日期起期 参数为空时,默认为今年第一天")
|
||||||
|
private Date checkInDateBegin;
|
||||||
|
/**
|
||||||
|
* 检查日期止期 参数为空时,默认为今天
|
||||||
|
*/
|
||||||
|
@JsonFormat(pattern = "yyyy-MM-dd", timezone = "GMT+8")
|
||||||
|
@DateTimeFormat(pattern = "yyyy-MM-dd")
|
||||||
|
@Schema(title = "检查日期止期 参数为空时,默认为今天")
|
||||||
|
private Date checkInDateEnd;
|
||||||
|
|
||||||
|
public MedicalAbnormalStatisticsDTO() {
|
||||||
|
Date date = new Date();
|
||||||
|
this.checkInDateBegin = DateUtil.beginOfYear(date);
|
||||||
|
this.checkInDateEnd = DateUtil.endOfDay(date);
|
||||||
|
}
|
||||||
|
}
|
||||||
+16
@@ -0,0 +1,16 @@
|
|||||||
|
package com.renkang.emergency.largeScreen.entity.dto;
|
||||||
|
|
||||||
|
import cn.hutool.core.date.DateUtil;
|
||||||
|
import lombok.Data;
|
||||||
|
|
||||||
|
import java.util.Date;
|
||||||
|
|
||||||
|
@Data
|
||||||
|
public class MedicalPeopleNumStatisticsDTO {
|
||||||
|
private Integer medicalYear;
|
||||||
|
private String centerId;
|
||||||
|
|
||||||
|
public MedicalPeopleNumStatisticsDTO() {
|
||||||
|
this.medicalYear = DateUtil.year(new Date());
|
||||||
|
}
|
||||||
|
}
|
||||||
+62
@@ -0,0 +1,62 @@
|
|||||||
|
package com.renkang.emergency.largeScreen.entity.vo;
|
||||||
|
|
||||||
|
import com.fasterxml.jackson.annotation.JsonFormat;
|
||||||
|
import io.swagger.v3.oas.annotations.media.Schema;
|
||||||
|
import lombok.Data;
|
||||||
|
import org.jeecg.common.aspect.annotation.Dict;
|
||||||
|
import org.springframework.format.annotation.DateTimeFormat;
|
||||||
|
|
||||||
|
import java.util.Date;
|
||||||
|
|
||||||
|
@Data
|
||||||
|
public class HealthBloodPressureVO {
|
||||||
|
/**
|
||||||
|
* 单位
|
||||||
|
*/
|
||||||
|
@Schema(title = "单位")
|
||||||
|
private String departName;
|
||||||
|
/**
|
||||||
|
* 姓名
|
||||||
|
*/
|
||||||
|
@Schema(title = "姓名")
|
||||||
|
private String name;
|
||||||
|
/**
|
||||||
|
* 性别
|
||||||
|
*/
|
||||||
|
@Schema(title = "性别")
|
||||||
|
@Dict(dicCode = "sex2")
|
||||||
|
private Integer sex;
|
||||||
|
/**
|
||||||
|
* 年龄
|
||||||
|
*/
|
||||||
|
@Schema(title = "年龄")
|
||||||
|
private Integer age;
|
||||||
|
/**
|
||||||
|
* 收缩压
|
||||||
|
*/
|
||||||
|
@Schema(title = "收缩压")
|
||||||
|
private String sbp;
|
||||||
|
/**
|
||||||
|
* 收缩压是否异常 1:是/0:否
|
||||||
|
*/
|
||||||
|
@Schema(title = "收缩压是否异常 1:是/0:否")
|
||||||
|
private String sbpFlag;
|
||||||
|
/**
|
||||||
|
* 舒张压
|
||||||
|
*/
|
||||||
|
@Schema(title = "舒张压")
|
||||||
|
private String dbp;
|
||||||
|
/**
|
||||||
|
* 舒张压是否异常 1:是/0:否
|
||||||
|
*/
|
||||||
|
@Schema(title = "舒张压是否异常 1:是/0:否")
|
||||||
|
private String dbpFlag;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 填报时间
|
||||||
|
*/
|
||||||
|
@JsonFormat(pattern = "yyyy-MM-dd", timezone = "GMT+8")
|
||||||
|
@DateTimeFormat(pattern = "yyyy-MM-dd")
|
||||||
|
@Schema(title = "填报时间")
|
||||||
|
private Date inputDate;
|
||||||
|
}
|
||||||
+57
@@ -0,0 +1,57 @@
|
|||||||
|
package com.renkang.emergency.largeScreen.entity.vo;
|
||||||
|
|
||||||
|
import com.fasterxml.jackson.annotation.JsonFormat;
|
||||||
|
import io.swagger.v3.oas.annotations.media.Schema;
|
||||||
|
import lombok.Data;
|
||||||
|
import org.jeecg.common.aspect.annotation.Dict;
|
||||||
|
import org.springframework.format.annotation.DateTimeFormat;
|
||||||
|
|
||||||
|
import java.util.Date;
|
||||||
|
|
||||||
|
@Data
|
||||||
|
public class HealthBloodSugarVO {
|
||||||
|
/**
|
||||||
|
* 单位
|
||||||
|
*/
|
||||||
|
@Schema(title = "单位")
|
||||||
|
private String departName;
|
||||||
|
/**
|
||||||
|
* 姓名
|
||||||
|
*/
|
||||||
|
@Schema(title = "姓名")
|
||||||
|
private String name;
|
||||||
|
/**
|
||||||
|
* 性别
|
||||||
|
*/
|
||||||
|
@Schema(title = "性别")
|
||||||
|
@Dict(dicCode = "sex2")
|
||||||
|
private Integer sex;
|
||||||
|
/**
|
||||||
|
* 年龄
|
||||||
|
*/
|
||||||
|
@Schema(title = "年龄")
|
||||||
|
private Integer age;
|
||||||
|
/**
|
||||||
|
* 血糖值
|
||||||
|
*/
|
||||||
|
@Schema(title = "血糖值")
|
||||||
|
private String bsVal;
|
||||||
|
/**
|
||||||
|
* 血糖是否异常 1:是/0:否
|
||||||
|
*/
|
||||||
|
@Schema(title = "血糖是否异常 1:是/0:否")
|
||||||
|
private String bmiFlag;
|
||||||
|
/**
|
||||||
|
* 腰围(CM)
|
||||||
|
*/
|
||||||
|
@Schema(title = "腰围(CM)")
|
||||||
|
private String waist;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 填报时间
|
||||||
|
*/
|
||||||
|
@JsonFormat(pattern = "yyyy-MM-dd", timezone = "GMT+8")
|
||||||
|
@DateTimeFormat(pattern = "yyyy-MM-dd")
|
||||||
|
@Schema(title = "填报时间")
|
||||||
|
private Date inputDate;
|
||||||
|
}
|
||||||
+24
@@ -0,0 +1,24 @@
|
|||||||
|
package com.renkang.emergency.largeScreen.entity.vo;
|
||||||
|
|
||||||
|
import com.fasterxml.jackson.annotation.JsonFormat;
|
||||||
|
import io.swagger.v3.oas.annotations.media.Schema;
|
||||||
|
import lombok.Data;
|
||||||
|
import org.springframework.format.annotation.DateTimeFormat;
|
||||||
|
|
||||||
|
import java.util.Date;
|
||||||
|
|
||||||
|
@Data
|
||||||
|
public class HealthRoomBaseVO {
|
||||||
|
private String id;
|
||||||
|
private String departName;
|
||||||
|
private String address;
|
||||||
|
private String lon;
|
||||||
|
private String lat;
|
||||||
|
/**
|
||||||
|
* 建设时间
|
||||||
|
*/
|
||||||
|
@JsonFormat(pattern = "yyyy-MM-dd", timezone = "GMT+8")
|
||||||
|
@DateTimeFormat(pattern = "yyyy-MM-dd")
|
||||||
|
@Schema(title = "建设时间")
|
||||||
|
private Date buildDate;
|
||||||
|
}
|
||||||
+55
@@ -0,0 +1,55 @@
|
|||||||
|
package com.renkang.emergency.largeScreen.entity.vo;
|
||||||
|
|
||||||
|
import io.swagger.v3.oas.annotations.media.Schema;
|
||||||
|
import lombok.Data;
|
||||||
|
import org.jeecg.common.aspect.annotation.Dict;
|
||||||
|
|
||||||
|
@Data
|
||||||
|
public class HealthRoomVO {
|
||||||
|
/**
|
||||||
|
* 单位
|
||||||
|
*/
|
||||||
|
@Schema(title = "单位")
|
||||||
|
private String departName;
|
||||||
|
/**
|
||||||
|
* 姓名
|
||||||
|
*/
|
||||||
|
@Schema(title = "姓名")
|
||||||
|
private String name;
|
||||||
|
/**
|
||||||
|
* 检查日期
|
||||||
|
*/
|
||||||
|
@Schema(title = "检查日期")
|
||||||
|
private String checkInDate;
|
||||||
|
/**
|
||||||
|
* 检查类型 11:BMI/21:收缩压/22:舒张压/31:血糖/41:低密度脂蛋白/42:总胆固醇/43:甘油三酯/51:尿酸/61:同型半胱氨酸 等等,缺失的可以继续加
|
||||||
|
*/
|
||||||
|
@Schema(title = "检查类型 11:BMI/21:收缩压/22:舒张压/31:血糖/41:低密度脂蛋白/42:总胆固醇/43:甘油三酯/51:尿酸/61:同型半胱氨酸 等等,缺失的可以继续加")
|
||||||
|
@Dict(dicCode = "xj_check_type")
|
||||||
|
private String checkType;
|
||||||
|
/**
|
||||||
|
* 去年体检值 前一年的体检值(初始值)
|
||||||
|
*/
|
||||||
|
@Schema(title = "去年体检值 前一年的体检值(初始值)")
|
||||||
|
private String lastVal;
|
||||||
|
/**
|
||||||
|
* 控降目标 一人一档(控降目标值)
|
||||||
|
*/
|
||||||
|
@Schema(title = "控降目标 一人一档(控降目标值")
|
||||||
|
private String goalVal;
|
||||||
|
/**
|
||||||
|
* 目前测量值 目前控降数值(可和健康打卡最新值一致)
|
||||||
|
*/
|
||||||
|
@Schema(title = "目前测量值 目前控降数值(可和健康打卡最新值一致)")
|
||||||
|
private String currentVal;
|
||||||
|
/**
|
||||||
|
* 控降差值 和控降目标对比
|
||||||
|
*/
|
||||||
|
@Schema(title = "控降差值 和控降目标对比")
|
||||||
|
private String compareVal;
|
||||||
|
/**
|
||||||
|
* 是否成功空降,1:是/0.否
|
||||||
|
*/
|
||||||
|
@Schema(title = "是否成功空降,1:是/0.否")
|
||||||
|
private String successFlag;
|
||||||
|
}
|
||||||
+23
@@ -0,0 +1,23 @@
|
|||||||
|
package com.renkang.emergency.largeScreen.entity.vo;
|
||||||
|
|
||||||
|
import io.swagger.v3.oas.annotations.media.Schema;
|
||||||
|
import lombok.Data;
|
||||||
|
|
||||||
|
@Data
|
||||||
|
public class HealthSignDataVO {
|
||||||
|
/**
|
||||||
|
* 数据类型 1.减重/2.血压/3.血糖
|
||||||
|
*/
|
||||||
|
@Schema(title = "数据类型 1.减重/2.血压/3.血糖")
|
||||||
|
private String dataType;
|
||||||
|
/**
|
||||||
|
* 打卡总人数
|
||||||
|
*/
|
||||||
|
@Schema(title = "打卡总人数")
|
||||||
|
private Integer totalCount;
|
||||||
|
/**
|
||||||
|
* 异常人数
|
||||||
|
*/
|
||||||
|
@Schema(title = "异常人数")
|
||||||
|
private Integer abCount;
|
||||||
|
}
|
||||||
+70
@@ -0,0 +1,70 @@
|
|||||||
|
package com.renkang.emergency.largeScreen.entity.vo;
|
||||||
|
|
||||||
|
import io.swagger.v3.oas.annotations.media.Schema;
|
||||||
|
import lombok.Data;
|
||||||
|
|
||||||
|
@Data
|
||||||
|
public class HealthSignVO {
|
||||||
|
/**
|
||||||
|
* 减重今日打卡人数
|
||||||
|
*/
|
||||||
|
@Schema(title = "减重今日打卡人数")
|
||||||
|
private Integer weightLossCountDay;
|
||||||
|
/**
|
||||||
|
* 减重本月打卡人数
|
||||||
|
*/
|
||||||
|
@Schema(title = "减重本月打卡人数")
|
||||||
|
private Integer weightLossCountMonth;
|
||||||
|
/**
|
||||||
|
* 减重今日异常人数
|
||||||
|
*/
|
||||||
|
@Schema(title = "减重今日异常人数")
|
||||||
|
private Integer weightLossAbnormalCountDay;
|
||||||
|
/**
|
||||||
|
* 减重本月异常人数
|
||||||
|
*/
|
||||||
|
@Schema(title = "减重本月异常人数")
|
||||||
|
private Integer weightLossAbnormalCountMonth;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 血糖今日打卡人数
|
||||||
|
*/
|
||||||
|
@Schema(title = "血糖今日打卡人数")
|
||||||
|
private Integer bloodSugarCountDay;
|
||||||
|
/**
|
||||||
|
* 血糖本月打卡人数
|
||||||
|
*/
|
||||||
|
@Schema(title = "血糖本月打卡人数")
|
||||||
|
private Integer bloodSugarCountMonth;
|
||||||
|
/**
|
||||||
|
* 血糖今日异常人数
|
||||||
|
*/
|
||||||
|
@Schema(title = "血糖今日异常人数")
|
||||||
|
private Integer bloodSugarAbnormalCountDay;
|
||||||
|
/**
|
||||||
|
* 血糖本月异常人数
|
||||||
|
*/
|
||||||
|
@Schema(title = "血糖本月异常人数")
|
||||||
|
private Integer bloodSugarAbnormalCountMonth;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* 血压今日打卡人数
|
||||||
|
*/
|
||||||
|
@Schema(title = "血压今日打卡人数")
|
||||||
|
private Integer bloodPressureCountDay;
|
||||||
|
/**
|
||||||
|
* 血压本月打卡人数
|
||||||
|
*/
|
||||||
|
@Schema(title = "血压本月打卡人数")
|
||||||
|
private Integer bloodPressureCountMonth;
|
||||||
|
/**
|
||||||
|
* 血压今日异常人数
|
||||||
|
*/
|
||||||
|
@Schema(title = "血压今日异常人数")
|
||||||
|
private Integer bloodPressureAbnormalCountDay;
|
||||||
|
/**
|
||||||
|
* 血压本月异常人数
|
||||||
|
*/
|
||||||
|
@Schema(title = "血压本月异常人数")
|
||||||
|
private Integer bloodPressureAbnormalCountMonth;
|
||||||
|
}
|
||||||
+66
@@ -0,0 +1,66 @@
|
|||||||
|
package com.renkang.emergency.largeScreen.entity.vo;
|
||||||
|
|
||||||
|
import com.fasterxml.jackson.annotation.JsonFormat;
|
||||||
|
import io.swagger.v3.oas.annotations.media.Schema;
|
||||||
|
import lombok.Data;
|
||||||
|
import org.jeecg.common.aspect.annotation.Dict;
|
||||||
|
import org.springframework.format.annotation.DateTimeFormat;
|
||||||
|
|
||||||
|
import java.util.Date;
|
||||||
|
|
||||||
|
@Data
|
||||||
|
public class HealthWeightLossVO {
|
||||||
|
/**
|
||||||
|
* 单位
|
||||||
|
*/
|
||||||
|
@Schema(title = "单位")
|
||||||
|
private String departName;
|
||||||
|
/**
|
||||||
|
* 姓名
|
||||||
|
*/
|
||||||
|
@Schema(title = "姓名")
|
||||||
|
private String name;
|
||||||
|
/**
|
||||||
|
* 性别
|
||||||
|
*/
|
||||||
|
@Schema(title = "性别")
|
||||||
|
@Dict(dicCode = "sex2")
|
||||||
|
private Integer sex;
|
||||||
|
/**
|
||||||
|
* 年龄
|
||||||
|
*/
|
||||||
|
@Schema(title = "年龄")
|
||||||
|
private Integer age;
|
||||||
|
/**
|
||||||
|
* 腰围(CM)
|
||||||
|
*/
|
||||||
|
@Schema(title = "腰围(CM)")
|
||||||
|
private String waist;
|
||||||
|
/**
|
||||||
|
* 身高(M)
|
||||||
|
*/
|
||||||
|
@Schema(title = "身高(M)")
|
||||||
|
private String height;
|
||||||
|
/**
|
||||||
|
* 体重(KG)
|
||||||
|
*/
|
||||||
|
@Schema(title = "体重(KG)")
|
||||||
|
private String weight;
|
||||||
|
/**
|
||||||
|
* BMI
|
||||||
|
*/
|
||||||
|
@Schema(title = "BMI")
|
||||||
|
private String bmi;
|
||||||
|
/**
|
||||||
|
* BMI是否异常 1:是/0:否
|
||||||
|
*/
|
||||||
|
@Schema(title = "BMI是否异常 1:是/0:否")
|
||||||
|
private String bmiFlag;
|
||||||
|
/**
|
||||||
|
* 填报时间
|
||||||
|
*/
|
||||||
|
@JsonFormat(pattern = "yyyy-MM-dd", timezone = "GMT+8")
|
||||||
|
@DateTimeFormat(pattern = "yyyy-MM-dd")
|
||||||
|
@Schema(title = "填报时间")
|
||||||
|
private Date inputDate;
|
||||||
|
}
|
||||||
+44
@@ -0,0 +1,44 @@
|
|||||||
|
package com.renkang.emergency.largeScreen.entity.vo;
|
||||||
|
|
||||||
|
import com.fasterxml.jackson.annotation.JsonFormat;
|
||||||
|
import io.swagger.v3.oas.annotations.media.Schema;
|
||||||
|
import lombok.Data;
|
||||||
|
import org.springframework.format.annotation.DateTimeFormat;
|
||||||
|
|
||||||
|
import java.util.Date;
|
||||||
|
|
||||||
|
@Data
|
||||||
|
public class HospitalVO {
|
||||||
|
/**
|
||||||
|
* 医院名字
|
||||||
|
*/
|
||||||
|
@Schema(title = "医院名字")
|
||||||
|
private String hospitalName;
|
||||||
|
/**
|
||||||
|
* 别名
|
||||||
|
*/
|
||||||
|
@Schema(title = "别名")
|
||||||
|
private String alias;
|
||||||
|
/**
|
||||||
|
* 地点
|
||||||
|
*/
|
||||||
|
@Schema(title = "地点")
|
||||||
|
private String address;
|
||||||
|
/**
|
||||||
|
* 经度
|
||||||
|
*/
|
||||||
|
@Schema(title = "经度")
|
||||||
|
private String lon;
|
||||||
|
/**
|
||||||
|
* 纬度
|
||||||
|
*/
|
||||||
|
@Schema(title = "纬度")
|
||||||
|
private String lat;
|
||||||
|
/**
|
||||||
|
* 签约时间
|
||||||
|
*/
|
||||||
|
@JsonFormat(pattern = "yyyy-MM-dd", timezone = "GMT+8")
|
||||||
|
@DateTimeFormat(pattern = "yyyy-MM-dd")
|
||||||
|
@Schema(title = "签约时间")
|
||||||
|
private Date contractDate;
|
||||||
|
}
|
||||||
+42
@@ -0,0 +1,42 @@
|
|||||||
|
package com.renkang.emergency.largeScreen.entity.vo;
|
||||||
|
|
||||||
|
import com.renkang.emergency.entity.EmergencyHealthRoom;
|
||||||
|
import com.renkang.emergency.entity.Resource;
|
||||||
|
import lombok.Data;
|
||||||
|
|
||||||
|
@Data
|
||||||
|
public class LargeScreenMap {
|
||||||
|
private String id;
|
||||||
|
|
||||||
|
private String name;
|
||||||
|
|
||||||
|
private String orgName;
|
||||||
|
|
||||||
|
private String type;
|
||||||
|
|
||||||
|
private String loveNum;
|
||||||
|
|
||||||
|
private String longitude;
|
||||||
|
|
||||||
|
private String latitude;
|
||||||
|
|
||||||
|
public LargeScreenMap() {}
|
||||||
|
|
||||||
|
public LargeScreenMap(Resource resource) {
|
||||||
|
this.id = resource.getId();
|
||||||
|
this.name = resource.getName();
|
||||||
|
this.orgName = resource.getAddress();
|
||||||
|
this.type = resource.getType();
|
||||||
|
this.latitude = String.valueOf(resource.getLatitude());
|
||||||
|
this.longitude = String.valueOf(resource.getLongitude());
|
||||||
|
}
|
||||||
|
|
||||||
|
public LargeScreenMap(EmergencyHealthRoom room) {
|
||||||
|
this.id = room.getId();
|
||||||
|
this.name = room.getName();
|
||||||
|
this.orgName = room.getOrgName();
|
||||||
|
this.type = "2";
|
||||||
|
this.latitude = room.getLatitude();
|
||||||
|
this.longitude = room.getLongitude();
|
||||||
|
}
|
||||||
|
}
|
||||||
+20
@@ -0,0 +1,20 @@
|
|||||||
|
package com.renkang.emergency.largeScreen.entity.vo;
|
||||||
|
|
||||||
|
import cn.hutool.core.date.DateUtil;
|
||||||
|
import com.fasterxml.jackson.annotation.JsonFormat;
|
||||||
|
import io.swagger.v3.oas.annotations.media.Schema;
|
||||||
|
import lombok.Data;
|
||||||
|
import org.springframework.format.annotation.DateTimeFormat;
|
||||||
|
|
||||||
|
import java.util.Date;
|
||||||
|
|
||||||
|
@Data
|
||||||
|
public class MedicalAbnormalStatisticsVO {
|
||||||
|
private Integer totalCount;
|
||||||
|
// 心血管异常人数
|
||||||
|
private Integer cardiovaAbCount;
|
||||||
|
// 脑血管异常人数
|
||||||
|
private Integer cerebrovAbCount;
|
||||||
|
// 冠脉ct异常人数
|
||||||
|
private Integer cctaAbCount;
|
||||||
|
}
|
||||||
+40
@@ -0,0 +1,40 @@
|
|||||||
|
package com.renkang.emergency.largeScreen.entity.vo;
|
||||||
|
|
||||||
|
import io.swagger.v3.oas.annotations.media.Schema;
|
||||||
|
import lombok.Data;
|
||||||
|
import org.jeecg.common.aspect.annotation.Dict;
|
||||||
|
|
||||||
|
@Data
|
||||||
|
public class MedicalAbnormalVO {
|
||||||
|
/**
|
||||||
|
* 单位
|
||||||
|
*/
|
||||||
|
@Schema(title = "单位")
|
||||||
|
private String departName;
|
||||||
|
/**
|
||||||
|
* 姓名
|
||||||
|
*/
|
||||||
|
@Schema(title = "姓名")
|
||||||
|
private String name;
|
||||||
|
/**
|
||||||
|
* 性别
|
||||||
|
*/
|
||||||
|
@Schema(title = "性别")
|
||||||
|
@Dict(dicCode = "sex2")
|
||||||
|
private Integer sex;
|
||||||
|
/**
|
||||||
|
* 年龄
|
||||||
|
*/
|
||||||
|
@Schema(title = "年龄")
|
||||||
|
private Integer age;
|
||||||
|
/**
|
||||||
|
* 体检医院
|
||||||
|
*/
|
||||||
|
@Schema(title = "体检医院")
|
||||||
|
private String hospitalName;
|
||||||
|
/**
|
||||||
|
* 检查日期
|
||||||
|
*/
|
||||||
|
@Schema(title = "检查日期")
|
||||||
|
private String checkInDate;
|
||||||
|
}
|
||||||
+23
@@ -0,0 +1,23 @@
|
|||||||
|
package com.renkang.emergency.largeScreen.entity.vo;
|
||||||
|
|
||||||
|
import io.swagger.v3.oas.annotations.media.Schema;
|
||||||
|
import lombok.Data;
|
||||||
|
|
||||||
|
@Data
|
||||||
|
public class MedicalPeopleNumStatisticsVO {
|
||||||
|
/**
|
||||||
|
* 医院名称
|
||||||
|
*/
|
||||||
|
@Schema(title = "医院名称")
|
||||||
|
private String hospitalName;
|
||||||
|
/**
|
||||||
|
* 已参检人数
|
||||||
|
*/
|
||||||
|
@Schema(title = "已参检人数")
|
||||||
|
private Integer checkedCount;
|
||||||
|
/**
|
||||||
|
* 应检人数 (可能无法提供 先冗余)
|
||||||
|
*/
|
||||||
|
@Schema(title = "应检人数 (可能无法提供 先冗余)")
|
||||||
|
private Integer totalCount;
|
||||||
|
}
|
||||||
+14
@@ -0,0 +1,14 @@
|
|||||||
|
package com.renkang.emergency.largeScreen.mapper;
|
||||||
|
|
||||||
|
import com.github.yulichang.base.MPJBaseMapper;
|
||||||
|
import com.renkang.emergency.largeScreen.entity.vo.LargeScreenMap;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* @Description: large_screen
|
||||||
|
* @Author: wang hao
|
||||||
|
* @Date: 2025-07-04
|
||||||
|
* @Version: V1.0
|
||||||
|
*/
|
||||||
|
public interface LargeScreenMapper extends MPJBaseMapper<LargeScreenMap> {
|
||||||
|
|
||||||
|
}
|
||||||
+43
@@ -0,0 +1,43 @@
|
|||||||
|
package com.renkang.emergency.largeScreen.service;
|
||||||
|
|
||||||
|
import com.baomidou.mybatisplus.core.metadata.IPage;
|
||||||
|
import com.baomidou.mybatisplus.extension.service.IService;
|
||||||
|
import com.renkang.emergency.largeScreen.entity.dto.*;
|
||||||
|
import com.renkang.emergency.largeScreen.entity.vo.*;
|
||||||
|
|
||||||
|
import java.util.List;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* @Description: HealthRoom
|
||||||
|
* @Author: wang hao
|
||||||
|
* @Date: 2025-07-03
|
||||||
|
* @Version: V1.0
|
||||||
|
*/
|
||||||
|
public interface ILargeScreenService extends IService<LargeScreenMap> {
|
||||||
|
|
||||||
|
List<LargeScreenMap> map(String type);
|
||||||
|
|
||||||
|
List<HealthRoomBaseVO> healthRoomBase(HealthRoomBaseDTO dto);
|
||||||
|
|
||||||
|
IPage<HealthRoomVO> healthRoomDetail(HealthRoomDTO dto);
|
||||||
|
|
||||||
|
IPage<MedicalAbnormalVO> medicalAbnormal(MedicalAbnormalDTO dto);
|
||||||
|
|
||||||
|
IPage<HealthWeightLossVO> healthWeightLoss(HealthWeightLossDTO dto);
|
||||||
|
|
||||||
|
IPage<HealthBloodSugarVO> healthBloodSugar(HealthBloodSugarDTO dto);
|
||||||
|
|
||||||
|
IPage<HealthBloodPressureVO> healthBloodPressure(HealthBloodPressureDTO dto);
|
||||||
|
|
||||||
|
List<MedicalPeopleNumStatisticsVO> medicalPeopleNumStatistics(MedicalPeopleNumStatisticsDTO dto);
|
||||||
|
|
||||||
|
MedicalAbnormalStatisticsVO medicalAbnormalStatistics(MedicalAbnormalStatisticsDTO dto);
|
||||||
|
|
||||||
|
HealthSignVO healthSign(HealthSignDTO dto);
|
||||||
|
|
||||||
|
List<HospitalVO> hospital();
|
||||||
|
|
||||||
|
void runJob();
|
||||||
|
|
||||||
|
void runTest();
|
||||||
|
}
|
||||||
+487
@@ -0,0 +1,487 @@
|
|||||||
|
package com.renkang.emergency.largeScreen.service.impl;
|
||||||
|
|
||||||
|
import cn.hutool.core.collection.CollUtil;
|
||||||
|
import cn.hutool.core.date.DateUtil;
|
||||||
|
import cn.hutool.core.util.ObjUtil;
|
||||||
|
import cn.hutool.core.util.StrUtil;
|
||||||
|
import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper;
|
||||||
|
import com.baomidou.mybatisplus.core.metadata.IPage;
|
||||||
|
import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
|
||||||
|
import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
|
||||||
|
import com.renkang.emergency.bean.response.XjDemandTypeFakerData;
|
||||||
|
import com.renkang.emergency.bean.response.XjHealthSignFakerData;
|
||||||
|
import com.renkang.emergency.bean.response.XjMedicalCountFakerData;
|
||||||
|
import com.renkang.emergency.bean.response.XjMedicalDataFakerData;
|
||||||
|
import com.renkang.emergency.entity.EmergencyHealthRoom;
|
||||||
|
import com.renkang.emergency.entity.Resource;
|
||||||
|
import com.renkang.emergency.entity.TblHelpCentorVo;
|
||||||
|
import com.renkang.emergency.entity.TblUserHelpVo;
|
||||||
|
import com.renkang.emergency.largeScreen.entity.dto.*;
|
||||||
|
import com.renkang.emergency.largeScreen.entity.vo.*;
|
||||||
|
import com.renkang.emergency.largeScreen.mapper.LargeScreenMapper;
|
||||||
|
import com.renkang.emergency.service.IEmergencyHealthRoomService;
|
||||||
|
import com.renkang.emergency.largeScreen.service.ILargeScreenService;
|
||||||
|
import com.renkang.emergency.service.IResourceService;
|
||||||
|
import lombok.RequiredArgsConstructor;
|
||||||
|
import org.jeecg.common.api.dto.ServiceFakerData;
|
||||||
|
import org.jeecg.common.api.dto.YcMedicalCenterFakerData;
|
||||||
|
import org.jeecg.common.constant.FakerDataConstant;
|
||||||
|
import org.jeecg.common.util.RedisUtil;
|
||||||
|
import org.jeecg.util.RedisClientUtil;
|
||||||
|
import org.jeecg.util.RedisKeyPrefix;
|
||||||
|
import org.springframework.beans.BeanUtils;
|
||||||
|
import org.springframework.stereotype.Service;
|
||||||
|
|
||||||
|
import java.util.*;
|
||||||
|
import java.util.stream.Collectors;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* @Description: large_screen
|
||||||
|
* @Author: wang hao
|
||||||
|
* @Date: 2025-07-04
|
||||||
|
* @Version: V1.0
|
||||||
|
*/
|
||||||
|
@Service
|
||||||
|
@RequiredArgsConstructor
|
||||||
|
public class LargeScreenServiceImpl extends ServiceImpl<LargeScreenMapper, LargeScreenMap> implements ILargeScreenService {
|
||||||
|
private final RedisKeyPrefix MEDICAL = new RedisKeyPrefix(-1, "emergency");
|
||||||
|
private final String MEDICAL_PEOPLE_NUM_STATISTICS = "medicalPeopleNumStatistics";
|
||||||
|
private final String MEDICAL_ABNORMAL_STATISTICS = "medicalAbnormalStatistics";
|
||||||
|
private final String HEALTH_SIGN = "healthSign";
|
||||||
|
private final IResourceService resourceService;
|
||||||
|
private final IEmergencyHealthRoomService roomService;
|
||||||
|
private final RedisClientUtil redisClientUtil;
|
||||||
|
private final RedisUtil redisUtil;
|
||||||
|
|
||||||
|
|
||||||
|
private static final double MIN_LONGITUDE = 80.0;
|
||||||
|
private static final double MAX_LONGITUDE = 100.0;
|
||||||
|
private static final double MIN_LATITUDE = 35.0;
|
||||||
|
private static final double MAX_LATITUDE = 50.0;
|
||||||
|
|
||||||
|
private static final String[] CITIES = {
|
||||||
|
"乌鲁木齐", "喀什", "克拉玛依", "吐鲁番", "哈密",
|
||||||
|
"阿克苏", "巴音郭楞", "昌吉", "石河子", "博乐"
|
||||||
|
};
|
||||||
|
|
||||||
|
private static final String[] SURNAMES = {
|
||||||
|
"李", "王", "张", "刘", "陈",
|
||||||
|
"杨", "黄", "赵", "周", "吴",
|
||||||
|
"徐", "孙", "胡", "朱", "郭",
|
||||||
|
"何", "高", "林", "罗", "郑"
|
||||||
|
};
|
||||||
|
|
||||||
|
private static final String[] FIRST_NAMES = {
|
||||||
|
"伟", "芳", "娜", "敏", "静",
|
||||||
|
"军", "鹏", "强", "磊", "丹",
|
||||||
|
"丽", "涛", "超", "莉", "洋",
|
||||||
|
"明", "辉", "俊", "毅", "凯"
|
||||||
|
};
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public List<LargeScreenMap> map(String type) {
|
||||||
|
List<LargeScreenMap> maps = new ArrayList<>();
|
||||||
|
if (StrUtil.isEmpty(type) || type.equals("1")) {
|
||||||
|
List<Resource> list = resourceService.list(new LambdaQueryWrapper<Resource>()
|
||||||
|
.eq(StrUtil.isNotEmpty(type),Resource::getType, type)
|
||||||
|
.eq(StrUtil.isEmpty(type),Resource::getType, "1"));
|
||||||
|
maps.addAll(list.stream().map(LargeScreenMap::new).collect(Collectors.toList()));
|
||||||
|
}
|
||||||
|
if (StrUtil.isEmpty(type) || type.equals("2")) {
|
||||||
|
List<EmergencyHealthRoom> list = roomService.list();
|
||||||
|
maps.addAll(list.stream().map(LargeScreenMap::new).collect(Collectors.toList()));
|
||||||
|
}
|
||||||
|
if (StrUtil.isEmpty(type) || type.equals("5")) {
|
||||||
|
List<Resource> list = resourceService.list(new LambdaQueryWrapper<Resource>()
|
||||||
|
.eq(StrUtil.isNotEmpty(type),Resource::getType, type)
|
||||||
|
.eq(StrUtil.isEmpty(type),Resource::getType, "5"));
|
||||||
|
maps.addAll(list.stream().map(LargeScreenMap::new).collect(Collectors.toList()));
|
||||||
|
}
|
||||||
|
return maps;
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public List<HealthRoomBaseVO> healthRoomBase(HealthRoomBaseDTO dto){
|
||||||
|
List<HealthRoomBaseVO> list = new ArrayList<>();
|
||||||
|
for (int i = 0; i < 10; i++) {
|
||||||
|
HealthRoomBaseVO baseVO = new HealthRoomBaseVO();
|
||||||
|
baseVO.setId(UUID.randomUUID().toString());
|
||||||
|
String[] data = generateRandomLocation();
|
||||||
|
baseVO.setAddress(data[0]);
|
||||||
|
baseVO.setLon(data[1]);
|
||||||
|
baseVO.setLat(data[2]);
|
||||||
|
baseVO.setDepartName("新疆大厂的单位");
|
||||||
|
baseVO.setBuildDate(new Date());
|
||||||
|
list.add(baseVO);
|
||||||
|
}
|
||||||
|
// 查询第三方接口返回 此接口返回对象跟原有可能不太一样 要注意
|
||||||
|
return list;
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public IPage<HealthRoomVO> healthRoomDetail(HealthRoomDTO dto){
|
||||||
|
IPage<HealthRoomVO> page = new Page<>(dto.getPageNo(), dto.getPageSize());
|
||||||
|
page.setTotal(20);
|
||||||
|
List<HealthRoomVO> list = new ArrayList<>();
|
||||||
|
Map<String, String> CHECK_TYPES = new HashMap<>();
|
||||||
|
CHECK_TYPES.put("11", "BMI");
|
||||||
|
CHECK_TYPES.put("21", "收缩压");
|
||||||
|
CHECK_TYPES.put("22", "舒张压");
|
||||||
|
CHECK_TYPES.put("31", "血糖");
|
||||||
|
CHECK_TYPES.put("41", "低密度脂蛋白");
|
||||||
|
CHECK_TYPES.put("42", "总胆固醇");
|
||||||
|
CHECK_TYPES.put("43", "甘油三酯");
|
||||||
|
CHECK_TYPES.put("51", "尿酸");
|
||||||
|
CHECK_TYPES.put("61", "同型半胱氨酸");
|
||||||
|
List<String> keys = new ArrayList<>(CHECK_TYPES.keySet());
|
||||||
|
for (int i = 0; i < 10; i++) {
|
||||||
|
HealthRoomVO roomVO = new HealthRoomVO();
|
||||||
|
roomVO.setName("小屋");
|
||||||
|
roomVO.setDepartName("新疆大厂");
|
||||||
|
roomVO.setCheckInDate(DateUtil.today());
|
||||||
|
|
||||||
|
Random random = new Random();
|
||||||
|
String randomKey = keys.get(random.nextInt(keys.size()));
|
||||||
|
roomVO.setCheckType(randomKey);
|
||||||
|
roomVO.setLastVal("111");
|
||||||
|
roomVO.setGoalVal("100");
|
||||||
|
roomVO.setCurrentVal("105");
|
||||||
|
roomVO.setCompareVal("5");
|
||||||
|
roomVO.setSuccessFlag("0");
|
||||||
|
list.add(roomVO);
|
||||||
|
}
|
||||||
|
page.setRecords(list);
|
||||||
|
// 查询第三方接口返回
|
||||||
|
return page;
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public IPage<MedicalAbnormalVO> medicalAbnormal (MedicalAbnormalDTO dto){
|
||||||
|
IPage<MedicalAbnormalVO> page = new Page<>(dto.getPageNo(), dto.getPageSize());
|
||||||
|
page.setTotal(20);
|
||||||
|
List<MedicalAbnormalVO> list = new ArrayList<>();
|
||||||
|
for (int i = 0; i < 20; i++) {
|
||||||
|
MedicalAbnormalVO abnormalVO = new MedicalAbnormalVO();
|
||||||
|
abnormalVO.setCheckInDate(DateUtil.today());
|
||||||
|
abnormalVO.setHospitalName("新疆医院");
|
||||||
|
abnormalVO.setDepartName("新疆大厂");
|
||||||
|
Random random = new Random();
|
||||||
|
abnormalVO.setSex(random.nextInt(2) + 1);
|
||||||
|
abnormalVO.setAge(random.nextInt(65 - 18 + 1) + 18);
|
||||||
|
abnormalVO.setName(generateRandomName());
|
||||||
|
list.add(abnormalVO);
|
||||||
|
}
|
||||||
|
page.setRecords(list);
|
||||||
|
// 查询第三方接口返回
|
||||||
|
return page;
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public IPage<HealthWeightLossVO> healthWeightLoss (HealthWeightLossDTO dto){
|
||||||
|
IPage<HealthWeightLossVO> page = new Page<>(dto.getPageNo(), dto.getPageSize());
|
||||||
|
page.setTotal(20);
|
||||||
|
List<HealthWeightLossVO> list = new ArrayList<>();
|
||||||
|
for (int i = 0; i < 20; i++) {
|
||||||
|
HealthWeightLossVO weightLossVO = new HealthWeightLossVO();
|
||||||
|
weightLossVO.setName(generateRandomName());
|
||||||
|
weightLossVO.setWeight("80");
|
||||||
|
weightLossVO.setDepartName("新疆大厂");
|
||||||
|
weightLossVO.setBmi("26.8");
|
||||||
|
weightLossVO.setWaist("80");
|
||||||
|
weightLossVO.setHeight("180");
|
||||||
|
weightLossVO.setBmiFlag("0");
|
||||||
|
weightLossVO.setInputDate(new Date());
|
||||||
|
Random random = new Random();
|
||||||
|
weightLossVO.setSex(random.nextInt(2) + 1);
|
||||||
|
weightLossVO.setAge(random.nextInt(65 - 18 + 1) + 18);
|
||||||
|
list.add(weightLossVO);
|
||||||
|
}
|
||||||
|
page.setRecords(list);
|
||||||
|
// 查询第三方接口返回
|
||||||
|
return page;
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public IPage<HealthBloodSugarVO> healthBloodSugar (HealthBloodSugarDTO dto){
|
||||||
|
IPage<HealthBloodSugarVO> page = new Page<>(dto.getPageNo(), dto.getPageSize());
|
||||||
|
page.setTotal(20);
|
||||||
|
List<HealthBloodSugarVO> list = new ArrayList<>();
|
||||||
|
for (int i = 0; i < 20; i++) {
|
||||||
|
HealthBloodSugarVO bloodSugarVO = new HealthBloodSugarVO();
|
||||||
|
bloodSugarVO.setName(generateRandomName());
|
||||||
|
bloodSugarVO.setDepartName("新疆大厂");
|
||||||
|
bloodSugarVO.setBmiFlag("0");
|
||||||
|
bloodSugarVO.setInputDate(new Date());
|
||||||
|
bloodSugarVO.setBsVal("100");
|
||||||
|
bloodSugarVO.setWaist("88");
|
||||||
|
Random random = new Random();
|
||||||
|
bloodSugarVO.setSex(random.nextInt(2) + 1);
|
||||||
|
bloodSugarVO.setAge(random.nextInt(65 - 18 + 1) + 18);
|
||||||
|
list.add(bloodSugarVO);
|
||||||
|
}
|
||||||
|
page.setRecords(list);
|
||||||
|
// 查询第三方接口返回
|
||||||
|
return page;
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public IPage<HealthBloodPressureVO> healthBloodPressure (HealthBloodPressureDTO dto){
|
||||||
|
IPage<HealthBloodPressureVO> page = new Page<>(dto.getPageNo(), dto.getPageSize());
|
||||||
|
page.setTotal(20);
|
||||||
|
List<HealthBloodPressureVO> list = new ArrayList<>();
|
||||||
|
for (int i = 0; i < 20; i++) {
|
||||||
|
HealthBloodPressureVO bloodPressureVO = new HealthBloodPressureVO();
|
||||||
|
bloodPressureVO.setName(generateRandomName());
|
||||||
|
bloodPressureVO.setDepartName("新疆大厂");
|
||||||
|
bloodPressureVO.setInputDate(new Date());
|
||||||
|
bloodPressureVO.setDbp("25");
|
||||||
|
bloodPressureVO.setDbpFlag("0");
|
||||||
|
bloodPressureVO.setSbp("15");
|
||||||
|
bloodPressureVO.setSbpFlag("0");
|
||||||
|
Random random = new Random();
|
||||||
|
bloodPressureVO.setSex(random.nextInt(2) + 1);
|
||||||
|
bloodPressureVO.setAge(random.nextInt(65 - 18 + 1) + 18);
|
||||||
|
list.add(bloodPressureVO);
|
||||||
|
}
|
||||||
|
page.setRecords(list);
|
||||||
|
// 查询第三方接口返回
|
||||||
|
return page;
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public List<HospitalVO> hospital(){
|
||||||
|
List<HospitalVO> list = new ArrayList<>();
|
||||||
|
for (int i = 0; i < 20; i++) {
|
||||||
|
HospitalVO hospitalVO = new HospitalVO();
|
||||||
|
hospitalVO.setHospitalName("新疆医院");
|
||||||
|
String[] data = generateRandomLocation();
|
||||||
|
hospitalVO.setAddress(data[0]);
|
||||||
|
hospitalVO.setAlias("新"+i);
|
||||||
|
hospitalVO.setContractDate(new Date());
|
||||||
|
hospitalVO.setLon(data[1]);
|
||||||
|
hospitalVO.setLat(data[2]);
|
||||||
|
list.add(hospitalVO);
|
||||||
|
}
|
||||||
|
return list;
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public List<MedicalPeopleNumStatisticsVO> medicalPeopleNumStatistics (MedicalPeopleNumStatisticsDTO dto){
|
||||||
|
Boolean enable = (Boolean) redisUtil.get(StrUtil.isNotEmpty(dto.getCenterId()) ?
|
||||||
|
FakerDataConstant.XJ_MEDICAL_COUNT_ENABLE + ":" + dto.getCenterId() : FakerDataConstant.XJ_MEDICAL_COUNT_ENABLE);
|
||||||
|
if (enable != null && enable) {
|
||||||
|
List<MedicalPeopleNumStatisticsVO> vo = XjMedicalCountFakerData(dto.getCenterId());
|
||||||
|
if (vo != null) {
|
||||||
|
return vo;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
List<MedicalPeopleNumStatisticsVO> list = redisClientUtil.getList(MEDICAL,MEDICAL_PEOPLE_NUM_STATISTICS,MedicalPeopleNumStatisticsVO.class);
|
||||||
|
if (CollUtil.isEmpty(list)){
|
||||||
|
return new ArrayList<>();
|
||||||
|
}
|
||||||
|
return list;
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public MedicalAbnormalStatisticsVO medicalAbnormalStatistics (MedicalAbnormalStatisticsDTO dto){
|
||||||
|
Boolean enable = (Boolean) redisUtil.get(StrUtil.isNotEmpty(dto.getCenterId())
|
||||||
|
? FakerDataConstant.XJ_MEDICAL_DATA_ENABLE + ":" + dto.getCenterId() : FakerDataConstant.XJ_MEDICAL_DATA_ENABLE);
|
||||||
|
if (enable != null && enable) {
|
||||||
|
MedicalAbnormalStatisticsVO vo = XjMedicalDataFakerDataNew(dto.getCenterId());
|
||||||
|
if (vo != null) {
|
||||||
|
return vo;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
MedicalAbnormalStatisticsVO statisticsVO = redisClientUtil.get(MEDICAL,MEDICAL_ABNORMAL_STATISTICS,MedicalAbnormalStatisticsVO.class);
|
||||||
|
if (ObjUtil.isEmpty(statisticsVO)){
|
||||||
|
return new MedicalAbnormalStatisticsVO();
|
||||||
|
}
|
||||||
|
return statisticsVO;
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public HealthSignVO healthSign (HealthSignDTO dto){
|
||||||
|
Boolean enable = (Boolean) redisUtil.get(StrUtil.isNotEmpty(dto.getCenterId())
|
||||||
|
? FakerDataConstant.XJ_HEALTH_SIGN_COUNT_ENABLE + ":" + dto.getCenterId() : FakerDataConstant.XJ_HEALTH_SIGN_COUNT_ENABLE);
|
||||||
|
if (enable != null && enable) {
|
||||||
|
HealthSignVO vo = XjHealthSignFakerDataNew(dto.getCenterId());
|
||||||
|
if (vo != null) {
|
||||||
|
return vo;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
HealthSignVO vo = redisClientUtil.get(MEDICAL,HEALTH_SIGN,HealthSignVO.class);
|
||||||
|
if (null == vo){
|
||||||
|
return new HealthSignVO();
|
||||||
|
}
|
||||||
|
return vo;
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public void runJob(){
|
||||||
|
// 体检人数统计查询
|
||||||
|
List<MedicalPeopleNumStatisticsVO> medicalPeopleNumStatisticsList = new ArrayList<>();
|
||||||
|
redisClientUtil.set(MEDICAL,MEDICAL_PEOPLE_NUM_STATISTICS,medicalPeopleNumStatisticsList);
|
||||||
|
|
||||||
|
// 体检异常数据查询
|
||||||
|
List<MedicalAbnormalStatisticsVO> medicalAbnormalStatisticsList = new ArrayList<>();
|
||||||
|
redisClientUtil.set(MEDICAL,MEDICAL_ABNORMAL_STATISTICS,medicalAbnormalStatisticsList);
|
||||||
|
|
||||||
|
// 减重 健康打卡数据今日查询
|
||||||
|
HealthSignDataVO weightLossDay = new HealthSignDataVO();
|
||||||
|
// 减重 健康打卡数据本月查询
|
||||||
|
HealthSignDataVO weightLossMonth = new HealthSignDataVO();
|
||||||
|
|
||||||
|
// 血压 健康打卡数据今日查询
|
||||||
|
HealthSignDataVO bloodPressureDay = new HealthSignDataVO();
|
||||||
|
// 血压 健康打卡数据本月查询
|
||||||
|
HealthSignDataVO bloodPressureMonth = new HealthSignDataVO();
|
||||||
|
|
||||||
|
// 血糖 健康打卡数据今日查询
|
||||||
|
HealthSignDataVO bloodSugarDay = new HealthSignDataVO();
|
||||||
|
// 血糖 健康打卡数据本月查询
|
||||||
|
HealthSignDataVO bloodSugarMonth = new HealthSignDataVO();
|
||||||
|
|
||||||
|
// 减重 血压 血糖 三种数据整合存
|
||||||
|
HealthSignVO healthSign = new HealthSignVO();
|
||||||
|
redisClientUtil.set(MEDICAL,HEALTH_SIGN,healthSign);
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
public void runTest(){
|
||||||
|
// 体检人数统计
|
||||||
|
List<MedicalPeopleNumStatisticsVO> medicalPeopleNumStatisticsList = new ArrayList<>();
|
||||||
|
MedicalPeopleNumStatisticsVO statistics1 = new MedicalPeopleNumStatisticsVO();
|
||||||
|
statistics1.setHospitalName("克拉玛依市诚裕慈惠综合门诊部门有限公司");
|
||||||
|
statistics1.setCheckedCount(220);
|
||||||
|
statistics1.setTotalCount(550);
|
||||||
|
medicalPeopleNumStatisticsList.add(statistics1);
|
||||||
|
MedicalPeopleNumStatisticsVO statistics2 = new MedicalPeopleNumStatisticsVO();
|
||||||
|
statistics2.setHospitalName("昌吉州宝石花医院");
|
||||||
|
statistics2.setCheckedCount(156);
|
||||||
|
statistics2.setTotalCount(200);
|
||||||
|
medicalPeopleNumStatisticsList.add(statistics2);
|
||||||
|
MedicalPeopleNumStatisticsVO statistics3 = new MedicalPeopleNumStatisticsVO();
|
||||||
|
statistics3.setHospitalName("中心医院");
|
||||||
|
statistics3.setCheckedCount(86);
|
||||||
|
statistics3.setTotalCount(100);
|
||||||
|
medicalPeopleNumStatisticsList.add(statistics3);
|
||||||
|
MedicalPeopleNumStatisticsVO statistics4 = new MedicalPeopleNumStatisticsVO();
|
||||||
|
statistics4.setHospitalName("克拉玛依市中西医结合医院(市人民医院)");
|
||||||
|
statistics4.setCheckedCount(23);
|
||||||
|
statistics4.setTotalCount(30);
|
||||||
|
medicalPeopleNumStatisticsList.add(statistics4);
|
||||||
|
MedicalPeopleNumStatisticsVO statistics5 = new MedicalPeopleNumStatisticsVO();
|
||||||
|
statistics5.setHospitalName("新疆医院");
|
||||||
|
statistics5.setCheckedCount(15);
|
||||||
|
statistics5.setTotalCount(20);
|
||||||
|
medicalPeopleNumStatisticsList.add(statistics5);
|
||||||
|
redisClientUtil.set(MEDICAL,MEDICAL_PEOPLE_NUM_STATISTICS,medicalPeopleNumStatisticsList);
|
||||||
|
|
||||||
|
// 体检异常数据查询
|
||||||
|
MedicalAbnormalStatisticsVO abnormalStatistics = new MedicalAbnormalStatisticsVO();
|
||||||
|
abnormalStatistics.setTotalCount(18000);
|
||||||
|
abnormalStatistics.setCardiovaAbCount(2000);
|
||||||
|
abnormalStatistics.setCerebrovAbCount(1500);
|
||||||
|
abnormalStatistics.setCctaAbCount(200);
|
||||||
|
redisClientUtil.set(MEDICAL,MEDICAL_ABNORMAL_STATISTICS,abnormalStatistics);
|
||||||
|
|
||||||
|
// 减重 血压 血糖 三种数据整合存
|
||||||
|
HealthSignVO healthSign = new HealthSignVO();
|
||||||
|
healthSign.setWeightLossCountDay(86);
|
||||||
|
healthSign.setWeightLossAbnormalCountDay(6);
|
||||||
|
healthSign.setWeightLossCountMonth(956);
|
||||||
|
healthSign.setWeightLossAbnormalCountMonth(56);
|
||||||
|
|
||||||
|
healthSign.setBloodSugarCountDay(8);
|
||||||
|
healthSign.setBloodSugarAbnormalCountDay(5);
|
||||||
|
healthSign.setBloodSugarCountMonth(156);
|
||||||
|
healthSign.setBloodSugarAbnormalCountMonth(56);
|
||||||
|
|
||||||
|
healthSign.setBloodPressureCountDay(18);
|
||||||
|
healthSign.setBloodPressureAbnormalCountDay(3);
|
||||||
|
healthSign.setBloodPressureCountMonth(350);
|
||||||
|
healthSign.setBloodPressureAbnormalCountMonth(30);
|
||||||
|
redisClientUtil.set(MEDICAL,HEALTH_SIGN,healthSign);
|
||||||
|
}
|
||||||
|
|
||||||
|
public static String[] generateRandomLocation() {
|
||||||
|
Random random = new Random();
|
||||||
|
|
||||||
|
// 生成随机经纬度
|
||||||
|
double longitude = MIN_LONGITUDE + (MAX_LONGITUDE - MIN_LONGITUDE) * random.nextDouble();
|
||||||
|
double latitude = MIN_LATITUDE + (MAX_LATITUDE - MIN_LATITUDE) * random.nextDouble();
|
||||||
|
|
||||||
|
// 随机选择一个城市作为地址
|
||||||
|
String city = CITIES[random.nextInt(CITIES.length)];
|
||||||
|
|
||||||
|
String[] data = new String[3];
|
||||||
|
data[0] = city;
|
||||||
|
data[1] = String.valueOf(longitude);
|
||||||
|
data[2] = String.valueOf(latitude);
|
||||||
|
return data;
|
||||||
|
}
|
||||||
|
|
||||||
|
public static String generateRandomName() {
|
||||||
|
Random random = new Random();
|
||||||
|
|
||||||
|
// 随机选择一个姓
|
||||||
|
String surname = SURNAMES[random.nextInt(SURNAMES.length)];
|
||||||
|
|
||||||
|
// 随机选择一个名
|
||||||
|
String firstName = FIRST_NAMES[random.nextInt(FIRST_NAMES.length)];
|
||||||
|
|
||||||
|
// 组合成完整姓名
|
||||||
|
return surname + firstName;
|
||||||
|
}
|
||||||
|
|
||||||
|
private List<MedicalPeopleNumStatisticsVO> XjMedicalCountFakerData(String centerId) {
|
||||||
|
try {
|
||||||
|
Object data = redisUtil.get(StrUtil.isNotEmpty(centerId) ?
|
||||||
|
FakerDataConstant.XJ_MEDICAL_COUNT + ":" + centerId : FakerDataConstant.XJ_MEDICAL_COUNT);
|
||||||
|
if (data == null) {
|
||||||
|
return Collections.emptyList();
|
||||||
|
}
|
||||||
|
try {
|
||||||
|
List<MedicalPeopleNumStatisticsVO> voList = new ArrayList<>();
|
||||||
|
List<XjMedicalCountFakerData> returnDataList = (List<XjMedicalCountFakerData>) data;
|
||||||
|
for (XjMedicalCountFakerData fakerData : returnDataList) {
|
||||||
|
MedicalPeopleNumStatisticsVO vo = new MedicalPeopleNumStatisticsVO();
|
||||||
|
vo.setHospitalName(fakerData.getName());
|
||||||
|
vo.setCheckedCount(Integer.valueOf(fakerData.getCount()));
|
||||||
|
voList.add(vo);
|
||||||
|
}
|
||||||
|
return voList;
|
||||||
|
} catch (Exception e) {
|
||||||
|
log.error("新疆大屏体检人数统计数据转化异常", e);
|
||||||
|
return Collections.emptyList();
|
||||||
|
}
|
||||||
|
} catch (Exception e) {
|
||||||
|
return null;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
private HealthSignVO XjHealthSignFakerDataNew(String centerId) {
|
||||||
|
try {
|
||||||
|
HealthSignVO vo = new HealthSignVO();
|
||||||
|
XjHealthSignFakerData data = (XjHealthSignFakerData) redisUtil.get(StrUtil.isNotEmpty(centerId)
|
||||||
|
? FakerDataConstant.XJ_HEALTH_SIGN_COUNT + ":" + centerId : FakerDataConstant.XJ_HEALTH_SIGN_COUNT);
|
||||||
|
BeanUtils.copyProperties(data,vo);
|
||||||
|
return vo;
|
||||||
|
} catch (Exception e) {
|
||||||
|
return null;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
private MedicalAbnormalStatisticsVO XjMedicalDataFakerDataNew(String centerId) {
|
||||||
|
try {
|
||||||
|
MedicalAbnormalStatisticsVO vo = new MedicalAbnormalStatisticsVO();
|
||||||
|
XjMedicalDataFakerData data = (XjMedicalDataFakerData) redisUtil.get(StrUtil.isNotEmpty(centerId)
|
||||||
|
? FakerDataConstant.XJ_MEDICAL_DATA + ":" + centerId : FakerDataConstant.XJ_MEDICAL_DATA);
|
||||||
|
BeanUtils.copyProperties(data,vo);
|
||||||
|
return vo;
|
||||||
|
} catch (Exception e) {
|
||||||
|
return null;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
+19
@@ -0,0 +1,19 @@
|
|||||||
|
package com.renkang.emergency.largeScreen.task;
|
||||||
|
|
||||||
|
import com.renkang.emergency.largeScreen.service.ILargeScreenService;
|
||||||
|
import lombok.RequiredArgsConstructor;
|
||||||
|
import lombok.extern.slf4j.Slf4j;
|
||||||
|
import org.springframework.stereotype.Component;
|
||||||
|
|
||||||
|
@Component
|
||||||
|
@Slf4j
|
||||||
|
@RequiredArgsConstructor
|
||||||
|
public class LargeScreenJob {
|
||||||
|
private final ILargeScreenService largeScreenService;
|
||||||
|
|
||||||
|
public void largeScreen() {
|
||||||
|
log.info("========开始缓存大屏数据========");
|
||||||
|
largeScreenService.runJob();
|
||||||
|
log.info("========结束缓存大屏数据========");
|
||||||
|
}
|
||||||
|
}
|
||||||
+14
@@ -0,0 +1,14 @@
|
|||||||
|
package com.renkang.emergency.mapper;
|
||||||
|
|
||||||
|
import com.github.yulichang.base.MPJBaseMapper;
|
||||||
|
import com.renkang.emergency.entity.EmergencyHealthRoom;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* @Description: large_screen
|
||||||
|
* @Author: wang hao
|
||||||
|
* @Date: 2025-07-04
|
||||||
|
* @Version: V1.0
|
||||||
|
*/
|
||||||
|
public interface EmergencyHealthRoomMapper extends MPJBaseMapper<EmergencyHealthRoom> {
|
||||||
|
|
||||||
|
}
|
||||||
+6
@@ -1,10 +1,12 @@
|
|||||||
package com.renkang.emergency.mapper;
|
package com.renkang.emergency.mapper;
|
||||||
|
|
||||||
|
import java.util.Date;
|
||||||
import java.util.List;
|
import java.util.List;
|
||||||
|
|
||||||
import com.renkang.emergency.entity.EmergencySchedules;
|
import com.renkang.emergency.entity.EmergencySchedules;
|
||||||
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
|
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
|
||||||
import com.github.yulichang.base.MPJBaseMapper;
|
import com.github.yulichang.base.MPJBaseMapper;
|
||||||
|
import org.apache.ibatis.annotations.Param;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* @Description: 排班表
|
* @Description: 排班表
|
||||||
@@ -14,4 +16,8 @@ import com.github.yulichang.base.MPJBaseMapper;
|
|||||||
*/
|
*/
|
||||||
public interface EmergencySchedulesNewMapper extends BaseMapper<EmergencySchedules>,MPJBaseMapper<EmergencySchedules> {
|
public interface EmergencySchedulesNewMapper extends BaseMapper<EmergencySchedules>,MPJBaseMapper<EmergencySchedules> {
|
||||||
|
|
||||||
|
List<Date> scheduleTimes(@Param("year") Integer year,
|
||||||
|
@Param("month") Integer month,
|
||||||
|
@Param("userId") String userId);
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|||||||
+5
@@ -0,0 +1,5 @@
|
|||||||
|
<?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.mapper.EmergencyHealthRoomMapper">
|
||||||
|
|
||||||
|
</mapper>
|
||||||
+10
-1
@@ -1,5 +1,14 @@
|
|||||||
<?xml version="1.0" encoding="UTF-8"?>
|
<?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">
|
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
|
||||||
<mapper namespace="com.renkang.emergency.mapper.EmergencySchedulesNewMapper">
|
<mapper namespace="com.renkang.emergency.mapper.EmergencySchedulesNewMapper">
|
||||||
|
<select id="scheduleTimes" resultType="java.util.Date">
|
||||||
|
SELECT DISTINCT t2.schedules_time
|
||||||
|
FROM emergency_schedules_new_item t1
|
||||||
|
LEFT JOIN emergency_new_schedules t2 ON t1.schedules_id = t2.id
|
||||||
|
WHERE
|
||||||
|
YEAR ( t2.schedules_time ) = #{year}
|
||||||
|
AND MONTH ( t2.schedules_time ) = #{month}
|
||||||
|
and t2.schedules_time is not null
|
||||||
|
AND t1.user_id = #{userId}
|
||||||
|
</select>
|
||||||
</mapper>
|
</mapper>
|
||||||
+14
@@ -0,0 +1,14 @@
|
|||||||
|
package com.renkang.emergency.service;
|
||||||
|
|
||||||
|
import com.baomidou.mybatisplus.extension.service.IService;
|
||||||
|
import com.renkang.emergency.entity.EmergencyHealthRoom;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* @Description: HealthRoom
|
||||||
|
* @Author: wanghao
|
||||||
|
* @Date: 2025-07-03
|
||||||
|
* @Version: V1.0
|
||||||
|
*/
|
||||||
|
public interface IEmergencyHealthRoomService extends IService<EmergencyHealthRoom> {
|
||||||
|
|
||||||
|
}
|
||||||
+59
@@ -0,0 +1,59 @@
|
|||||||
|
package com.renkang.emergency.service;
|
||||||
|
|
||||||
|
|
||||||
|
import com.renkang.emergency.bean.response.*;
|
||||||
|
import org.jeecg.common.api.dto.*;
|
||||||
|
|
||||||
|
import java.util.List;
|
||||||
|
import java.util.Map;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* health_house_banner
|
||||||
|
*
|
||||||
|
* @author Junqiang Zhu
|
||||||
|
* @date 2024-04-11
|
||||||
|
*/
|
||||||
|
public interface IFakerDataService {
|
||||||
|
|
||||||
|
void createGroupUserFakerData(GroupUserFakerData data);
|
||||||
|
|
||||||
|
Object getFakerData(int module,String centerId);
|
||||||
|
|
||||||
|
void fakerDataEnable(FakerDataEnable enable);
|
||||||
|
|
||||||
|
void createMedicalCenterFakerData(MedicalCenterFakerData data);
|
||||||
|
|
||||||
|
void createNutritionFakerData(NutritionFakerData data);
|
||||||
|
|
||||||
|
void createHealthLevelFakerData(HealthLevelFakerData data);
|
||||||
|
|
||||||
|
void createInterveneFakerData(InterveneFakerData data);
|
||||||
|
|
||||||
|
Map<Integer, Boolean> getFakerDataEnable(String centerId);
|
||||||
|
|
||||||
|
void createServiceFakerData(ServiceFakerData data);
|
||||||
|
|
||||||
|
void createMedicalFakerData(MedicalFakerData data);
|
||||||
|
|
||||||
|
void createBigIllFakerData(BigIllFakerData data);
|
||||||
|
|
||||||
|
void createYcServiceFakerData(ServiceFakerData data);
|
||||||
|
|
||||||
|
void createYcMedicalFakerData(MedicalFakerData data);
|
||||||
|
|
||||||
|
void createYcMedicalCenterFakerData(List<YcMedicalCenterFakerData> data,String centerId);
|
||||||
|
|
||||||
|
void createYcUserHealthFakerData(YcUserHealthFakerData data);
|
||||||
|
|
||||||
|
void createWatchFakerData(HouseWatchFakerData data);
|
||||||
|
|
||||||
|
void createWatchStressFakerData(HouseWatchStressFakerData data);
|
||||||
|
|
||||||
|
void createXjDemandTypeFakerData(XjDemandTypeFakerData data);
|
||||||
|
|
||||||
|
void createXjMedicalCountFakerData(List<XjMedicalCountFakerData> data,String centerId);
|
||||||
|
|
||||||
|
void createXjHealthSignCountFakerData(XjHealthSignFakerData data);
|
||||||
|
|
||||||
|
void createXjMedicalDataFakerData(XjMedicalDataFakerData data);
|
||||||
|
}
|
||||||
+1
-1
@@ -18,6 +18,6 @@ public interface ITbHelpCenterService extends IService<TblHelpCenter> {
|
|||||||
* @param depart
|
* @param depart
|
||||||
* @return
|
* @return
|
||||||
*/
|
*/
|
||||||
List<TblHelpCentorVo> sicknessTypeStatistic(String sex,String depart);
|
List<TblHelpCentorVo> sicknessTypeStatistic(String sex,String depart,String centerId);
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|||||||
+18
@@ -0,0 +1,18 @@
|
|||||||
|
package com.renkang.emergency.service.impl;
|
||||||
|
|
||||||
|
import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
|
||||||
|
import com.renkang.emergency.entity.EmergencyHealthRoom;
|
||||||
|
import com.renkang.emergency.mapper.EmergencyHealthRoomMapper;
|
||||||
|
import com.renkang.emergency.service.IEmergencyHealthRoomService;
|
||||||
|
import org.springframework.stereotype.Service;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* @Description: emergency_order
|
||||||
|
* @Author: jeecg-boot
|
||||||
|
* @Date: 2023-04-26
|
||||||
|
* @Version: V1.0
|
||||||
|
*/
|
||||||
|
@Service
|
||||||
|
public class EmergencyHealthRoomServiceImpl extends ServiceImpl<EmergencyHealthRoomMapper, EmergencyHealthRoom> implements IEmergencyHealthRoomService {
|
||||||
|
|
||||||
|
}
|
||||||
+348
@@ -0,0 +1,348 @@
|
|||||||
|
package com.renkang.emergency.service.impl;
|
||||||
|
|
||||||
|
import cn.hutool.core.util.StrUtil;
|
||||||
|
import com.renkang.emergency.bean.response.*;
|
||||||
|
import com.renkang.emergency.service.IFakerDataService;
|
||||||
|
import org.jeecg.common.api.dto.*;
|
||||||
|
import org.jeecg.common.constant.FakerDataConstant;
|
||||||
|
import org.jeecg.common.exception.ExceptionAssertsUtil;
|
||||||
|
import org.jeecg.common.util.RedisUtil;
|
||||||
|
import org.springframework.beans.factory.annotation.Autowired;
|
||||||
|
import org.springframework.stereotype.Service;
|
||||||
|
|
||||||
|
import java.util.*;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* health_house_banner
|
||||||
|
*
|
||||||
|
* @author Junqiang Zhu
|
||||||
|
* @date 2024-04-11
|
||||||
|
*/
|
||||||
|
@Service
|
||||||
|
public class FakerDataServiceImpl implements IFakerDataService {
|
||||||
|
|
||||||
|
@Autowired
|
||||||
|
private RedisUtil redisUtil;
|
||||||
|
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public void createGroupUserFakerData(GroupUserFakerData data) {
|
||||||
|
redisUtil.set(FakerDataConstant.GROUP_USER, data);
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public void createMedicalCenterFakerData(MedicalCenterFakerData data) {
|
||||||
|
redisUtil.set(FakerDataConstant.MEDICAL_CENTER, data);
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public void createNutritionFakerData(NutritionFakerData data) {
|
||||||
|
redisUtil.set(FakerDataConstant.NUTRITION, data);
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public void createHealthLevelFakerData(HealthLevelFakerData data) {
|
||||||
|
redisUtil.set(FakerDataConstant.HEALTH, data);
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public void createInterveneFakerData(InterveneFakerData data) {
|
||||||
|
redisUtil.set(FakerDataConstant.INTERVENE, data);
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public void createServiceFakerData(ServiceFakerData data) {
|
||||||
|
redisUtil.set(FakerDataConstant.SERVICE, data);
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public void createMedicalFakerData(MedicalFakerData data) {
|
||||||
|
redisUtil.set(FakerDataConstant.MEDICAL, data);
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public void createBigIllFakerData(BigIllFakerData data) {
|
||||||
|
redisUtil.set(FakerDataConstant.BIG_ILL, data);
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public void createWatchFakerData(HouseWatchFakerData data) {
|
||||||
|
redisUtil.set(FakerDataConstant.WATCH, data);
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public void createWatchStressFakerData(HouseWatchStressFakerData data) {
|
||||||
|
redisUtil.set(FakerDataConstant.WATCH_STRESS, data);
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public void createYcServiceFakerData(ServiceFakerData data) {
|
||||||
|
if (StrUtil.isNotEmpty(data.getCenterId())) {
|
||||||
|
redisUtil.set(FakerDataConstant.YC_SERVICE + ":" + data.getCenterId(), data);
|
||||||
|
} else {
|
||||||
|
redisUtil.set(FakerDataConstant.YC_SERVICE, data);
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public void createYcMedicalFakerData(MedicalFakerData data) {
|
||||||
|
if (StrUtil.isNotEmpty(data.getCenterId())) {
|
||||||
|
redisUtil.set(FakerDataConstant.YC_MEDICAL + ":" + data.getCenterId(), data);
|
||||||
|
} else {
|
||||||
|
redisUtil.set(FakerDataConstant.YC_MEDICAL, data);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public void createYcMedicalCenterFakerData(List<YcMedicalCenterFakerData> data, String centerId) {
|
||||||
|
if (StrUtil.isNotEmpty(centerId)) {
|
||||||
|
redisUtil.set(FakerDataConstant.YC_MEDICAL_CENTER + ":" + centerId, data);
|
||||||
|
} else {
|
||||||
|
redisUtil.set(FakerDataConstant.YC_MEDICAL_CENTER, data);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public void createYcUserHealthFakerData(YcUserHealthFakerData data) {
|
||||||
|
if (StrUtil.isNotEmpty(data.getCenterId())) {
|
||||||
|
redisUtil.set(FakerDataConstant.YC_USER_HEALTH + ":" + data.getCenterId(), data);
|
||||||
|
} else {
|
||||||
|
redisUtil.set(FakerDataConstant.YC_USER_HEALTH, data);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public Map<Integer, Boolean> getFakerDataEnable(String centerId) {
|
||||||
|
Map<Integer, Boolean> map = new HashMap<>();
|
||||||
|
map.put(1, (Boolean) redisUtil.get(FakerDataConstant.GROUP_USER_ENABLE));
|
||||||
|
map.put(2, (Boolean) redisUtil.get(FakerDataConstant.MEDICAL_CENTER_ENABLE));
|
||||||
|
map.put(3, (Boolean) redisUtil.get(FakerDataConstant.NUTRITION_ENABLE));
|
||||||
|
map.put(4, (Boolean) redisUtil.get(FakerDataConstant.HEALTH_ENABLE));
|
||||||
|
map.put(5, (Boolean) redisUtil.get(FakerDataConstant.INTERVENE_ENABLE));
|
||||||
|
|
||||||
|
// 西安大屏相关
|
||||||
|
map.put(6, (Boolean) redisUtil.get(FakerDataConstant.SERVICE_ENABLE));
|
||||||
|
map.put(7, (Boolean) redisUtil.get(FakerDataConstant.MEDICAL_ENABLE));
|
||||||
|
map.put(8, (Boolean) redisUtil.get(FakerDataConstant.BIG_ILL_ENABLE));
|
||||||
|
|
||||||
|
// 银川大屏相关
|
||||||
|
if (StrUtil.isEmpty(centerId)) {
|
||||||
|
map.put(9, (Boolean) redisUtil.get(FakerDataConstant.YC_SERVICE_ENABLE));
|
||||||
|
map.put(10, (Boolean) redisUtil.get(FakerDataConstant.YC_MEDICAL_ENABLE));
|
||||||
|
map.put(11, (Boolean) redisUtil.get(FakerDataConstant.YC_MEDICAL_CENTER_ENABLE));
|
||||||
|
map.put(12, (Boolean) redisUtil.get(FakerDataConstant.YC_USER_HEALTH_ENABLE));
|
||||||
|
} else {
|
||||||
|
map.put(9, (Boolean) redisUtil.get(FakerDataConstant.YC_SERVICE_ENABLE + ":" + centerId));
|
||||||
|
map.put(10, (Boolean) redisUtil.get(FakerDataConstant.YC_MEDICAL_ENABLE + ":" + centerId));
|
||||||
|
map.put(11, (Boolean) redisUtil.get(FakerDataConstant.YC_MEDICAL_CENTER_ENABLE + ":" + centerId));
|
||||||
|
map.put(12, (Boolean) redisUtil.get(FakerDataConstant.YC_USER_HEALTH_ENABLE + ":" + centerId));
|
||||||
|
}
|
||||||
|
|
||||||
|
// 小屋手表数据开关
|
||||||
|
map.put(20, (Boolean) redisUtil.get(FakerDataConstant.WATCH_ENABLE));
|
||||||
|
|
||||||
|
// 小屋运动检测 压力检测
|
||||||
|
map.put(21, (Boolean) redisUtil.get(FakerDataConstant.WATCH_STRESS_ENABLE));
|
||||||
|
|
||||||
|
// 新疆大屏 主诉分类
|
||||||
|
map.put(31, (Boolean) redisUtil.get(StrUtil.isNotEmpty(centerId)
|
||||||
|
? FakerDataConstant.XJ_DEMAND_TYPE_ENABLE + ":" + centerId : FakerDataConstant.XJ_DEMAND_TYPE_ENABLE));
|
||||||
|
// 新疆大屏 体检人数统计
|
||||||
|
map.put(32, (Boolean) redisUtil.get(StrUtil.isNotEmpty(centerId)
|
||||||
|
? FakerDataConstant.XJ_MEDICAL_COUNT_ENABLE + ":" + centerId : FakerDataConstant.XJ_MEDICAL_COUNT_ENABLE));
|
||||||
|
// 新疆大屏 健康打卡数据
|
||||||
|
map.put(33, (Boolean) redisUtil.get(StrUtil.isNotEmpty(centerId)
|
||||||
|
? FakerDataConstant.XJ_HEALTH_SIGN_COUNT_ENABLE + ":" + centerId : FakerDataConstant.XJ_HEALTH_SIGN_COUNT_ENABLE));
|
||||||
|
// 新疆大屏 体检数据
|
||||||
|
map.put(34, (Boolean) redisUtil.get(StrUtil.isNotEmpty(centerId)
|
||||||
|
? FakerDataConstant.XJ_MEDICAL_DATA_ENABLE + ":" + centerId : FakerDataConstant.XJ_MEDICAL_DATA_ENABLE));
|
||||||
|
return map;
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public Object getFakerData(int module, String centerId) {
|
||||||
|
switch (module) {
|
||||||
|
case 1:
|
||||||
|
return Optional.ofNullable(getRedisData(FakerDataConstant.GROUP_USER)).orElse(new GroupUserFakerData());
|
||||||
|
case 2:
|
||||||
|
return Optional.ofNullable(getRedisData(FakerDataConstant.MEDICAL_CENTER)).orElse(new MedicalCenterFakerData());
|
||||||
|
case 3:
|
||||||
|
return Optional.ofNullable(getRedisData(FakerDataConstant.NUTRITION)).orElse(new NutritionFakerData());
|
||||||
|
case 4:
|
||||||
|
return Optional.ofNullable(getRedisData(FakerDataConstant.HEALTH)).orElse(new HealthLevelFakerData());
|
||||||
|
case 5:
|
||||||
|
return Optional.ofNullable(getRedisData(FakerDataConstant.INTERVENE)).orElse(new InterveneFakerData());
|
||||||
|
|
||||||
|
case 6:
|
||||||
|
return Optional.ofNullable(getRedisData(FakerDataConstant.SERVICE)).orElse(new ServiceFakerData());
|
||||||
|
case 7:
|
||||||
|
return Optional.ofNullable(getRedisData(FakerDataConstant.MEDICAL)).orElse(new MedicalFakerData());
|
||||||
|
case 8:
|
||||||
|
return Optional.ofNullable(getRedisData(FakerDataConstant.BIG_ILL)).orElse(new BigIllFakerData());
|
||||||
|
|
||||||
|
// 银川大屏相关
|
||||||
|
case 9:
|
||||||
|
return Optional.ofNullable(getRedisData(
|
||||||
|
StrUtil.isNotEmpty(centerId) ? FakerDataConstant.YC_SERVICE + ":" + centerId : FakerDataConstant.YC_SERVICE))
|
||||||
|
.orElse(new ServiceFakerData());
|
||||||
|
case 10:
|
||||||
|
return Optional.ofNullable(
|
||||||
|
getRedisData(StrUtil.isNotEmpty(centerId) ? FakerDataConstant.YC_MEDICAL + ":" + centerId : FakerDataConstant.YC_MEDICAL))
|
||||||
|
.orElse(new MedicalFakerData());
|
||||||
|
case 11:
|
||||||
|
return Optional.ofNullable(
|
||||||
|
getRedisData(StrUtil.isNotEmpty(centerId) ? FakerDataConstant.YC_MEDICAL_CENTER + ":" + centerId : FakerDataConstant.YC_MEDICAL_CENTER))
|
||||||
|
.orElse(Collections.emptyList());
|
||||||
|
case 12:
|
||||||
|
return Optional.ofNullable(
|
||||||
|
getRedisData(StrUtil.isNotEmpty(centerId) ? FakerDataConstant.YC_USER_HEALTH + ":" + centerId : FakerDataConstant.YC_USER_HEALTH))
|
||||||
|
.orElse(new YcUserHealthFakerData());
|
||||||
|
|
||||||
|
// 手表假数据
|
||||||
|
case 20:
|
||||||
|
return Optional.ofNullable(getRedisData(FakerDataConstant.WATCH)).orElse(new HouseWatchFakerData());
|
||||||
|
|
||||||
|
// 小屋运动 压力了
|
||||||
|
case 21:
|
||||||
|
return Optional.ofNullable(getRedisData(FakerDataConstant.WATCH_STRESS)).orElse(new HouseWatchStressFakerData());
|
||||||
|
|
||||||
|
// 新疆大屏 主诉分类
|
||||||
|
case 31:
|
||||||
|
return Optional.ofNullable(
|
||||||
|
getRedisData(StrUtil.isNotEmpty(centerId) ? FakerDataConstant.XJ_DEMAND_TYPE + ":" + centerId : FakerDataConstant.XJ_DEMAND_TYPE))
|
||||||
|
.orElse(new XjDemandTypeFakerData());
|
||||||
|
// 新疆大屏 体检人数统计
|
||||||
|
case 32:
|
||||||
|
return Optional.ofNullable(
|
||||||
|
getRedisData(StrUtil.isNotEmpty(centerId) ? FakerDataConstant.XJ_MEDICAL_COUNT + ":" + centerId : FakerDataConstant.XJ_MEDICAL_COUNT))
|
||||||
|
.orElse(new ArrayList<XjMedicalCountFakerData>());
|
||||||
|
// 新疆大屏 健康打卡数据
|
||||||
|
case 33:
|
||||||
|
return Optional.ofNullable(
|
||||||
|
getRedisData(StrUtil.isNotEmpty(centerId) ? FakerDataConstant.XJ_HEALTH_SIGN_COUNT + ":" + centerId : FakerDataConstant.XJ_HEALTH_SIGN_COUNT))
|
||||||
|
.orElse(new XjDemandTypeFakerData());
|
||||||
|
// 新疆大屏 体检数据
|
||||||
|
case 34:
|
||||||
|
return Optional.ofNullable(
|
||||||
|
getRedisData(StrUtil.isNotEmpty(centerId) ? FakerDataConstant.XJ_MEDICAL_DATA + ":" + centerId : FakerDataConstant.XJ_MEDICAL_DATA))
|
||||||
|
.orElse(new XjMedicalDataFakerData());
|
||||||
|
default:
|
||||||
|
return null;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
private Object getRedisData(String redisKey) {
|
||||||
|
return redisUtil.get(redisKey);
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public void fakerDataEnable(FakerDataEnable enable) {
|
||||||
|
switch (enable.getModule()) {
|
||||||
|
case 1:
|
||||||
|
redisUtil.set(FakerDataConstant.GROUP_USER_ENABLE, enable.getEnable());
|
||||||
|
break;
|
||||||
|
case 2:
|
||||||
|
redisUtil.set(FakerDataConstant.MEDICAL_CENTER_ENABLE, enable.getEnable());
|
||||||
|
break;
|
||||||
|
case 3:
|
||||||
|
redisUtil.set(FakerDataConstant.NUTRITION_ENABLE, enable.getEnable());
|
||||||
|
break;
|
||||||
|
case 4:
|
||||||
|
redisUtil.set(FakerDataConstant.HEALTH_ENABLE, enable.getEnable());
|
||||||
|
break;
|
||||||
|
case 5:
|
||||||
|
redisUtil.set(FakerDataConstant.INTERVENE_ENABLE, enable.getEnable());
|
||||||
|
break;
|
||||||
|
|
||||||
|
case 6:
|
||||||
|
redisUtil.set(FakerDataConstant.SERVICE_ENABLE, enable.getEnable());
|
||||||
|
break;
|
||||||
|
case 7:
|
||||||
|
redisUtil.set(FakerDataConstant.MEDICAL_ENABLE, enable.getEnable());
|
||||||
|
break;
|
||||||
|
case 8:
|
||||||
|
redisUtil.set(FakerDataConstant.BIG_ILL_ENABLE, enable.getEnable());
|
||||||
|
break;
|
||||||
|
|
||||||
|
// 银川大屏相关
|
||||||
|
case 9:
|
||||||
|
redisUtil.set(StrUtil.isNotEmpty(enable.getCenterId()) ? FakerDataConstant.YC_SERVICE_ENABLE + ":" + enable.getCenterId() : FakerDataConstant.YC_SERVICE_ENABLE, enable.getEnable());
|
||||||
|
break;
|
||||||
|
case 10:
|
||||||
|
redisUtil.set(StrUtil.isNotEmpty(enable.getCenterId()) ? FakerDataConstant.YC_MEDICAL_ENABLE + ":" + enable.getCenterId() : FakerDataConstant.YC_MEDICAL_ENABLE, enable.getEnable());
|
||||||
|
break;
|
||||||
|
case 11:
|
||||||
|
redisUtil.set(StrUtil.isNotEmpty(enable.getCenterId()) ? FakerDataConstant.YC_MEDICAL_CENTER_ENABLE + ":" + enable.getCenterId() : FakerDataConstant.YC_MEDICAL_CENTER_ENABLE, enable.getEnable());
|
||||||
|
break;
|
||||||
|
case 12:
|
||||||
|
redisUtil.set(StrUtil.isNotEmpty(enable.getCenterId()) ? FakerDataConstant.YC_USER_HEALTH_ENABLE + ":" + enable.getCenterId() : FakerDataConstant.YC_USER_HEALTH_ENABLE, enable.getEnable());
|
||||||
|
break;
|
||||||
|
|
||||||
|
// 小屋手表开关
|
||||||
|
case 20:
|
||||||
|
redisUtil.set(FakerDataConstant.WATCH_ENABLE, enable.getEnable());
|
||||||
|
// 小屋运动 压力
|
||||||
|
case 21:
|
||||||
|
redisUtil.set(FakerDataConstant.WATCH_STRESS_ENABLE, enable.getEnable());
|
||||||
|
break;
|
||||||
|
|
||||||
|
// 新疆大屏 主诉分类
|
||||||
|
case 31:
|
||||||
|
redisUtil.set(StrUtil.isNotEmpty(enable.getCenterId()) ? FakerDataConstant.XJ_DEMAND_TYPE_ENABLE + ":" + enable.getCenterId() : FakerDataConstant.XJ_DEMAND_TYPE_ENABLE, enable.getEnable());
|
||||||
|
break;
|
||||||
|
// 新疆大屏 体检人数统计
|
||||||
|
case 32:
|
||||||
|
redisUtil.set(StrUtil.isNotEmpty(enable.getCenterId()) ? FakerDataConstant.XJ_MEDICAL_COUNT_ENABLE + ":" + enable.getCenterId() : FakerDataConstant.XJ_MEDICAL_COUNT_ENABLE, enable.getEnable());
|
||||||
|
break;
|
||||||
|
// 新疆大屏 健康打卡数据
|
||||||
|
case 33:
|
||||||
|
redisUtil.set(StrUtil.isNotEmpty(enable.getCenterId()) ? FakerDataConstant.XJ_HEALTH_SIGN_COUNT_ENABLE + ":" + enable.getCenterId() : FakerDataConstant.XJ_HEALTH_SIGN_COUNT_ENABLE, enable.getEnable());
|
||||||
|
break;
|
||||||
|
// 新疆大屏 体检数据
|
||||||
|
case 34:
|
||||||
|
redisUtil.set(StrUtil.isNotEmpty(enable.getCenterId()) ? FakerDataConstant.XJ_MEDICAL_DATA_ENABLE + ":" + enable.getCenterId() : FakerDataConstant.XJ_MEDICAL_DATA_ENABLE, enable.getEnable());
|
||||||
|
break;
|
||||||
|
default:
|
||||||
|
ExceptionAssertsUtil.fail("未知模块");
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public void createXjDemandTypeFakerData(XjDemandTypeFakerData data) {
|
||||||
|
if (StrUtil.isNotEmpty(data.getCenterId())) {
|
||||||
|
redisUtil.set(FakerDataConstant.XJ_DEMAND_TYPE + ":" + data.getCenterId(), data);
|
||||||
|
} else {
|
||||||
|
redisUtil.set(FakerDataConstant.XJ_DEMAND_TYPE, data);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public void createXjMedicalCountFakerData(List<XjMedicalCountFakerData> data,String centerId) {
|
||||||
|
if (StrUtil.isNotEmpty(centerId)) {
|
||||||
|
redisUtil.set(FakerDataConstant.XJ_MEDICAL_COUNT + ":" + centerId, data);
|
||||||
|
} else {
|
||||||
|
redisUtil.set(FakerDataConstant.XJ_MEDICAL_COUNT, data);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public void createXjHealthSignCountFakerData(XjHealthSignFakerData data) {
|
||||||
|
if (StrUtil.isNotEmpty(data.getCenterId())) {
|
||||||
|
redisUtil.set(FakerDataConstant.XJ_HEALTH_SIGN_COUNT + ":" + data.getCenterId(), data);
|
||||||
|
} else {
|
||||||
|
redisUtil.set(FakerDataConstant.XJ_HEALTH_SIGN_COUNT, data);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public void createXjMedicalDataFakerData(XjMedicalDataFakerData data) {
|
||||||
|
if (StrUtil.isNotEmpty(data.getCenterId())) {
|
||||||
|
redisUtil.set(FakerDataConstant.XJ_MEDICAL_DATA + ":" + data.getCenterId(), data);
|
||||||
|
} else {
|
||||||
|
redisUtil.set(FakerDataConstant.XJ_MEDICAL_DATA, data);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
+22
-4
@@ -4,11 +4,15 @@ import cn.hutool.core.collection.CollUtil;
|
|||||||
import cn.hutool.core.util.StrUtil;
|
import cn.hutool.core.util.StrUtil;
|
||||||
import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper;
|
import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper;
|
||||||
import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
|
import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
|
||||||
|
import com.github.yulichang.wrapper.MPJLambdaWrapper;
|
||||||
import com.renkang.emergency.entity.*;
|
import com.renkang.emergency.entity.*;
|
||||||
import com.renkang.emergency.entity.dto.ResourcesAllDTO;
|
import com.renkang.emergency.entity.dto.ResourcesAllDTO;
|
||||||
|
import com.renkang.emergency.largeScreen.entity.dto.HealthRoomDTO;
|
||||||
|
import com.renkang.emergency.mapper.EmergencyHealthRoomMapper;
|
||||||
import com.renkang.emergency.mapper.TblAmbulanceGpsMapper;
|
import com.renkang.emergency.mapper.TblAmbulanceGpsMapper;
|
||||||
import com.renkang.emergency.mapper.TblBaseHospitalMapper;
|
import com.renkang.emergency.mapper.TblBaseHospitalMapper;
|
||||||
import com.renkang.emergency.service.IEmergencyCenterResourceService;
|
import com.renkang.emergency.service.IEmergencyCenterResourceService;
|
||||||
|
import com.renkang.emergency.service.IEmergencyHealthRoomService;
|
||||||
import com.renkang.emergency.service.ITblAmbulanceGpsService;
|
import com.renkang.emergency.service.ITblAmbulanceGpsService;
|
||||||
import lombok.extern.slf4j.Slf4j;
|
import lombok.extern.slf4j.Slf4j;
|
||||||
import org.jeecg.common.api.vo.Result;
|
import org.jeecg.common.api.vo.Result;
|
||||||
@@ -16,6 +20,7 @@ import org.springframework.beans.BeanUtils;
|
|||||||
import org.springframework.stereotype.Service;
|
import org.springframework.stereotype.Service;
|
||||||
|
|
||||||
import javax.annotation.Resource;
|
import javax.annotation.Resource;
|
||||||
|
import java.text.DecimalFormat;
|
||||||
import java.util.ArrayList;
|
import java.util.ArrayList;
|
||||||
import java.util.HashMap;
|
import java.util.HashMap;
|
||||||
import java.util.List;
|
import java.util.List;
|
||||||
@@ -36,6 +41,8 @@ public class TblAmbulanceGpsServiceImpl extends ServiceImpl<TblAmbulanceGpsMappe
|
|||||||
private TblBaseHospitalMapper tblBaseHospitalMapper;
|
private TblBaseHospitalMapper tblBaseHospitalMapper;
|
||||||
@Resource
|
@Resource
|
||||||
private IEmergencyCenterResourceService resourceService;
|
private IEmergencyCenterResourceService resourceService;
|
||||||
|
@Resource
|
||||||
|
private EmergencyHealthRoomMapper roomMapper;
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public List<TblBaseHospitalVo> getAllList(String lat, String lon, String type, String keys) {
|
public List<TblBaseHospitalVo> getAllList(String lat, String lon, String type, String keys) {
|
||||||
@@ -48,18 +55,28 @@ public class TblAmbulanceGpsServiceImpl extends ServiceImpl<TblAmbulanceGpsMappe
|
|||||||
search.setType(type);
|
search.setType(type);
|
||||||
}
|
}
|
||||||
List<TblBaseHospitalVo> hospitalList = tblBaseHospitalMapper.getHospitalList(search);
|
List<TblBaseHospitalVo> hospitalList = tblBaseHospitalMapper.getHospitalList(search);
|
||||||
|
MPJLambdaWrapper<EmergencyHealthRoom> wrapper = new MPJLambdaWrapper<>();
|
||||||
|
wrapper.selectAs(EmergencyHealthRoom::getId, TblBaseHospitalVo::getId);
|
||||||
|
wrapper.selectAs(EmergencyHealthRoom::getName, TblBaseHospitalVo::getName);
|
||||||
|
wrapper.selectAs(EmergencyHealthRoom::getLatitude, TblBaseHospitalVo::getLat);
|
||||||
|
wrapper.selectAs(EmergencyHealthRoom::getLongitude, TblBaseHospitalVo::getLon);
|
||||||
|
wrapper.selectAs("3", TblBaseHospitalVo::getType);
|
||||||
|
List<TblBaseHospitalVo> list = roomMapper.selectJoinList(TblBaseHospitalVo.class, wrapper);
|
||||||
|
if (CollUtil.isNotEmpty(list)) {
|
||||||
|
hospitalList.addAll(list);
|
||||||
|
}
|
||||||
Double lat1 = Double.parseDouble(lat);
|
Double lat1 = Double.parseDouble(lat);
|
||||||
Double lon1 = Double.parseDouble(lon);
|
Double lon1 = Double.parseDouble(lon);
|
||||||
List<TblBaseHospitalVo> voList = new ArrayList<>();
|
List<TblBaseHospitalVo> voList = new ArrayList<>();
|
||||||
for (TblBaseHospitalVo tblBaseHospitalVo : hospitalList) {
|
for (TblBaseHospitalVo tblBaseHospitalVo : hospitalList) {
|
||||||
if (tblBaseHospitalVo.getLat()!=null && Double.parseDouble(tblBaseHospitalVo.getLat().toString()) != 0.0 && Double.parseDouble(tblBaseHospitalVo.getLon().toString()) != 0.0) {
|
if (tblBaseHospitalVo.getLat() != null && Double.parseDouble(tblBaseHospitalVo.getLat().toString()) != 0.0 && Double.parseDouble(tblBaseHospitalVo.getLon().toString()) != 0.0) {
|
||||||
Double lat2 = Double.parseDouble(tblBaseHospitalVo.getLat().toString());
|
Double lat2 = Double.parseDouble(tblBaseHospitalVo.getLat().toString());
|
||||||
Double lng2 = Double.parseDouble(tblBaseHospitalVo.getLon().toString());
|
Double lng2 = Double.parseDouble(tblBaseHospitalVo.getLon().toString());
|
||||||
Double distance = getDistance(lat1, lon1, lat2, lng2);
|
Double distance = getDistance(lat1, lon1, lat2, lng2);
|
||||||
if (distance > 1000d) {
|
if (distance > 1000d) {
|
||||||
tblBaseHospitalVo.setDistance(Math.round((distance / 1000d) * 100) / 100 + "km");
|
tblBaseHospitalVo.setDistance((int) (distance / 1000d) + "km");
|
||||||
} else {
|
} else {
|
||||||
tblBaseHospitalVo.setDistance(Math.round(distance * 100) / 100 + "m");
|
tblBaseHospitalVo.setDistance((int) (distance * 1) + "m");
|
||||||
}
|
}
|
||||||
voList.add(tblBaseHospitalVo);
|
voList.add(tblBaseHospitalVo);
|
||||||
}
|
}
|
||||||
@@ -86,7 +103,7 @@ public class TblAmbulanceGpsServiceImpl extends ServiceImpl<TblAmbulanceGpsMappe
|
|||||||
double lon1 = Double.parseDouble(dto.getLon());
|
double lon1 = Double.parseDouble(dto.getLon());
|
||||||
List<TblBaseHospitalVo> voList = new ArrayList<>();
|
List<TblBaseHospitalVo> voList = new ArrayList<>();
|
||||||
for (TblBaseHospitalVo tblBaseHospitalVo : hospitalList) {
|
for (TblBaseHospitalVo tblBaseHospitalVo : hospitalList) {
|
||||||
if (tblBaseHospitalVo.getLat()!=null && Double.parseDouble(tblBaseHospitalVo.getLat().toString()) != 0.0 && Double.parseDouble(tblBaseHospitalVo.getLon().toString()) != 0.0) {
|
if (tblBaseHospitalVo.getLat() != null && Double.parseDouble(tblBaseHospitalVo.getLat().toString()) != 0.0 && Double.parseDouble(tblBaseHospitalVo.getLon().toString()) != 0.0) {
|
||||||
double lat2 = Double.parseDouble(tblBaseHospitalVo.getLat().toString());
|
double lat2 = Double.parseDouble(tblBaseHospitalVo.getLat().toString());
|
||||||
double lng2 = Double.parseDouble(tblBaseHospitalVo.getLon().toString());
|
double lng2 = Double.parseDouble(tblBaseHospitalVo.getLon().toString());
|
||||||
double distance = getDistance(lat1, lon1, lat2, lng2);
|
double distance = getDistance(lat1, lon1, lat2, lng2);
|
||||||
@@ -103,6 +120,7 @@ public class TblAmbulanceGpsServiceImpl extends ServiceImpl<TblAmbulanceGpsMappe
|
|||||||
|
|
||||||
/**
|
/**
|
||||||
* 获取救护车gps信息
|
* 获取救护车gps信息
|
||||||
|
*
|
||||||
* @return
|
* @return
|
||||||
*/
|
*/
|
||||||
@Override
|
@Override
|
||||||
|
|||||||
+39
-1
@@ -1,15 +1,22 @@
|
|||||||
package com.renkang.emergency.service.impl;
|
package com.renkang.emergency.service.impl;
|
||||||
|
|
||||||
|
import cn.hutool.core.util.StrUtil;
|
||||||
import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
|
import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
|
||||||
import com.renkang.emergency.api.service.EmergencyOrderApiService;
|
import com.renkang.emergency.api.service.EmergencyOrderApiService;
|
||||||
|
import com.renkang.emergency.bean.response.XjDemandTypeFakerData;
|
||||||
import com.renkang.emergency.entity.TblHelpCenter;
|
import com.renkang.emergency.entity.TblHelpCenter;
|
||||||
import com.renkang.emergency.entity.TblHelpCentorVo;
|
import com.renkang.emergency.entity.TblHelpCentorVo;
|
||||||
|
import com.renkang.emergency.entity.TblUserHelpVo;
|
||||||
import com.renkang.emergency.mapper.TblHelpCenterMapper;
|
import com.renkang.emergency.mapper.TblHelpCenterMapper;
|
||||||
import com.renkang.emergency.service.ITbHelpCenterService;
|
import com.renkang.emergency.service.ITbHelpCenterService;
|
||||||
import lombok.extern.slf4j.Slf4j;
|
import lombok.extern.slf4j.Slf4j;
|
||||||
|
import org.jeecg.common.api.dto.ServiceFakerData;
|
||||||
|
import org.jeecg.common.constant.FakerDataConstant;
|
||||||
|
import org.jeecg.common.util.RedisUtil;
|
||||||
import org.springframework.stereotype.Service;
|
import org.springframework.stereotype.Service;
|
||||||
|
|
||||||
import javax.annotation.Resource;
|
import javax.annotation.Resource;
|
||||||
|
import java.util.ArrayList;
|
||||||
import java.util.List;
|
import java.util.List;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
@@ -22,6 +29,8 @@ public class TblHelpCenterServiceImpl extends ServiceImpl<TblHelpCenterMapper, T
|
|||||||
|
|
||||||
@Resource
|
@Resource
|
||||||
private EmergencyOrderApiService emergencyOrderApiService;
|
private EmergencyOrderApiService emergencyOrderApiService;
|
||||||
|
@Resource
|
||||||
|
private RedisUtil redisUtil;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* 主诉分类统计
|
* 主诉分类统计
|
||||||
@@ -30,7 +39,14 @@ public class TblHelpCenterServiceImpl extends ServiceImpl<TblHelpCenterMapper, T
|
|||||||
* @return
|
* @return
|
||||||
*/
|
*/
|
||||||
@Override
|
@Override
|
||||||
public List<TblHelpCentorVo> sicknessTypeStatistic(String sex, String depart) {
|
public List<TblHelpCentorVo> sicknessTypeStatistic(String sex, String depart,String centerId) {
|
||||||
|
Boolean enable = (Boolean) redisUtil.get(StrUtil.isNotEmpty(centerId) ? FakerDataConstant.XJ_DEMAND_TYPE_ENABLE + ":" + centerId : FakerDataConstant.XJ_DEMAND_TYPE_ENABLE);
|
||||||
|
if (enable != null && enable) {
|
||||||
|
List<TblHelpCentorVo> vo = XjDemandTypeFakerData(centerId);
|
||||||
|
if (vo != null) {
|
||||||
|
return vo;
|
||||||
|
}
|
||||||
|
}
|
||||||
List<TblHelpCentorVo> statistic = emergencyOrderApiService.getSicknessTypeStatistic(sex, depart);
|
List<TblHelpCentorVo> statistic = emergencyOrderApiService.getSicknessTypeStatistic(sex, depart);
|
||||||
for (TblHelpCentorVo tblHelpCentorVo : statistic) {
|
for (TblHelpCentorVo tblHelpCentorVo : statistic) {
|
||||||
if (tblHelpCentorVo.getType().equals("0")) {
|
if (tblHelpCentorVo.getType().equals("0")) {
|
||||||
@@ -45,4 +61,26 @@ public class TblHelpCenterServiceImpl extends ServiceImpl<TblHelpCenterMapper, T
|
|||||||
}
|
}
|
||||||
return statistic;
|
return statistic;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
private List<TblHelpCentorVo> XjDemandTypeFakerData(String centerId) {
|
||||||
|
try {
|
||||||
|
List<TblHelpCentorVo> voList = new ArrayList<>();
|
||||||
|
XjDemandTypeFakerData data = (XjDemandTypeFakerData) redisUtil.get(StrUtil.isNotEmpty(centerId) ?
|
||||||
|
FakerDataConstant.XJ_DEMAND_TYPE + ":" + centerId : FakerDataConstant.XJ_DEMAND_TYPE);
|
||||||
|
|
||||||
|
TblHelpCentorVo vo1 = new TblHelpCentorVo();
|
||||||
|
vo1.setCount(Integer.valueOf(data.getHospitalCount()));
|
||||||
|
vo1.setName("120");
|
||||||
|
vo1.setType("0");
|
||||||
|
voList.add(vo1);
|
||||||
|
TblHelpCentorVo vo2 = new TblHelpCentorVo();
|
||||||
|
vo2.setCount(Integer.valueOf(data.getEmergencyCount()));
|
||||||
|
vo2.setName("应急就医");
|
||||||
|
vo2.setType("1");
|
||||||
|
voList.add(vo2);
|
||||||
|
return voList;
|
||||||
|
} catch (Exception e) {
|
||||||
|
return null;
|
||||||
|
}
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -0,0 +1,22 @@
|
|||||||
|
FROM anapsix/alpine-java:8_server-jre_unlimited
|
||||||
|
|
||||||
|
ENV PROFILE_NAME=dev \
|
||||||
|
SERVER_PORT=7011 \
|
||||||
|
NACOS_SERVER_ADDR=nacos250:8848 \
|
||||||
|
NACOS_USERNAME=xjuser \
|
||||||
|
NACOS_PASSWORD=Aa135790!123 \
|
||||||
|
NACOS_NAMESPACE=3af98a54-4a44-4576-8e28-bf5781c0dccf \
|
||||||
|
NACOS_GROUP=dev
|
||||||
|
|
||||||
|
|
||||||
|
RUN ln -sf /usr/share/zoneinfo/Asia/Shanghai /etc/localtime
|
||||||
|
|
||||||
|
RUN mkdir -p /health-emergency-start
|
||||||
|
|
||||||
|
WORKDIR /health-emergency-start
|
||||||
|
|
||||||
|
EXPOSE 7011
|
||||||
|
|
||||||
|
COPY ./target/health-emergency-start-xj.jar ./
|
||||||
|
|
||||||
|
CMD sleep 1;java -Dfile.encoding=utf-8 -Djava.security.egd=file:/dev/./urandom -jar health-emergency-start-xj.jar
|
||||||
@@ -9,6 +9,11 @@
|
|||||||
<modelVersion>4.0.0</modelVersion>
|
<modelVersion>4.0.0</modelVersion>
|
||||||
|
|
||||||
<artifactId>health-emergency-start</artifactId>
|
<artifactId>health-emergency-start</artifactId>
|
||||||
|
|
||||||
|
<properties>
|
||||||
|
<maven.install.skip>true</maven.install.skip>
|
||||||
|
</properties>
|
||||||
|
|
||||||
<dependencies>
|
<dependencies>
|
||||||
<!--微服务启动 starter-->
|
<!--微服务启动 starter-->
|
||||||
<dependency>
|
<dependency>
|
||||||
@@ -20,6 +25,7 @@
|
|||||||
<dependency>
|
<dependency>
|
||||||
<groupId>com.renkang</groupId>
|
<groupId>com.renkang</groupId>
|
||||||
<artifactId>health-emergency-biz</artifactId>
|
<artifactId>health-emergency-biz</artifactId>
|
||||||
|
<classifier>${biz-classifier}</classifier>
|
||||||
</dependency>
|
</dependency>
|
||||||
|
|
||||||
</dependencies>
|
</dependencies>
|
||||||
|
|||||||
@@ -13,10 +13,6 @@
|
|||||||
<version>2.0.0</version>
|
<version>2.0.0</version>
|
||||||
<packaging>pom</packaging>
|
<packaging>pom</packaging>
|
||||||
|
|
||||||
<properties>
|
|
||||||
<maven.install.skip>true</maven.install.skip>
|
|
||||||
</properties>
|
|
||||||
|
|
||||||
<!--项目子模块-->
|
<!--项目子模块-->
|
||||||
<modules>
|
<modules>
|
||||||
<module>health-emergency-api</module>
|
<module>health-emergency-api</module>
|
||||||
|
|||||||
Some files were not shown because too many files have changed in this diff Show More
Reference in New Issue
Block a user