Skip to content
项目
群组
代码片段
帮助
正在加载...
登录
切换导航
B
byh-family-doctor
项目
项目
详情
活动
周期分析
仓库
仓库
文件
提交
分支
标签
贡献者
分枝图
比较
统计图
议题
0
议题
0
列表
看板
标记
里程碑
合并请求
0
合并请求
0
CI / CD
CI / CD
流水线
作业
日程
统计图
包
包
Wiki
Wiki
代码片段
代码片段
成员
成员
折叠边栏
关闭边栏
活动
分枝图
统计图
创建新议题
作业
提交
议题看板
打开侧边栏
杨凯
byh-family-doctor
Commits
8c94e4cb
提交
8c94e4cb
authored
3月 20, 2024
作者:
杨凯
浏览文件
操作
浏览文件
下载
电子邮件补丁
差异文件
feat:家庭医生初始化
上级
49091521
显示空白字符变更
内嵌
并排
正在显示
5 个修改的文件
包含
28 行增加
和
6 行删除
+28
-6
SendImMsgDTO.java
.../com/ebaiyihui/family/doctor/common/dto/SendImMsgDTO.java
+3
-0
ImChatTemplate.java
...baiyihui/family/doctor/server/service/ImChatTemplate.java
+1
-1
ImChatTemplateImpl.java
...family/doctor/server/service/impl/ImChatTemplateImpl.java
+7
-4
ImMsgTemplateServiceImpl.java
.../doctor/server/service/impl/ImMsgTemplateServiceImpl.java
+1
-1
PatientServiceImpl.java
...family/doctor/server/service/impl/PatientServiceImpl.java
+16
-0
没有找到文件。
family-doctor-common/src/main/java/com/ebaiyihui/family/doctor/common/dto/SendImMsgDTO.java
浏览文件 @
8c94e4cb
...
...
@@ -21,6 +21,9 @@ public class SendImMsgDTO {
@ApiModelProperty
(
value
=
"医院编码"
)
private
Long
organId
;
@ApiModelProperty
(
value
=
"签约编号"
)
private
String
oldAdmId
;
@ApiModelProperty
(
value
=
"签约编号"
)
private
String
admId
;
}
family-doctor-server/src/main/java/com/ebaiyihui/family/doctor/server/service/ImChatTemplate.java
浏览文件 @
8c94e4cb
...
...
@@ -29,5 +29,5 @@ public interface ImChatTemplate {
void
doctorPrompted
(
String
admId
);
Boolean
sendMsg
(
List
<
Components
>
componentsList
,
String
admId
);
Boolean
sendMsg
(
List
<
Components
>
componentsList
,
String
oldAdmId
,
String
admId
);
}
family-doctor-server/src/main/java/com/ebaiyihui/family/doctor/server/service/impl/ImChatTemplateImpl.java
浏览文件 @
8c94e4cb
...
...
@@ -142,20 +142,23 @@ public class ImChatTemplateImpl implements ImChatTemplate {
}
@Override
public
Boolean
sendMsg
(
List
<
Components
>
componentsList
,
String
admId
)
{
public
Boolean
sendMsg
(
List
<
Components
>
componentsList
,
String
oldAdmId
,
String
admId
)
{
Boolean
flag
=
false
;
if
(!
componentsList
.
isEmpty
())
{
log
.
info
(
"componentsList={}"
,
componentsList
);
log
.
info
(
"componentsList={}"
,
componentsList
);
for
(
int
i
=
0
;
i
<=
componentsList
.
size
();
i
++)
{
String
content
=
componentsList
.
get
(
i
).
getContent
();
List
<
MessageInfo
>
messageInfos
=
new
ArrayList
<>();
PatientSignInfo
patientSignInfo
=
getPatientSignInfo
(
admId
);
MessageInfo
messageInfo
=
new
MessageInfo
();
if
(
SenderEnum
.
DOCTOR
.
getDesc
().
equals
(
componentsList
.
get
(
i
).
getSender
()))
{
content
=
MessageFormat
.
format
(
content
,
patientSignInfo
.
getDoctorName
());
if
(!
StringUtils
.
isEmpty
(
oldAdmId
))
{
PatientSignInfo
oldPatientSignInfo
=
getPatientSignInfo
(
oldAdmId
);
content
=
MessageFormat
.
format
(
content
,
oldPatientSignInfo
.
getDoctorName
(),
patientSignInfo
.
getDoctorName
());
}
if
(
SenderEnum
.
DOCTOR
.
getDesc
().
equals
(
componentsList
.
get
(
i
).
getSender
()))
{
messageInfo
=
getDoctorInformRefreshPatientParam
(
patientSignInfo
,
IMInformConstants
.
REFRESH
);
}
else
{
content
=
MessageFormat
.
format
(
content
,
patientSignInfo
.
getPatientName
());
messageInfo
=
getInformRefreshPatientParam
(
patientSignInfo
,
IMInformConstants
.
REFRESH
);
}
messageInfos
.
add
(
messageInfo
);
...
...
family-doctor-server/src/main/java/com/ebaiyihui/family/doctor/server/service/impl/ImMsgTemplateServiceImpl.java
浏览文件 @
8c94e4cb
...
...
@@ -48,7 +48,7 @@ public class ImMsgTemplateServiceImpl implements ImMsgTemplateService {
String
components
=
imMsgTemplateEntity
.
getContent
();
MsgContent
msgContent
=
JSON
.
parseObject
(
components
,
MsgContent
.
class
);
List
<
Components
>
componentsList
=
msgContent
.
getComponents
().
stream
().
sorted
(
Comparator
.
comparing
(
Components:
:
getSort
)).
collect
(
Collectors
.
toList
());
Boolean
flag
=
imChatTemplate
.
sendMsg
(
componentsList
,
reqVo
.
getAdmId
());
Boolean
flag
=
imChatTemplate
.
sendMsg
(
componentsList
,
reqVo
.
get
OldAdmId
(),
reqVo
.
get
AdmId
());
if
(!
flag
)
{
throw
new
BusinessException
(
"消息推送失败"
);
}
...
...
family-doctor-server/src/main/java/com/ebaiyihui/family/doctor/server/service/impl/PatientServiceImpl.java
浏览文件 @
8c94e4cb
...
...
@@ -140,6 +140,22 @@ public class PatientServiceImpl implements PatientService {
notifyConsultDataDTO
.
setOrderDate
(
DateUtils
.
dateToFullString
(
patientSignEntity
.
getCreateTime
()));
thirdOrderPushUtil
.
syncBenefitUsedOrder
(
notifyConsultDataDTO
);
}
else
{
QueryWrapper
<
PatientSignEntity
>
psWrapper
=
new
QueryWrapper
<>();
PatientSignEntity
patientSign
=
new
PatientSignEntity
();
if
(
Objects
.
nonNull
(
reqVo
.
getPhone
()))
{
patientSign
.
setPatientPhone
(
reqVo
.
getPhone
());
}
psWrapper
.
setEntity
(
patientSign
);
if
(
Objects
.
nonNull
(
reqVo
.
getPhone
()))
{
psWrapper
.
orderByDesc
(
"createTime"
);
psWrapper
.
last
(
"limit 1"
);
}
PatientSignEntity
pse
=
patientSignMapper
.
selectOne
(
psWrapper
);
if
(
null
==
pse
)
{
throw
new
BusinessException
(
"未查询到签约信息,不能获取排班医生!"
);
}
sendImMsgDTO
.
setOldAdmId
(
pse
.
getAdmId
());
//放入MQ任务,处理订单到时结束
OrderTaskVo
orderTaskVo
=
new
OrderTaskVo
();
orderTaskVo
.
setType
(
1
);
...
...
编写
预览
Markdown
格式
0%
重试
或
添加新文件
添加附件
取消
您添加了
0
人
到此讨论。请谨慎行事。
请先完成此评论的编辑!
取消
请
注册
或者
登录
后发表评论