Skip to content
项目
群组
代码片段
帮助
正在加载...
登录
切换导航
B
byh-family-doctor
项目
项目
详情
活动
周期分析
仓库
仓库
文件
提交
分支
标签
贡献者
分枝图
比较
统计图
议题
0
议题
0
列表
看板
标记
里程碑
合并请求
0
合并请求
0
CI / CD
CI / CD
流水线
作业
日程
统计图
包
包
Wiki
Wiki
代码片段
代码片段
成员
成员
折叠边栏
关闭边栏
活动
分枝图
统计图
创建新议题
作业
提交
议题看板
打开侧边栏
杨凯
byh-family-doctor
Commits
fb4a91aa
提交
fb4a91aa
authored
5月 17, 2024
作者:
luzhangjian
浏览文件
操作
浏览文件
下载
电子邮件补丁
差异文件
feat:病例相关接口
上级
30fe4858
全部展开
显示空白字符变更
内嵌
并排
正在显示
11 个修改的文件
包含
563 行增加
和
43 行删除
+563
-43
InvalidMedicalRecordDTO.java
...hui/family/doctor/common/dto/InvalidMedicalRecordDTO.java
+3
-3
ImInfoDetailDocResVo.java
...aiyihui/family/doctor/common/vo/ImInfoDetailDocResVo.java
+3
-0
MedicalSortVo.java
.../com/ebaiyihui/family/doctor/common/vo/MedicalSortVo.java
+31
-0
TreatmentCard.java
.../com/ebaiyihui/family/doctor/common/vo/TreatmentCard.java
+26
-0
PatientMedicalRecordController.java
...tor/server/controller/PatientMedicalRecordController.java
+20
-9
PatientMedicalRecordMapper.java
...mily/doctor/server/mapper/PatientMedicalRecordMapper.java
+3
-0
PatientMedicalRecordService.java
...ly/doctor/server/service/PatientMedicalRecordService.java
+3
-2
RedisTemplateService.java
...ui/family/doctor/server/service/RedisTemplateService.java
+76
-0
PatientMedicalRecordServiceImpl.java
.../server/service/impl/PatientMedicalRecordServiceImpl.java
+327
-29
PatientSignServiceImpl.java
...ly/doctor/server/service/impl/PatientSignServiceImpl.java
+1
-0
RedisTemplateServiceImpl.java
.../doctor/server/service/impl/RedisTemplateServiceImpl.java
+70
-0
没有找到文件。
family-doctor-common/src/main/java/com/ebaiyihui/family/doctor/common/dto/InvalidMedicalRecordDTO.java
浏览文件 @
fb4a91aa
...
@@ -8,8 +8,8 @@ import javax.validation.constraints.NotBlank;
...
@@ -8,8 +8,8 @@ import javax.validation.constraints.NotBlank;
@Data
@Data
public
class
InvalidMedicalRecordDTO
{
public
class
InvalidMedicalRecordDTO
{
@NotBlank
(
message
=
"
病历ID
不能为空"
)
@NotBlank
(
message
=
"
就诊id
不能为空"
)
@ApiModelProperty
(
"
病历ID
"
)
@ApiModelProperty
(
"
就诊id
"
)
private
String
i
d
;
private
String
admI
d
;
}
}
family-doctor-common/src/main/java/com/ebaiyihui/family/doctor/common/vo/ImInfoDetailDocResVo.java
浏览文件 @
fb4a91aa
...
@@ -32,6 +32,9 @@ public class ImInfoDetailDocResVo {
...
@@ -32,6 +32,9 @@ public class ImInfoDetailDocResVo {
@ApiModelProperty
(
"就诊id"
)
@ApiModelProperty
(
"就诊id"
)
private
String
admId
;
private
String
admId
;
@ApiModelProperty
(
"就诊日期"
)
private
Date
admTime
;
@ApiModelProperty
(
"订单状态 2.进行中 3.已完成"
)
@ApiModelProperty
(
"订单状态 2.进行中 3.已完成"
)
private
Integer
status
;
private
Integer
status
;
...
...
family-doctor-common/src/main/java/com/ebaiyihui/family/doctor/common/vo/MedicalSortVo.java
0 → 100644
浏览文件 @
fb4a91aa
package
com
.
ebaiyihui
.
family
.
doctor
.
common
.
vo
;
import
io.swagger.annotations.ApiModelProperty
;
import
lombok.Data
;
/**
* @author odd$
* @description: $
* @param: $
* @return: $
* @date: $ $
*/
@Data
public
class
MedicalSortVo
{
@ApiModelProperty
(
"病例记录name"
)
private
String
titleContent
;
@ApiModelProperty
(
"病例记录值"
)
private
Object
value
;
@ApiModelProperty
(
"展示顺序"
)
private
Integer
sort
;
@ApiModelProperty
(
"模块类型"
)
private
Integer
inputType
;
@ApiModelProperty
(
"是否展示在病历卡片"
)
private
Integer
isCard
;
@ApiModelProperty
(
"展示信息类型"
)
private
Integer
titleType
;
@ApiModelProperty
(
"是否为空"
)
private
Integer
isNull
;
@ApiModelProperty
(
"数据key信息"
)
private
String
keywords
;
}
family-doctor-common/src/main/java/com/ebaiyihui/family/doctor/common/vo/TreatmentCard.java
0 → 100644
浏览文件 @
fb4a91aa
package
com
.
ebaiyihui
.
family
.
doctor
.
common
.
vo
;
import
io.swagger.annotations.ApiModelProperty
;
import
lombok.Data
;
import
lombok.ToString
;
import
java.util.List
;
/**
* @program: byh_online_outpatient
* @description:
* @author: zhaosiyi
* @create: 2020-11-03 10:32
**/
@Data
@ToString
public
class
TreatmentCard
{
@ApiModelProperty
(
"复诊病例Id"
)
private
String
medicalRecordId
;
@ApiModelProperty
(
"展示在卡片上的数据"
)
List
<
MedicalSortVo
>
medicalUserFills
;
}
family-doctor-server/src/main/java/com/ebaiyihui/family/doctor/server/controller/PatientMedicalRecordController.java
浏览文件 @
fb4a91aa
...
@@ -13,10 +13,7 @@ import io.swagger.annotations.ApiOperation;
...
@@ -13,10 +13,7 @@ import io.swagger.annotations.ApiOperation;
import
org.springframework.beans.factory.annotation.Autowired
;
import
org.springframework.beans.factory.annotation.Autowired
;
import
org.springframework.validation.BindingResult
;
import
org.springframework.validation.BindingResult
;
import
org.springframework.validation.annotation.Validated
;
import
org.springframework.validation.annotation.Validated
;
import
org.springframework.web.bind.annotation.PostMapping
;
import
org.springframework.web.bind.annotation.*
;
import
org.springframework.web.bind.annotation.RequestBody
;
import
org.springframework.web.bind.annotation.RequestMapping
;
import
org.springframework.web.bind.annotation.RestController
;
import
java.util.Objects
;
import
java.util.Objects
;
...
@@ -48,14 +45,14 @@ public class PatientMedicalRecordController {
...
@@ -48,14 +45,14 @@ public class PatientMedicalRecordController {
return
patientMedicalRecordService
.
updatePatientMedicalRecord
(
dto
);
return
patientMedicalRecordService
.
updatePatientMedicalRecord
(
dto
);
}
}
@PostMapping
(
"/in
valid
"
)
@PostMapping
(
"/in
sertOrUpdate
"
)
@ApiOperation
(
value
=
"
开具处方失效病历"
,
notes
=
"开具处方失效
病历"
)
@ApiOperation
(
value
=
"
新建或修改复诊病历"
,
notes
=
"新建或修改复诊
病历"
)
public
BaseResponse
<
Objects
>
invalid
(
@RequestBody
@Validated
Invalid
MedicalRecordDTO
dto
,
public
BaseResponse
<
InsertPatientMedicalRecordVO
>
insertOrUpdate
(
@RequestBody
@Validated
InsertPatient
MedicalRecordDTO
dto
,
BindingResult
bindingResult
)
{
BindingResult
bindingResult
)
{
if
(
bindingResult
.
hasErrors
())
{
if
(
bindingResult
.
hasErrors
())
{
return
BaseResponse
.
error
(
Objects
.
requireNonNull
(
bindingResult
.
getFieldError
()).
getDefaultMessage
());
return
BaseResponse
.
error
(
Objects
.
requireNonNull
(
bindingResult
.
getFieldError
()).
getDefaultMessage
());
}
}
return
patientMedicalRecordService
.
in
validMedicalRecord
(
dto
);
return
patientMedicalRecordService
.
in
sertOrUpdate
(
dto
);
}
}
@PostMapping
(
"/detail"
)
@PostMapping
(
"/detail"
)
...
@@ -68,4 +65,18 @@ public class PatientMedicalRecordController {
...
@@ -68,4 +65,18 @@ public class PatientMedicalRecordController {
return
patientMedicalRecordService
.
detailMedicalRecord
(
dto
);
return
patientMedicalRecordService
.
detailMedicalRecord
(
dto
);
}
}
@ApiOperation
(
value
=
"推送病例卡片"
,
notes
=
"医生开具复诊病例推送小卡片"
)
@RequestMapping
(
value
=
"/treatmentCard"
,
method
=
RequestMethod
.
POST
)
public
BaseResponse
<
Object
>
treatmentCard
(
@RequestBody
@Validated
InvalidMedicalRecordDTO
param
,
BindingResult
bindingResult
)
{
if
(
bindingResult
.
hasErrors
())
{
return
BaseResponse
.
error
(
Objects
.
requireNonNull
(
bindingResult
.
getFieldError
()).
getDefaultMessage
());
}
return
patientMedicalRecordService
.
treatmentCard
(
param
.
getAdmId
());
}
}
}
family-doctor-server/src/main/java/com/ebaiyihui/family/doctor/server/mapper/PatientMedicalRecordMapper.java
浏览文件 @
fb4a91aa
...
@@ -11,4 +11,7 @@ public interface PatientMedicalRecordMapper extends BaseMapper<PatientMedicalRec
...
@@ -11,4 +11,7 @@ public interface PatientMedicalRecordMapper extends BaseMapper<PatientMedicalRec
@Select
(
"select * from patient_medical_record where id = #{id} and record_status = #{status}"
)
@Select
(
"select * from patient_medical_record where id = #{id} and record_status = #{status}"
)
PatientMedicalRecordEntity
getByIdAndStatus
(
String
id
,
int
status
);
PatientMedicalRecordEntity
getByIdAndStatus
(
String
id
,
int
status
);
@Select
(
"select * from patient_medical_record where adm_id = #{id} and record_status = 1"
)
PatientMedicalRecordEntity
getByAdmId
(
String
admId
);
}
}
family-doctor-server/src/main/java/com/ebaiyihui/family/doctor/server/service/PatientMedicalRecordService.java
浏览文件 @
fb4a91aa
...
@@ -19,8 +19,9 @@ public interface PatientMedicalRecordService {
...
@@ -19,8 +19,9 @@ public interface PatientMedicalRecordService {
BaseResponse
<
InsertPatientMedicalRecordVO
>
updatePatientMedicalRecord
(
UpdatePatientMedicalRecordDTO
dto
);
BaseResponse
<
InsertPatientMedicalRecordVO
>
updatePatientMedicalRecord
(
UpdatePatientMedicalRecordDTO
dto
);
BaseResponse
<
Objects
>
invalidMedicalRecord
(
InvalidMedicalRecordDTO
dto
);
BaseResponse
<
PatientMedicalRecordVO
>
detailMedicalRecord
(
InvalidMedicalRecordDTO
dto
);
BaseResponse
<
PatientMedicalRecordVO
>
detailMedicalRecord
(
InvalidMedicalRecordDTO
dto
);
BaseResponse
<
InsertPatientMedicalRecordVO
>
insertOrUpdate
(
InsertPatientMedicalRecordDTO
dto
);
BaseResponse
<
Object
>
treatmentCard
(
String
admId
);
}
}
family-doctor-server/src/main/java/com/ebaiyihui/family/doctor/server/service/RedisTemplateService.java
0 → 100644
浏览文件 @
fb4a91aa
package
com
.
ebaiyihui
.
family
.
doctor
.
server
.
service
;
/**
* @program byh-aggregation-payment
* @description:
* @author: chenmet
* @create: 2019/08/21 15:30
*/
public
interface
RedisTemplateService
{
/**
* Description: 根据key获取值
* @param key
* @return: boolean
* @author: zhaosy
* @date: 2019/10/29 2:06 PM
*/
boolean
get
(
String
key
);
/**
* Description: 根据key来set数据
* @param key
* @return: void
* @author: zhaosy
* @date: 2019/10/29 2:07 PM
*/
void
set
(
String
key
);
/**
* Description: 根据key删除值
* @param key
* @return: boolean
* @author: zhaosy
* @date: 2019/10/29 2:08 PM
*/
boolean
del
(
String
key
);
/**
* Description: 根据key获取redis中的时间
* @param key
* @return: Long
* @author: zhaosy
* @date: 2019/10/29 2:08 PM
*/
Long
getTime
(
String
key
);
/**
* Description: 给redis设置锁,以及锁的过期时间
* @param key
* @param value
* @param time
* @return: boolean
* @author: zhaosy
* @date: 2019/10/29 2:09PM
*/
boolean
addLock
(
String
key
,
String
value
,
long
time
);
boolean
addLockNew
(
String
key
,
String
value
,
long
time
);
/**
* Description: 加锁
* @param key
* @param value
* @return: boolean
*/
boolean
addLock
(
String
key
,
String
value
);
/**
* Description: 判断redis中是否有锁
* @param key
* @return: boolean
* @author: zhaosy
* @date: 2019/10/29 2:11 PM
*/
boolean
hasKey
(
String
key
);
}
\ No newline at end of file
family-doctor-server/src/main/java/com/ebaiyihui/family/doctor/server/service/impl/PatientMedicalRecordServiceImpl.java
浏览文件 @
fb4a91aa
差异被折叠。
点击展开。
family-doctor-server/src/main/java/com/ebaiyihui/family/doctor/server/service/impl/PatientSignServiceImpl.java
浏览文件 @
fb4a91aa
...
@@ -231,6 +231,7 @@ public class PatientSignServiceImpl implements PatientSignService {
...
@@ -231,6 +231,7 @@ public class PatientSignServiceImpl implements PatientSignService {
resVo
.
setDeptId
(
patientSignEntity
.
getDeptId
().
toString
());
resVo
.
setDeptId
(
patientSignEntity
.
getDeptId
().
toString
());
resVo
.
setDeptName
(
patientSignEntity
.
getDeptName
());
resVo
.
setDeptName
(
patientSignEntity
.
getDeptName
());
resVo
.
setSignEndTime
(
patientSignEntity
.
getSignEndTime
());
resVo
.
setSignEndTime
(
patientSignEntity
.
getSignEndTime
());
resVo
.
setAdmTime
(
patientSignEntity
.
getSignEndTime
());
//患者信息
//患者信息
PatientEntity
patientEntity
=
patientMapper
.
selectById
(
patientSignEntity
.
getPatientId
());
PatientEntity
patientEntity
=
patientMapper
.
selectById
(
patientSignEntity
.
getPatientId
());
...
...
family-doctor-server/src/main/java/com/ebaiyihui/family/doctor/server/service/impl/RedisTemplateServiceImpl.java
0 → 100644
浏览文件 @
fb4a91aa
package
com
.
ebaiyihui
.
family
.
doctor
.
server
.
service
.
impl
;
import
com.ebaiyihui.family.doctor.server.service.RedisTemplateService
;
import
lombok.extern.slf4j.Slf4j
;
import
org.springframework.beans.factory.annotation.Autowired
;
import
org.springframework.data.redis.core.StringRedisTemplate
;
import
org.springframework.stereotype.Service
;
import
java.util.concurrent.TimeUnit
;
/**
* @program byh-aggregation-payment
* @description:
* @author: chenmet
* @create: 2019/08/21 15:31
*/
@Service
@Slf4j
public
class
RedisTemplateServiceImpl
implements
RedisTemplateService
{
@Autowired
StringRedisTemplate
stringRedisTemplate
;
@Override
public
boolean
get
(
String
key
)
{
return
stringRedisTemplate
.
hasKey
(
key
);
}
@Override
public
void
set
(
String
key
)
{
stringRedisTemplate
.
opsForValue
().
set
(
key
,
key
,
30
,
TimeUnit
.
SECONDS
);
}
@Override
public
boolean
del
(
String
key
)
{
return
stringRedisTemplate
.
delete
(
key
);
}
@Override
public
Long
getTime
(
String
key
)
{
return
stringRedisTemplate
.
getExpire
(
key
,
TimeUnit
.
SECONDS
);
}
@Override
public
boolean
addLock
(
String
key
,
String
value
,
long
time
)
{
return
stringRedisTemplate
.
opsForValue
().
setIfAbsent
(
key
,
value
);
}
//有锁:true 没锁:false
@Override
public
synchronized
boolean
addLockNew
(
String
key
,
String
value
,
long
time
)
{
boolean
flag
=
true
;
if
(!
get
(
key
)){
stringRedisTemplate
.
opsForValue
().
set
(
key
,
value
,
time
,
TimeUnit
.
SECONDS
);
return
false
;
}
return
flag
;
}
@Override
public
boolean
addLock
(
String
key
,
String
value
)
{
return
stringRedisTemplate
.
opsForValue
().
setIfAbsent
(
key
,
value
);
}
@Override
public
boolean
hasKey
(
String
key
)
{
return
stringRedisTemplate
.
hasKey
(
key
);
}
}
\ No newline at end of file
编写
预览
Markdown
格式
0%
重试
或
添加新文件
添加附件
取消
您添加了
0
人
到此讨论。请谨慎行事。
请先完成此评论的编辑!
取消
请
注册
或者
登录
后发表评论