Skip to content
项目
群组
代码片段
帮助
正在加载...
登录
切换导航
B
byh-family-doctor
项目
项目
详情
活动
周期分析
仓库
仓库
文件
提交
分支
标签
贡献者
分枝图
比较
统计图
议题
0
议题
0
列表
看板
标记
里程碑
合并请求
0
合并请求
0
CI / CD
CI / CD
流水线
作业
日程
统计图
包
包
Wiki
Wiki
代码片段
代码片段
成员
成员
折叠边栏
关闭边栏
活动
分枝图
统计图
创建新议题
作业
提交
议题看板
打开侧边栏
杨凯
byh-family-doctor
Commits
06c6628a
提交
06c6628a
authored
4月 09, 2024
作者:
杨凯
浏览文件
操作
浏览文件
下载
电子邮件补丁
差异文件
feat:家庭医生初始化
上级
c6b1b29a
隐藏空白字符变更
内嵌
并排
正在显示
6 个修改的文件
包含
37 行增加
和
10 行删除
+37
-10
QueryDoctorsDTO.java
...m/ebaiyihui/family/doctor/common/dto/QueryDoctorsDTO.java
+9
-0
PatientSignService.java
...ihui/family/doctor/server/service/PatientSignService.java
+1
-1
DoctorServiceImpl.java
.../family/doctor/server/service/impl/DoctorServiceImpl.java
+21
-4
PatientServiceImpl.java
...family/doctor/server/service/impl/PatientServiceImpl.java
+3
-2
PatientSignServiceImpl.java
...ly/doctor/server/service/impl/PatientSignServiceImpl.java
+2
-1
SignedTask.java
...a/com/ebaiyihui/family/doctor/server/task/SignedTask.java
+1
-2
没有找到文件。
family-doctor-common/src/main/java/com/ebaiyihui/family/doctor/common/dto/QueryDoctorsDTO.java
浏览文件 @
06c6628a
package
com
.
ebaiyihui
.
family
.
doctor
.
common
.
dto
;
import
io.swagger.annotations.ApiModelProperty
;
import
lombok.Data
;
import
java.util.List
;
...
...
@@ -17,4 +18,12 @@ public class QueryDoctorsDTO extends QueryFamousDTO {
* 新冠门诊多科室
*/
private
List
<
Long
>
depts
;
@ApiModelProperty
(
"权益包id"
)
private
String
packageOrderId
;
@ApiModelProperty
(
"签约关联id"
)
private
Long
signId
;
}
family-doctor-server/src/main/java/com/ebaiyihui/family/doctor/server/service/PatientSignService.java
浏览文件 @
06c6628a
...
...
@@ -48,7 +48,7 @@ public interface PatientSignService {
List
<
PatientSignEntity
>
selectList
(
PatientSignEntity
patientSignEntity
);
List
<
PatientSignEntity
>
getListByPhone
(
String
phone
);
List
<
PatientSignEntity
>
getListByPhone
(
String
phone
,
String
activateOrderId
);
int
updateById
(
PatientSignEntity
patientSignEntity
);
...
...
family-doctor-server/src/main/java/com/ebaiyihui/family/doctor/server/service/impl/DoctorServiceImpl.java
浏览文件 @
06c6628a
...
...
@@ -13,6 +13,7 @@ import com.ebaiyihui.family.doctor.common.dto.*;
import
com.ebaiyihui.family.doctor.common.vo.*
;
import
com.ebaiyihui.family.doctor.server.common.constants.ImConstants
;
import
com.ebaiyihui.family.doctor.server.common.enums.SignStatus
;
import
com.ebaiyihui.family.doctor.server.common.enums.StatusEnum
;
import
com.ebaiyihui.family.doctor.server.entity.PatientEntity
;
import
com.ebaiyihui.family.doctor.server.entity.PatientSignEntity
;
import
com.ebaiyihui.family.doctor.server.entity.ServiceConfigEntity
;
...
...
@@ -84,6 +85,7 @@ public class DoctorServiceImpl implements DoctorService {
patientSignEntity
.
setPatientId
(
reqVo
.
getPatientId
());
patientSignEntity
.
setOrganId
(
reqVo
.
getOrganId
());
patientSignEntity
.
setSignStatus
(
SignStatus
.
SIGNED
.
getValue
());
patientSignEntity
.
setPackageOrderId
(
reqVo
.
getPackageOrderId
());
QueryWrapper
<
PatientEntity
>
pWrapper
=
new
QueryWrapper
<>();
PatientEntity
patient
=
new
PatientEntity
();
...
...
@@ -156,6 +158,23 @@ public class DoctorServiceImpl implements DoctorService {
// if (LastSignFlag) {
// isLastSign(reqVo, doctorListVos, wOrganId, entity, doctorZxwzService);
// }
// 过滤签约过的医生信息
if
(
Objects
.
isNull
(
reqVo
.
getSignId
())
&&
Objects
.
nonNull
(
reqVo
.
getPackageOrderId
()))
{
QueryWrapper
<
PatientSignEntity
>
psWrapper
=
new
QueryWrapper
<>();
PatientSignEntity
patientSign
=
new
PatientSignEntity
();
patientSign
.
setPackageOrderId
(
reqVo
.
getPackageOrderId
());
patientSign
.
setStatus
(
StatusEnum
.
IN_CONSULTATION
.
getValue
());
patientSign
.
setSignStatus
(
SignStatus
.
SIGNED
.
getValue
());
psWrapper
.
setEntity
(
patientSign
);
List
<
PatientSignEntity
>
patientSignEntities
=
patientSignMapper
.
selectList
(
psWrapper
);
if
(!
patientSignEntities
.
isEmpty
())
{
List
<
Long
>
patientDoctorIds
=
patientSignEntities
.
stream
().
map
(
PatientSignEntity:
:
getDoctorId
).
collect
(
Collectors
.
toList
());
doctorListVos
=
doctorListVos
.
stream
().
filter
(
doctorListVo
->
!
patientDoctorIds
.
contains
(
Long
.
valueOf
(
doctorListVo
.
getDoctorId
()))).
collect
(
Collectors
.
toList
());
}
}
pageResult
.
setPageNum
(
reqVo
.
getPageNum
());
pageResult
.
setPageSize
(
doctorListVos
.
size
());
// pageResult.setPageSize(reqVo.getPageSize());
...
...
@@ -177,8 +196,7 @@ public class DoctorServiceImpl implements DoctorService {
businessDoctorPageReqVo
.
setPageSize
(
9999
);
businessDoctorPageReqVo
.
setServiceCode
(
ImConstants
.
IM_QUERY_ACCOUNT_CODE
);
BaseResponse
<
PageResult
<
DoctorBasicRespVO
>>
result
=
doctorWorkingServiceClient
.
getBusinessDoctorBaseInfoPage
(
businessDoctorPageReqVo
);
BaseResponse
<
PageResult
<
DoctorBasicRespVO
>>
result
=
doctorWorkingServiceClient
.
getBusinessDoctorBaseInfoPage
(
businessDoctorPageReqVo
);
if
(!
result
.
isSuccess
())
{
return
BaseResponse
.
error
(
"医生查询失败"
);
}
...
...
@@ -407,8 +425,7 @@ public class DoctorServiceImpl implements DoctorService {
BeanUtils
.
copyProperties
(
reqVo
,
businessDoctorPageReqVo
);
businessDoctorPageReqVo
.
setServiceCode
(
reqVo
.
getServiceCodes
());
log
.
info
(
"医生数据入参"
+
JSON
.
toJSONString
(
businessDoctorPageReqVo
));
BaseResponse
<
PageResult
<
DoctorBasicRespVO
>>
businessDoctorPage
=
doctorWorkingServiceClient
.
getBusinessDoctorBaseInfoPage
(
businessDoctorPageReqVo
);
BaseResponse
<
PageResult
<
DoctorBasicRespVO
>>
businessDoctorPage
=
doctorWorkingServiceClient
.
getBusinessDoctorBaseInfoPage
(
businessDoctorPageReqVo
);
log
.
info
(
"医生数据出参"
+
JSON
.
toJSONString
(
businessDoctorPage
.
getData
()));
if
(
null
==
businessDoctorPage
.
getData
())
{
return
new
ArrayList
<>();
...
...
family-doctor-server/src/main/java/com/ebaiyihui/family/doctor/server/service/impl/PatientServiceImpl.java
浏览文件 @
06c6628a
...
...
@@ -147,7 +147,7 @@ public class PatientServiceImpl implements PatientService {
}
// 查询排班医生信息
ScheduleRecordEntity
scheduleRecordEntity
=
getScheduleDoctor
(
reqVo
.
getPatientId
(),
oldPatientSignEntity
.
getDoctorId
());
ScheduleRecordEntity
scheduleRecordEntity
=
getScheduleDoctor
(
reqVo
.
getPatientId
(),
reqVo
.
getPackageOrderId
(),
oldPatientSignEntity
.
getDoctorId
());
doctorId
=
Long
.
valueOf
(
scheduleRecordEntity
.
getDoctorId
());
doctorName
=
scheduleRecordEntity
.
getDoctorName
();
deptId
=
Long
.
valueOf
(
scheduleRecordEntity
.
getDeptId
());
...
...
@@ -310,12 +310,13 @@ public class PatientServiceImpl implements PatientService {
* @param patientId
* @return
*/
public
ScheduleRecordEntity
getScheduleDoctor
(
String
patientId
,
Long
doctorId
)
{
public
ScheduleRecordEntity
getScheduleDoctor
(
String
patientId
,
String
packageOrderId
,
Long
doctorId
)
{
String
date
=
DateUtils
.
dateToSimpleString
(
new
Date
());
String
hourAndSecond
=
DateUtils
.
getHourAndSecond
();
QueryWrapper
<
PatientSignEntity
>
psWrapper
=
new
QueryWrapper
<>();
PatientSignEntity
patientSign
=
new
PatientSignEntity
();
patientSign
.
setPatientId
(
patientId
);
patientSign
.
setPackageOrderId
(
packageOrderId
);
patientSign
.
setSignStatus
(
SignStatus
.
NORMAL
.
getValue
());
patientSign
.
setStatus
(
StatusEnum
.
IN_CONSULTATION
.
getValue
());
psWrapper
.
setEntity
(
patientSign
);
...
...
family-doctor-server/src/main/java/com/ebaiyihui/family/doctor/server/service/impl/PatientSignServiceImpl.java
浏览文件 @
06c6628a
...
...
@@ -318,10 +318,11 @@ public class PatientSignServiceImpl implements PatientSignService {
}
@Override
public
List
<
PatientSignEntity
>
getListByPhone
(
String
phone
)
{
public
List
<
PatientSignEntity
>
getListByPhone
(
String
phone
,
String
activateOrderId
)
{
QueryWrapper
<
PatientSignEntity
>
psWrapper
=
new
QueryWrapper
<>();
PatientSignEntity
patientSign
=
new
PatientSignEntity
();
patientSign
.
setPatientPhone
(
phone
);
patientSign
.
setPackageOrderId
(
activateOrderId
);
psWrapper
.
setEntity
(
patientSign
);
// psWrapper.orderByDesc("create_time");
// psWrapper.last("limit 1");
...
...
family-doctor-server/src/main/java/com/ebaiyihui/family/doctor/server/task/SignedTask.java
浏览文件 @
06c6628a
...
...
@@ -202,11 +202,10 @@ public class SignedTask {
for
(
MobileBenefitPackageEntity
mbp
:
mobileBenefitPackageEntities
)
{
Date
curTime
=
new
Date
();
Date
endTime
=
DateUtils
.
parseDate
(
mbp
.
getBenefitsEndTime
(),
DateUtils
.
FULL_FORMAT
);
List
<
PatientSignEntity
>
patientSignEntities
=
patientSignSevice
.
getListByPhone
(
mbp
.
getPhone
());
List
<
PatientSignEntity
>
patientSignEntities
=
patientSignSevice
.
getListByPhone
(
mbp
.
getPhone
()
,
mbp
.
getActivateOrderId
()
);
mbp
.
setVersion
(
1
);
for
(
PatientSignEntity
patientSignEntity
:
patientSignEntities
)
{
if
(
endTime
.
after
(
curTime
))
{
patientSignEntity
.
setPackageOrderId
(
mbp
.
getActivateOrderId
());
patientSignEntity
.
setSignEndTime
(
endTime
);
}
else
{
if
(
SignStatus
.
SIGNED
.
getValue
().
equals
(
patientSignEntity
.
getSignStatus
())
...
...
编写
预览
Markdown
格式
0%
重试
或
添加新文件
添加附件
取消
您添加了
0
人
到此讨论。请谨慎行事。
请先完成此评论的编辑!
取消
请
注册
或者
登录
后发表评论