Skip to content
Toggle navigation
Projects
Groups
Snippets
Help
dj
/
rpc-dj-supervisor
This project
Loading...
Sign in
Toggle navigation
Go to a project
Project
Repository
Issues
0
Merge Requests
0
Pipelines
Wiki
Settings
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Commit 99d07087
authored
Mar 13, 2026
by
zhouhaibao
Browse Files
Options
Browse Files
Tag
Download
Plain Diff
Merge branch 'main' of
http://192.168.3.233:8090/dj/rpc-dj-supervisor
2 parents
a3ec481e
95bbfb0f
Show whitespace changes
Inline
Side-by-side
Showing
45 changed files
with
1892 additions
and
9 deletions
rpc-dj-supervisor-api/src/main/java/cn/com/glsx/dj/supervisor/dto/AudioReceptionDTO.java
rpc-dj-supervisor-api/src/main/java/cn/com/glsx/dj/supervisor/dto/AudioSummaryDTO.java
rpc-dj-supervisor-api/src/main/java/cn/com/glsx/dj/supervisor/dto/CoursePageInfo.java
rpc-dj-supervisor-api/src/main/java/cn/com/glsx/dj/supervisor/dto/CoursePushDTO.java
rpc-dj-supervisor-api/src/main/java/cn/com/glsx/dj/supervisor/dto/CourseSearchDTO.java
rpc-dj-supervisor-api/src/main/java/cn/com/glsx/dj/supervisor/dto/EmployeeTrainingInfoDTO.java
rpc-dj-supervisor-api/src/main/java/cn/com/glsx/dj/supervisor/dto/EmployeeTrainingInfoRequestDTO.java
rpc-dj-supervisor-api/src/main/java/cn/com/glsx/dj/supervisor/dto/MapperQueryEmployeeTrainingInfoDTO.java
rpc-dj-supervisor-api/src/main/java/cn/com/glsx/dj/supervisor/dto/MyselfCourseRecommendDTO.java
rpc-dj-supervisor-api/src/main/java/cn/com/glsx/dj/supervisor/dto/PersonCourseRecommendDTO.java
rpc-dj-supervisor-api/src/main/java/cn/com/glsx/dj/supervisor/dto/SupervisorTaskDTO.java
rpc-dj-supervisor-api/src/main/java/cn/com/glsx/dj/supervisor/enums/BeisenCourseStatusEnum.java
rpc-dj-supervisor-api/src/main/java/cn/com/glsx/dj/supervisor/model/PersonCourseRecommendation.java
rpc-dj-supervisor-api/src/main/java/cn/com/glsx/dj/supervisor/model/SupervisorAudioReviewInfo.java
rpc-dj-supervisor-api/src/main/java/cn/com/glsx/dj/supervisor/remote/PersonCourseRecommendationRemote.java
rpc-dj-supervisor-api/src/main/java/cn/com/glsx/dj/supervisor/remote/SupervisorAiAnalysisRecordRemote.java
rpc-dj-supervisor-api/src/main/java/cn/com/glsx/dj/supervisor/remote/SupervisorEmployeeTrainingInfoRemote.java
rpc-dj-supervisor-api/src/main/java/cn/com/glsx/dj/supervisor/remote/SupervisorLearningCenterRemote.java
rpc-dj-supervisor-api/src/main/java/cn/com/glsx/dj/supervisor/remote/SupervisorTaskInfoRemote.java
rpc-dj-supervisor/pom.xml
rpc-dj-supervisor/src/main/java/cn/com/glsx/dj/supervisor/mapper/PersonCourseRecommendationMapper.java
rpc-dj-supervisor/src/main/java/cn/com/glsx/dj/supervisor/mapper/SupervisorAiAnalysisRecordMapper.java
rpc-dj-supervisor/src/main/java/cn/com/glsx/dj/supervisor/mapper/SupervisorAudioReviewInfoMapper.java
rpc-dj-supervisor/src/main/java/cn/com/glsx/dj/supervisor/mapper/SupervisorTaskInfoMapper.java
rpc-dj-supervisor/src/main/java/cn/com/glsx/dj/supervisor/remote/PersonCourseRecommendationRemoteImpl.java
rpc-dj-supervisor/src/main/java/cn/com/glsx/dj/supervisor/remote/SupervisorAiAnalysisRecordRemoteImpl.java
rpc-dj-supervisor/src/main/java/cn/com/glsx/dj/supervisor/remote/SupervisorEmployeeTrainingInfoRemoteImpl.java
rpc-dj-supervisor/src/main/java/cn/com/glsx/dj/supervisor/remote/SupervisorLearningCenterRemoteImpl.java
rpc-dj-supervisor/src/main/java/cn/com/glsx/dj/supervisor/remote/SupervisorTaskInfoRemoteImpl.java
rpc-dj-supervisor/src/main/java/cn/com/glsx/dj/supervisor/service/PersonCourseRecommendationService.java
rpc-dj-supervisor/src/main/java/cn/com/glsx/dj/supervisor/service/SupervisorAiAnalysisRecordService.java
rpc-dj-supervisor/src/main/java/cn/com/glsx/dj/supervisor/service/SupervisorAudioReviewInfoService.java
rpc-dj-supervisor/src/main/java/cn/com/glsx/dj/supervisor/service/SupervisorEmployeeTrainingInfoService.java
rpc-dj-supervisor/src/main/java/cn/com/glsx/dj/supervisor/service/SupervisorLearningCenterService.java
rpc-dj-supervisor/src/main/java/cn/com/glsx/dj/supervisor/service/SupervisorTaskCourseService.java
rpc-dj-supervisor/src/main/java/cn/com/glsx/dj/supervisor/service/SupervisorTaskInfoService.java
rpc-dj-supervisor/src/main/resources/META-INF/orm/PersonCourseRecommendationMapper.xml
rpc-dj-supervisor/src/main/resources/META-INF/orm/SupervisorAiAnalysisRecordMapper.xml
rpc-dj-supervisor/src/main/resources/META-INF/orm/SupervisorAudioReviewInfoMapper.xml
rpc-dj-supervisor/src/main/resources/META-INF/orm/SupervisorTaskInfoMapper.xml
rpc-dj-supervisor/src/test/java/cn/com/glsx/dj/supervisor/service/PersonCourseRecommendationServiceTest.java
rpc-dj-supervisor/src/test/java/cn/com/glsx/dj/supervisor/service/SupervisorAiAnalysisRecordServiceTest.java
rpc-dj-supervisor/src/test/java/cn/com/glsx/dj/supervisor/service/SupervisorEmployeeTrainingInfoServiceTest.java
rpc-dj-supervisor/src/test/java/cn/com/glsx/dj/supervisor/service/SupervisorLearningCenterServiceTest.java
rpc-dj-supervisor/src/test/java/cn/com/glsx/dj/supervisor/service/SupervisorTaskInfoServiceTest.java
rpc-dj-supervisor-api/src/main/java/cn/com/glsx/dj/supervisor/dto/AudioReceptionDTO.java
0 → 100644
View file @
99d0708
package
cn
.
com
.
glsx
.
dj
.
supervisor
.
dto
;
import
io.swagger.annotations.ApiModelProperty
;
import
lombok.Data
;
import
lombok.ToString
;
import
java.io.Serializable
;
import
java.util.Date
;
@Data
@ToString
public
class
AudioReceptionDTO
implements
Serializable
{
@ApiModelProperty
(
notes
=
"复盘记录id"
)
private
Integer
id
;
@ApiModelProperty
(
notes
=
"接待日期"
)
private
Date
staticDate
;
@ApiModelProperty
(
notes
=
"员工姓名"
)
private
String
employeeName
;
@ApiModelProperty
(
notes
=
"客户姓名"
)
private
String
customerName
;
@ApiModelProperty
(
notes
=
"客户手机号"
)
private
String
phoneNumber
;
@ApiModelProperty
(
notes
=
"门店商户号"
)
private
String
merchantNo
;
@ApiModelProperty
(
notes
=
"门店名称"
)
private
String
merchantName
;
@ApiModelProperty
(
notes
=
"客户类型"
)
private
String
customerType
;
@ApiModelProperty
(
notes
=
"质检评分"
)
private
Integer
qualityCheckScore
;
@ApiModelProperty
(
notes
=
"攻防评分"
)
private
String
avgDefence
;
@ApiModelProperty
(
notes
=
"录音起始时间"
)
private
Date
startTime
;
// 录音起始时间
@ApiModelProperty
(
notes
=
"录音结束时间"
)
private
Date
endTime
;
// 录音结束时间
@ApiModelProperty
(
notes
=
"总耗时时长"
)
private
Long
totalDuration
;
@ApiModelProperty
(
notes
=
"车型"
)
private
String
carModel
;
@ApiModelProperty
(
notes
=
"品牌"
)
private
String
carBrand
;
@ApiModelProperty
(
notes
=
"复盘状态,0-未复盘,1-已复盘"
)
private
Integer
reviewStatus
;
@ApiModelProperty
(
notes
=
"录音批次id"
)
private
Integer
batchId
;
@ApiModelProperty
(
notes
=
"录音地址"
)
private
String
fileUrl
;
}
rpc-dj-supervisor-api/src/main/java/cn/com/glsx/dj/supervisor/dto/AudioSummaryDTO.java
0 → 100644
View file @
99d0708
package
cn
.
com
.
glsx
.
dj
.
supervisor
.
dto
;
import
io.swagger.annotations.ApiModelProperty
;
import
lombok.Data
;
import
lombok.ToString
;
import
java.io.Serializable
;
import
java.util.Date
;
@Data
@ToString
public
class
AudioSummaryDTO
implements
Serializable
{
/**
* 已复盘数量
*/
@ApiModelProperty
(
notes
=
"已复盘数量"
)
private
Integer
reviewedCount
;
/**
* 未复盘数量
*/
@ApiModelProperty
(
notes
=
"未复盘数量"
)
private
Integer
unreviewedCount
;
/**
* 总数
*/
@ApiModelProperty
(
notes
=
"总数"
)
private
Integer
totalCount
;
}
rpc-dj-supervisor-api/src/main/java/cn/com/glsx/dj/supervisor/dto/CoursePageInfo.java
0 → 100644
View file @
99d0708
package
cn
.
com
.
glsx
.
dj
.
supervisor
.
dto
;
import
io.swagger.annotations.ApiModelProperty
;
import
lombok.Data
;
import
java.io.Serializable
;
import
java.math.BigDecimal
;
import
java.util.Date
;
@Data
public
class
CoursePageInfo
implements
Serializable
{
@ApiModelProperty
(
notes
=
"课程id"
)
private
String
courseId
;
@ApiModelProperty
(
notes
=
"课程标题"
)
private
String
title
;
@ApiModelProperty
(
notes
=
"课程类型:10-视频,80-音频,20-混合,30-文档,40-H5,70-URL,120-图文"
)
private
String
courseFileType
;
@ApiModelProperty
(
notes
=
"课程总时长(单位:分钟)"
)
private
BigDecimal
totalDuration
;
@ApiModelProperty
(
notes
=
"课程状态:10-转换中, 20-转换失败, 30-未发布, 40-已发布, 50-已下架"
)
private
String
courseStatus
;
@ApiModelProperty
(
notes
=
"分类名称"
)
private
String
categoryName
;
@ApiModelProperty
(
notes
=
"分类id"
)
private
Integer
categoryId
;
@ApiModelProperty
(
notes
=
"父级分类id"
)
private
Integer
parentId
;
@ApiModelProperty
(
notes
=
"部门名称"
)
private
String
organizationName
;
@ApiModelProperty
(
notes
=
"学习人数"
)
private
Integer
learnTotal
;
@ApiModelProperty
(
notes
=
"课程总评分"
)
private
BigDecimal
totalStar
;
@ApiModelProperty
(
notes
=
"创建人"
)
private
String
createdBy
;
@ApiModelProperty
(
notes
=
"北森创建人用户id"
)
private
Integer
beisenCreatedBy
;
@ApiModelProperty
(
notes
=
"创建时间"
)
private
Date
createdTime
;
@ApiModelProperty
(
notes
=
"学习进度"
)
private
BigDecimal
progress
;
@ApiModelProperty
(
notes
=
"学习状态:10 - 未学习,20 - 未完成,30 - 待考核,40 - 未通过,50 - 已完成,60 - 待签署"
)
private
String
learnStatus
;
}
rpc-dj-supervisor-api/src/main/java/cn/com/glsx/dj/supervisor/dto/CoursePushDTO.java
0 → 100644
View file @
99d0708
package
cn
.
com
.
glsx
.
dj
.
supervisor
.
dto
;
import
lombok.Data
;
import
java.io.Serializable
;
/**
* 课程推送请求 DTO
*/
@Data
public
class
CoursePushDTO
implements
Serializable
{
private
static
final
long
serialVersionUID
=
1L
;
/**
* 驻店手机号
*/
private
String
storeManagerPhone
;
/**
* 驻店姓名
*/
private
String
storeManagerName
;
/**
* 北森课程标识
*/
private
String
bcCourseId
;
/**
* 北森课程名称
*/
private
String
bcCourseName
;
}
rpc-dj-supervisor-api/src/main/java/cn/com/glsx/dj/supervisor/dto/CourseSearchDTO.java
0 → 100644
View file @
99d0708
package
cn
.
com
.
glsx
.
dj
.
supervisor
.
dto
;
import
io.swagger.annotations.ApiModelProperty
;
import
lombok.Data
;
import
org.springframework.format.annotation.DateTimeFormat
;
import
java.io.Serializable
;
import
java.math.BigDecimal
;
import
java.util.Date
;
import
java.util.List
;
@Data
public
class
CourseSearchDTO
implements
Serializable
{
@ApiModelProperty
(
notes
=
"课程名称"
)
private
String
title
;
@ApiModelProperty
(
notes
=
"课程分类id"
)
private
Integer
courseCategoryId
;
@ApiModelProperty
(
notes
=
"排除未分类课程:1-排除"
)
private
Integer
excludeNullCategoryId
;
@ApiModelProperty
(
notes
=
"课程id列表"
)
private
List
<
String
>
courseIds
;
@ApiModelProperty
(
notes
=
"课程类型:10-视频,80-音频,20-混合,30-文档,40-H5,70-URL,120-图文"
)
private
String
courseFileType
;
@ApiModelProperty
(
notes
=
"课程状态:10-转换中, 20-转换失败, 30-未发布, 40-已发布, 50-已下架"
)
private
String
courseStatus
;
/**
* 课程状态列表
*/
private
List
<
String
>
statusList
;
private
List
<
Integer
>
userIdList
;
@ApiModelProperty
(
notes
=
"部门id"
)
private
Integer
organizationV2Id
;
private
List
<
Integer
>
organizationIdList
;
@ApiModelProperty
(
notes
=
"创建人"
)
private
String
createdBy
;
@DateTimeFormat
(
pattern
=
"yyyy-MM-dd HH:mm:ss"
)
@ApiModelProperty
(
notes
=
"创建时间开始, 格式: yyyy-MM-dd HH:mm:ss"
)
private
Date
createTimeStart
;
@DateTimeFormat
(
pattern
=
"yyyy-MM-dd HH:mm:ss"
)
@ApiModelProperty
(
notes
=
"创建时间结束, 格式: yyyy-MM-dd HH:mm:ss"
)
private
Date
createTimeEnd
;
@ApiModelProperty
(
notes
=
"排序类型:0-学习人数,1-评分,2-创建时间"
,
required
=
true
)
private
Integer
sortType
;
@ApiModelProperty
(
notes
=
"排序顺序:asc-升序,desc-降序"
,
required
=
true
)
private
String
sortOrder
;
@ApiModelProperty
(
notes
=
"排序类型:0-学习人数升序,1-学习人数降序,2-评分升序,3-评分降序,4-创建时间升序,5-创建时间降序"
,
required
=
true
)
private
Integer
orderByType
;
@ApiModelProperty
(
notes
=
"员工手机号"
)
private
String
staffPhone
;
@ApiModelProperty
(
notes
=
"课程总评分"
)
private
BigDecimal
totalStar
;
@ApiModelProperty
(
notes
=
"周期类型:0-总榜,1-日榜,2-周榜,3-月榜"
)
private
Integer
periodType
;
@ApiModelProperty
(
notes
=
"修习标识:1-必修,2-选修"
)
private
Integer
planCourseType
;
private
Integer
userId
;
private
Integer
rankLimit
;
@ApiModelProperty
(
notes
=
"业务类型(1.延保 2.轻改 3.权益)"
)
private
Integer
bizs
;
}
rpc-dj-supervisor-api/src/main/java/cn/com/glsx/dj/supervisor/dto/EmployeeTrainingInfoDTO.java
0 → 100644
View file @
99d0708
package
cn
.
com
.
glsx
.
dj
.
supervisor
.
dto
;
import
io.swagger.annotations.ApiModelProperty
;
import
lombok.Data
;
import
java.io.Serializable
;
import
java.math.BigDecimal
;
/**
* 员工培训信息响应
*
* @author xiehx
* @date 2026 年 3 月 12 日
*/
@Data
public
class
EmployeeTrainingInfoDTO
implements
Serializable
{
@ApiModelProperty
(
notes
=
"员工姓名"
)
private
String
employeeName
;
@ApiModelProperty
(
notes
=
"手机号"
)
private
String
phone
;
@ApiModelProperty
(
notes
=
"学习时长(小时)"
)
private
BigDecimal
studyHours
;
@ApiModelProperty
(
notes
=
"完成课程数"
)
private
Integer
completedCourses
;
@ApiModelProperty
(
notes
=
"带教次数"
)
private
Integer
coachingTimes
;
}
rpc-dj-supervisor-api/src/main/java/cn/com/glsx/dj/supervisor/dto/EmployeeTrainingInfoRequestDTO.java
0 → 100644
View file @
99d0708
package
cn
.
com
.
glsx
.
dj
.
supervisor
.
dto
;
import
lombok.Data
;
import
java.io.Serializable
;
/**
* 员工培训信息查询 DTO
*
* @author xiehx
* @date 2026 年 3 月 12 日
*/
@Data
public
class
EmployeeTrainingInfoRequestDTO
implements
Serializable
{
/**
* 业务类型(1-延保、2-权益、3-轻改)
*/
private
Integer
businessType
;
/**
* 开始日期
*/
private
String
startDate
;
/**
* 结束日期
*/
private
String
endDate
;
/**
* 排序字段(1-学习时长、2-完成课程数、3-带教次数)
*/
private
Integer
sortField
;
/**
* 排序方式(0-升序、1-降序)
*/
private
Integer
sortOrder
;
/**
* 督导手机号
*/
private
String
supervisorPhone
;
}
rpc-dj-supervisor-api/src/main/java/cn/com/glsx/dj/supervisor/dto/MapperQueryEmployeeTrainingInfoDTO.java
0 → 100644
View file @
99d0708
package
cn
.
com
.
glsx
.
dj
.
supervisor
.
dto
;
import
io.swagger.annotations.ApiModelProperty
;
import
lombok.Data
;
import
java.io.Serializable
;
import
java.math.BigDecimal
;
/**
* 员工培训信息响应
*
* @author xiehx
* @date 2026 年 3 月 12 日
*/
@Data
public
class
MapperQueryEmployeeTrainingInfoDTO
implements
Serializable
{
@ApiModelProperty
(
notes
=
"员工姓名"
)
private
String
employeeName
;
@ApiModelProperty
(
notes
=
"手机号"
)
private
String
phone
;
@ApiModelProperty
(
notes
=
"员工北森id"
)
private
Integer
userId
;
@ApiModelProperty
(
notes
=
"学习时长(小时)"
)
private
BigDecimal
studyHours
;
@ApiModelProperty
(
notes
=
"完成课程数"
)
private
Integer
completedCourses
;
@ApiModelProperty
(
notes
=
"带教次数"
)
private
Integer
coachingTimes
;
}
rpc-dj-supervisor-api/src/main/java/cn/com/glsx/dj/supervisor/dto/MyselfCourseRecommendDTO.java
0 → 100644
View file @
99d0708
package
cn
.
com
.
glsx
.
dj
.
supervisor
.
dto
;
import
lombok.AllArgsConstructor
;
import
lombok.Data
;
import
lombok.NoArgsConstructor
;
import
lombok.experimental.SuperBuilder
;
import
javax.validation.constraints.NotBlank
;
import
java.io.Serializable
;
import
java.math.BigDecimal
;
/**
* 学习中心-我的课程-推荐课程
* @author xiehx
* @version 1.0
* @since 2026/03/11 15:32
*/
@Data
@SuperBuilder
@NoArgsConstructor
@AllArgsConstructor
public
class
MyselfCourseRecommendDTO
implements
Serializable
{
private
static
final
long
serialVersionUID
=
-
4811308989776259758L
;
/**
* 调用标识 0:内部调用
*/
private
String
invokeFlag
;
/**
* 北森人员标识
*/
private
Integer
personId
;
/**
* 手机号码
*/
@NotBlank
(
message
=
"手机号码不能为空"
)
private
String
phone
;
/**
* 北森课程标识
*/
private
String
courseId
;
/**
* 课程标题
*/
private
String
title
;
/**
* 总时长(分钟)
*/
private
BigDecimal
totalDuration
;
/**
* 总评分结果
*/
private
BigDecimal
totalStar
;
/**
* 学习总人数
*/
private
Integer
learnTotal
;
/**
* 课程文件类型 10:视频 80:音频 20:混合 30:文档 40:H5 70:URL 120:图文
*/
private
String
courseFileType
;
/**
* 学习进度(百分比)
*/
private
BigDecimal
process
;
}
rpc-dj-supervisor-api/src/main/java/cn/com/glsx/dj/supervisor/dto/PersonCourseRecommendDTO.java
0 → 100644
View file @
99d0708
package
cn
.
com
.
glsx
.
dj
.
supervisor
.
dto
;
import
lombok.Data
;
import
java.io.Serializable
;
/**
* 人员课程推荐查询 DTO
*/
@Data
public
class
PersonCourseRecommendDTO
implements
Serializable
{
private
static
final
long
serialVersionUID
=
1L
;
/**
* 人员手机号
*/
private
String
personPhone
;
/**
* 人员姓名
*/
private
String
personName
;
/**
* 北森课程标识
*/
private
String
bcCourseId
;
/**
* 北森课程名称
*/
private
String
bcCourseName
;
/**
* 推送来源(1-飞行督导)
*/
private
Integer
pushSource
;
}
rpc-dj-supervisor-api/src/main/java/cn/com/glsx/dj/supervisor/dto/SupervisorTaskDTO.java
View file @
99d0708
package
cn
.
com
.
glsx
.
dj
.
supervisor
.
dto
;
package
cn
.
com
.
glsx
.
dj
.
supervisor
.
dto
;
import
cn.com.glsx.dj.supervisor.model.SupervisorTaskCourse
;
import
cn.com.glsx.dj.supervisor.model.SupervisorTaskImage
;
import
cn.com.glsx.dj.supervisor.model.SupervisorTaskImage
;
import
cn.com.glsx.dj.supervisor.model.SupervisorWeekTaskStaff
;
import
cn.com.glsx.dj.supervisor.model.SupervisorWeekTaskStaff
;
import
cn.com.glsx.dj.supervisor.remote.SupervisorTaskInfoRemote
;
import
cn.com.glsx.dj.supervisor.remote.SupervisorTaskInfoRemote
;
...
@@ -50,6 +51,20 @@ public class SupervisorTaskDTO implements Serializable {
...
@@ -50,6 +51,20 @@ public class SupervisorTaskDTO implements Serializable {
*/
*/
@ApiModelProperty
(
notes
=
"驻店员工姓名"
)
@ApiModelProperty
(
notes
=
"驻店员工姓名"
)
private
String
storeManagerName
;
private
String
storeManagerName
;
/**
* 驻店员工手机号
*/
@ApiModelProperty
(
notes
=
"驻店员工手机号"
)
private
String
storeManagerPhone
;
@ApiModelProperty
(
notes
=
"任务描述"
)
private
String
taskDesc
;
@ApiModelProperty
(
notes
=
"督导手机号"
)
private
String
supervisorPhone
;
@ApiModelProperty
(
notes
=
"督导姓名"
)
private
String
supervisorName
;
/**
/**
* 督导记录(富文本内容)
* 督导记录(富文本内容)
...
@@ -71,6 +86,12 @@ public class SupervisorTaskDTO implements Serializable {
...
@@ -71,6 +86,12 @@ public class SupervisorTaskDTO implements Serializable {
private
Integer
audioReviewCompletedCount
;
private
Integer
audioReviewCompletedCount
;
/**
/**
* 创建时间
*/
@ApiModelProperty
(
notes
=
"创建时间"
)
private
Date
createTime
;
/**
* 更新时间
* 更新时间
*/
*/
@ApiModelProperty
(
notes
=
"更新时间"
)
@ApiModelProperty
(
notes
=
"更新时间"
)
...
@@ -91,4 +112,7 @@ public class SupervisorTaskDTO implements Serializable {
...
@@ -91,4 +112,7 @@ public class SupervisorTaskDTO implements Serializable {
@ApiModelProperty
(
notes
=
"照片图片列表"
)
@ApiModelProperty
(
notes
=
"照片图片列表"
)
private
List
<
SupervisorTaskImage
>
taskImageList
;
private
List
<
SupervisorTaskImage
>
taskImageList
;
@ApiModelProperty
(
notes
=
"课程列表"
)
private
List
<
SupervisorTaskCourse
>
taskCourseList
;
}
}
rpc-dj-supervisor-api/src/main/java/cn/com/glsx/dj/supervisor/enums/BeisenCourseStatusEnum.java
0 → 100644
View file @
99d0708
package
cn
.
com
.
glsx
.
dj
.
supervisor
.
enums
;
import
org.springframework.util.StringUtils
;
/**
* 课程状态:10-转换中, 20-转换失败, 30-未发布, 40-已发布, 50-已下架
*/
public
enum
BeisenCourseStatusEnum
{
CONVERTING
(
"10"
,
"转换中"
),
CONVERT_FAILED
(
"20"
,
"转换失败"
),
UNRELEASED
(
"30"
,
"未发布"
),
RELEASED
(
"40"
,
"已发布"
),
SOLD_OUT
(
"50"
,
"已下架"
);
private
final
String
code
;
private
final
String
desc
;
BeisenCourseStatusEnum
(
String
code
,
String
desc
)
{
this
.
code
=
code
;
this
.
desc
=
desc
;
}
public
String
getCode
()
{
return
code
;
}
public
String
getDesc
()
{
return
desc
;
}
/**
* 根据状态码获取状态描述
* @param code 状态码
* @return 状态描述
*/
public
static
String
getDescByCode
(
String
code
)
{
if
(
StringUtils
.
isEmpty
(
code
))
{
return
null
;
}
for
(
BeisenCourseStatusEnum
e
:
values
())
{
if
(
e
.
getCode
().
equals
(
code
))
{
return
e
.
getDesc
();
}
}
return
null
;
}
}
rpc-dj-supervisor-api/src/main/java/cn/com/glsx/dj/supervisor/model/PersonCourseRecommendation.java
View file @
99d0708
...
@@ -31,6 +31,12 @@ public class PersonCourseRecommendation implements Serializable {
...
@@ -31,6 +31,12 @@ public class PersonCourseRecommendation implements Serializable {
private
String
personName
;
private
String
personName
;
/**
/**
* 北森人员id
*/
@Column
(
name
=
"beisen_userid"
)
private
Integer
beisenUserId
;
/**
* 北森课程标识
* 北森课程标识
*/
*/
@Column
(
name
=
"bc_course_id"
)
@Column
(
name
=
"bc_course_id"
)
...
...
rpc-dj-supervisor-api/src/main/java/cn/com/glsx/dj/supervisor/model/SupervisorAudioReviewInfo.java
View file @
99d0708
package
cn
.
com
.
glsx
.
dj
.
supervisor
.
model
;
package
cn
.
com
.
glsx
.
dj
.
supervisor
.
model
;
import
cn.com.glsx.dj.supervisor.enums.ReviewStatusEnum
;
import
cn.com.glsx.dj.supervisor.enums.ReviewStatusEnum
;
import
cn.com.glsx.dj.supervisor.remote.SupervisorTaskInfoRemote
;
import
lombok.Data
;
import
lombok.Data
;
import
lombok.ToString
;
import
lombok.ToString
;
import
java.io.Serializable
;
import
java.io.Serializable
;
import
java.util.Date
;
import
java.util.Date
;
import
javax.persistence.*
;
import
javax.persistence.*
;
import
javax.validation.constraints.NotNull
;
@ToString
@ToString
@Data
@Data
...
@@ -15,12 +17,13 @@ public class SupervisorAudioReviewInfo implements Serializable {
...
@@ -15,12 +17,13 @@ public class SupervisorAudioReviewInfo implements Serializable {
/**
/**
* 主键ID(自增)
* 主键ID(自增)
*/
*/
@NotNull
(
message
=
"主键ID不能为空"
,
groups
=
{
SupervisorTaskInfoRemote
.
SubmitAudioReview
.
class
})
@Id
@Id
@GeneratedValue
(
strategy
=
GenerationType
.
IDENTITY
)
@GeneratedValue
(
strategy
=
GenerationType
.
IDENTITY
)
private
Long
id
;
private
Long
id
;
/**
/**
* 关联接待记录id(
reception_customer_info
.id)
* 关联接待记录id(
inspection_conversation_batch
.id)
*/
*/
@Column
(
name
=
"reception_id"
)
@Column
(
name
=
"reception_id"
)
private
Long
receptionId
;
private
Long
receptionId
;
...
...
rpc-dj-supervisor-api/src/main/java/cn/com/glsx/dj/supervisor/remote/PersonCourseRecommendationRemote.java
0 → 100644
View file @
99d0708
package
cn
.
com
.
glsx
.
dj
.
supervisor
.
remote
;
import
cn.com.glsx.dj.supervisor.dto.MyselfCourseRecommendDTO
;
import
cn.com.glsx.framework.core.annotation.ApiMethod
;
import
cn.com.glsx.framework.core.annotation.ApiParam
;
import
cn.com.glsx.framework.core.annotation.ApiResponse
;
import
cn.com.glsx.framework.core.annotation.ApiService
;
import
cn.com.glsx.framework.core.beans.rpc.RpcPagination
;
import
cn.com.glsx.framework.core.beans.rpc.RpcResponse
;
@ApiService
(
value
=
"督导学习中心"
,
owner
=
"xiehx"
)
public
interface
PersonCourseRecommendationRemote
{
@ApiMethod
(
"查询人员课程推荐分页接口"
)
@ApiParam
(
name
=
"pagination"
,
notes
=
"分页查询条件"
,
dataType
=
ApiParam
.
DataTypeEnum
.
OBJECT
,
required
=
true
)
@ApiResponse
(
"分页结果"
)
RpcResponse
<
RpcPagination
<
MyselfCourseRecommendDTO
>>
getPersonCourseRecommendPage
(
RpcPagination
<
MyselfCourseRecommendDTO
>
pagination
);
}
rpc-dj-supervisor-api/src/main/java/cn/com/glsx/dj/supervisor/remote/SupervisorAiAnalysisRecordRemote.java
0 → 100644
View file @
99d0708
package
cn
.
com
.
glsx
.
dj
.
supervisor
.
remote
;
import
cn.com.glsx.dj.supervisor.model.SupervisorAiAnalysisRecord
;
import
cn.com.glsx.framework.core.annotation.*
;
import
cn.com.glsx.framework.core.beans.rpc.RpcResponse
;
@ApiService
(
value
=
"督导 - 团队 AI 分析记录"
,
owner
=
"alvin"
)
public
interface
SupervisorAiAnalysisRecordRemote
{
@ApiMethod
(
"根据条件查询 AI 分析记录"
)
@ApiParams
({
@ApiParam
(
name
=
"request"
,
notes
=
"查询条件"
,
dataType
=
ApiParam
.
DataTypeEnum
.
OBJECT
,
required
=
true
)})
@ApiResponse
(
"提交结果"
)
RpcResponse
<
SupervisorAiAnalysisRecord
>
getAiAnalysisRecord
(
SupervisorAiAnalysisRecord
request
);
}
rpc-dj-supervisor-api/src/main/java/cn/com/glsx/dj/supervisor/remote/SupervisorEmployeeTrainingInfoRemote.java
0 → 100644
View file @
99d0708
package
cn
.
com
.
glsx
.
dj
.
supervisor
.
remote
;
import
cn.com.glsx.dj.supervisor.dto.EmployeeTrainingInfoRequestDTO
;
import
cn.com.glsx.dj.supervisor.dto.EmployeeTrainingInfoDTO
;
import
cn.com.glsx.framework.core.annotation.ApiMethod
;
import
cn.com.glsx.framework.core.annotation.ApiParam
;
import
cn.com.glsx.framework.core.annotation.ApiResponse
;
import
cn.com.glsx.framework.core.annotation.ApiService
;
import
cn.com.glsx.framework.core.beans.rpc.RpcResponse
;
import
java.util.List
;
/**
* 督导 - 员工培训信息 RPC 接口
*
* @author xiehx
* @date 2026 年 3 月 12 日
*/
@ApiService
(
value
=
"督导 - 员工培训信息"
,
owner
=
"xiehx"
)
public
interface
SupervisorEmployeeTrainingInfoRemote
{
@ApiMethod
(
"根据条件查询全部员工培训信息列表"
)
@ApiParam
(
name
=
"request"
,
notes
=
"查询条件"
,
dataType
=
ApiParam
.
DataTypeEnum
.
OBJECT
,
required
=
true
)
@ApiResponse
(
"列表结果"
)
RpcResponse
<
List
<
EmployeeTrainingInfoDTO
>>
getAllEmployeeTrainingInfo
(
EmployeeTrainingInfoRequestDTO
request
);
}
rpc-dj-supervisor-api/src/main/java/cn/com/glsx/dj/supervisor/remote/SupervisorLearningCenterRemote.java
0 → 100644
View file @
99d0708
package
cn
.
com
.
glsx
.
dj
.
supervisor
.
remote
;
import
cn.com.glsx.dj.supervisor.dto.CoursePageInfo
;
import
cn.com.glsx.dj.supervisor.dto.CoursePushDTO
;
import
cn.com.glsx.dj.supervisor.dto.CourseSearchDTO
;
import
cn.com.glsx.framework.core.annotation.ApiMethod
;
import
cn.com.glsx.framework.core.annotation.ApiParam
;
import
cn.com.glsx.framework.core.annotation.ApiResponse
;
import
cn.com.glsx.framework.core.annotation.ApiService
;
import
cn.com.glsx.framework.core.beans.rpc.RpcPagination
;
import
cn.com.glsx.framework.core.beans.rpc.RpcResponse
;
import
java.util.List
;
@ApiService
(
value
=
"督导学习中心"
,
owner
=
"xiehx"
)
public
interface
SupervisorLearningCenterRemote
{
@ApiMethod
(
"查询全部课程分页接口"
)
@ApiParam
(
name
=
"request"
,
notes
=
"查询条件"
,
dataType
=
ApiParam
.
DataTypeEnum
.
OBJECT
,
required
=
true
)
@ApiResponse
(
"分页结果"
)
RpcResponse
<
RpcPagination
<
CoursePageInfo
>>
allCourse
(
RpcPagination
<
CourseSearchDTO
>
pagination
);
@ApiMethod
(
"批量推送课程给驻店人员"
)
@ApiParam
(
name
=
"coursePushList"
,
notes
=
"课程推送列表"
,
dataType
=
ApiParam
.
DataTypeEnum
.
OBJECT
,
required
=
true
)
@ApiResponse
(
"操作结果"
)
RpcResponse
<
Boolean
>
batchPushCourseToStoreManager
(
List
<
CoursePushDTO
>
coursePushList
);
}
rpc-dj-supervisor-api/src/main/java/cn/com/glsx/dj/supervisor/remote/SupervisorTaskInfoRemote.java
View file @
99d0708
package
cn
.
com
.
glsx
.
dj
.
supervisor
.
remote
;
package
cn
.
com
.
glsx
.
dj
.
supervisor
.
remote
;
import
cn.com.glsx.dj.supervisor.dto.AudioReceptionDTO
;
import
cn.com.glsx.dj.supervisor.dto.AudioSummaryDTO
;
import
cn.com.glsx.dj.supervisor.dto.SupervisorTaskDTO
;
import
cn.com.glsx.dj.supervisor.dto.SupervisorTaskDTO
;
import
cn.com.glsx.dj.supervisor.dto.SupervisorTaskQueryDTO
;
import
cn.com.glsx.dj.supervisor.dto.SupervisorTaskQueryDTO
;
import
cn.com.glsx.dj.supervisor.model.SupervisorAudioReviewInfo
;
import
cn.com.glsx.framework.core.annotation.*
;
import
cn.com.glsx.framework.core.annotation.*
;
import
cn.com.glsx.framework.core.beans.rpc.RpcPagination
;
import
cn.com.glsx.framework.core.beans.rpc.RpcPagination
;
import
cn.com.glsx.framework.core.beans.rpc.RpcResponse
;
import
cn.com.glsx.framework.core.beans.rpc.RpcResponse
;
...
@@ -38,4 +41,40 @@ public interface SupervisorTaskInfoRemote {
...
@@ -38,4 +41,40 @@ public interface SupervisorTaskInfoRemote {
@ApiParams
({
@ApiParam
(
name
=
"request"
,
notes
=
"查询参数"
,
dataType
=
ApiParam
.
DataTypeEnum
.
OBJECT
,
required
=
true
)})
@ApiParams
({
@ApiParam
(
name
=
"request"
,
notes
=
"查询参数"
,
dataType
=
ApiParam
.
DataTypeEnum
.
OBJECT
,
required
=
true
)})
@ApiResponse
(
"提交结果"
)
@ApiResponse
(
"提交结果"
)
RpcResponse
<
RpcPagination
<
SupervisorTaskDTO
>>
pageTask
(
RpcPagination
<
SupervisorTaskQueryDTO
>
request
);
RpcResponse
<
RpcPagination
<
SupervisorTaskDTO
>>
pageTask
(
RpcPagination
<
SupervisorTaskQueryDTO
>
request
);
/**
* 分页查询录音复盘记录
*/
@ApiMethod
(
"分页查询录音复盘记录"
)
@ApiParams
({
@ApiParam
(
name
=
"request"
,
notes
=
"查询参数"
,
dataType
=
ApiParam
.
DataTypeEnum
.
OBJECT
,
required
=
true
)})
@ApiResponse
(
"复盘记录"
)
RpcResponse
<
RpcPagination
<
AudioReceptionDTO
>>
pageAudioReception
(
RpcPagination
<
SupervisorTaskQueryDTO
>
request
);
/**
* 查询录音复盘汇总信息
*/
@ApiMethod
(
"查询录音复盘汇总信息"
)
@ApiParams
({
@ApiParam
(
name
=
"request"
,
notes
=
"查询参数"
,
dataType
=
ApiParam
.
DataTypeEnum
.
OBJECT
,
required
=
true
)})
@ApiResponse
(
"汇总信息"
)
RpcResponse
<
AudioSummaryDTO
>
getAudioSummary
(
SupervisorTaskQueryDTO
request
);
/**
* 提交录音复盘内容
*/
@interface
SubmitAudioReview
{}
@ApiMethod
(
"提交录音复盘内容"
)
@ApiParams
({
@ApiParam
(
name
=
"request"
,
notes
=
"提交参数"
,
dataType
=
ApiParam
.
DataTypeEnum
.
OBJECT
,
required
=
true
)})
@ApiResponse
(
"提交结果"
)
RpcResponse
<
Boolean
>
submitAudioReview
(
SupervisorAudioReviewInfo
request
);
/**
* 发起带教 - 提交
*/
@interface
SubmitCoaching
{}
@ApiMethod
(
"发起带教 - 提交"
)
@ApiParams
({
@ApiParam
(
name
=
"request"
,
notes
=
"带教信息"
,
dataType
=
ApiParam
.
DataTypeEnum
.
OBJECT
,
required
=
true
)})
@ApiResponse
(
"提交结果"
)
RpcResponse
<
Long
>
submitCoaching
(
SupervisorTaskDTO
request
);
}
}
rpc-dj-supervisor/pom.xml
View file @
99d0708
...
@@ -13,6 +13,17 @@
...
@@ -13,6 +13,17 @@
<dependencies>
<dependencies>
<dependency>
<dependency>
<groupId>
cn.hutool
</groupId>
<artifactId>
hutool-all
</artifactId>
<version>
5.8.38
</version>
</dependency>
<dependency>
<groupId>
cn.com.glsx.merchants
</groupId>
<artifactId>
platform-merchants-api
</artifactId>
<version>
5.6.1-SNAPSHOT
</version>
</dependency>
<dependency>
<groupId>
cn.com.glsx.dj
</groupId>
<groupId>
cn.com.glsx.dj
</groupId>
<artifactId>
rpc-dj-supervisor-api
</artifactId>
<artifactId>
rpc-dj-supervisor-api
</artifactId>
<version>
1.0.0-SNAPSHOT
</version>
<version>
1.0.0-SNAPSHOT
</version>
...
...
rpc-dj-supervisor/src/main/java/cn/com/glsx/dj/supervisor/mapper/PersonCourseRecommendationMapper.java
View file @
99d0708
package
cn
.
com
.
glsx
.
dj
.
supervisor
.
mapper
;
package
cn
.
com
.
glsx
.
dj
.
supervisor
.
mapper
;
import
cn.com.glsx.dj.supervisor.dto.CoursePageInfo
;
import
cn.com.glsx.dj.supervisor.dto.CourseSearchDTO
;
import
cn.com.glsx.dj.supervisor.dto.MyselfCourseRecommendDTO
;
import
cn.com.glsx.dj.supervisor.model.PersonCourseRecommendation
;
import
cn.com.glsx.dj.supervisor.model.PersonCourseRecommendation
;
import
org.apache.ibatis.annotations.Mapper
;
import
org.apache.ibatis.annotations.Mapper
;
import
org.oreframework.datasource.mybatis.mapper.OreMapper
;
import
org.oreframework.datasource.mybatis.mapper.OreMapper
;
import
java.util.List
;
@Mapper
@Mapper
public
interface
PersonCourseRecommendationMapper
extends
OreMapper
<
PersonCourseRecommendation
>
{
public
interface
PersonCourseRecommendationMapper
extends
OreMapper
<
PersonCourseRecommendation
>
{
/**
* 分页查询北森全部已分类的正常状态的课程
*
* @param condition
* @return
*/
List
<
CoursePageInfo
>
allCourse
(
CourseSearchDTO
condition
);
List
<
MyselfCourseRecommendDTO
>
getPersonCourseRecommendPage
(
MyselfCourseRecommendDTO
condition
);
}
}
rpc-dj-supervisor/src/main/java/cn/com/glsx/dj/supervisor/mapper/SupervisorAiAnalysisRecordMapper.java
View file @
99d0708
...
@@ -6,4 +6,12 @@ import org.oreframework.datasource.mybatis.mapper.OreMapper;
...
@@ -6,4 +6,12 @@ import org.oreframework.datasource.mybatis.mapper.OreMapper;
@Mapper
@Mapper
public
interface
SupervisorAiAnalysisRecordMapper
extends
OreMapper
<
SupervisorAiAnalysisRecord
>
{
public
interface
SupervisorAiAnalysisRecordMapper
extends
OreMapper
<
SupervisorAiAnalysisRecord
>
{
/**
* 根据条件查询 AI 分析记录(单条)
*
* @param record 查询条件
* @return AI 分析记录
*/
SupervisorAiAnalysisRecord
selectByCondition
(
SupervisorAiAnalysisRecord
record
);
}
}
rpc-dj-supervisor/src/main/java/cn/com/glsx/dj/supervisor/mapper/SupervisorAudioReviewInfoMapper.java
View file @
99d0708
package
cn
.
com
.
glsx
.
dj
.
supervisor
.
mapper
;
package
cn
.
com
.
glsx
.
dj
.
supervisor
.
mapper
;
import
cn.com.glsx.dj.supervisor.dto.AudioReceptionDTO
;
import
cn.com.glsx.dj.supervisor.model.SupervisorAudioReviewInfo
;
import
cn.com.glsx.dj.supervisor.model.SupervisorAudioReviewInfo
;
import
org.apache.ibatis.annotations.Mapper
;
import
org.apache.ibatis.annotations.Mapper
;
import
org.apache.ibatis.annotations.Param
;
import
org.oreframework.datasource.mybatis.mapper.OreMapper
;
import
org.oreframework.datasource.mybatis.mapper.OreMapper
;
import
java.util.List
;
@Mapper
@Mapper
public
interface
SupervisorAudioReviewInfoMapper
extends
OreMapper
<
SupervisorAudioReviewInfo
>
{
public
interface
SupervisorAudioReviewInfoMapper
extends
OreMapper
<
SupervisorAudioReviewInfo
>
{
List
<
AudioReceptionDTO
>
listAudionByReceptionId
(
@Param
(
"relationId"
)
Long
receptionId
);
}
}
\ No newline at end of file
\ No newline at end of file
rpc-dj-supervisor/src/main/java/cn/com/glsx/dj/supervisor/mapper/SupervisorTaskInfoMapper.java
View file @
99d0708
package
cn
.
com
.
glsx
.
dj
.
supervisor
.
mapper
;
package
cn
.
com
.
glsx
.
dj
.
supervisor
.
mapper
;
import
cn.com.glsx.dj.supervisor.dto.MapperQueryEmployeeTrainingInfoDTO
;
import
cn.com.glsx.dj.supervisor.dto.SupervisorTaskDTO
;
import
cn.com.glsx.dj.supervisor.dto.SupervisorTaskDTO
;
import
cn.com.glsx.dj.supervisor.dto.SupervisorTaskQueryDTO
;
import
cn.com.glsx.dj.supervisor.dto.SupervisorTaskQueryDTO
;
import
cn.com.glsx.dj.supervisor.model.SupervisorTaskInfo
;
import
cn.com.glsx.dj.supervisor.model.SupervisorTaskInfo
;
import
org.apache.ibatis.annotations.MapKey
;
import
org.apache.ibatis.annotations.Mapper
;
import
org.apache.ibatis.annotations.Mapper
;
import
org.apache.ibatis.annotations.Param
;
import
org.apache.ibatis.annotations.Param
;
import
org.oreframework.datasource.mybatis.mapper.OreMapper
;
import
org.oreframework.datasource.mybatis.mapper.OreMapper
;
import
java.util.List
;
import
java.util.List
;
import
java.util.Map
;
@Mapper
@Mapper
public
interface
SupervisorTaskInfoMapper
extends
OreMapper
<
SupervisorTaskInfo
>
{
public
interface
SupervisorTaskInfoMapper
extends
OreMapper
<
SupervisorTaskInfo
>
{
...
@@ -24,4 +27,12 @@ public interface SupervisorTaskInfoMapper extends OreMapper<SupervisorTaskInfo>
...
@@ -24,4 +27,12 @@ public interface SupervisorTaskInfoMapper extends OreMapper<SupervisorTaskInfo>
List
<
SupervisorTaskDTO
>
listTask
(
SupervisorTaskQueryDTO
request
);
List
<
SupervisorTaskDTO
>
listTask
(
SupervisorTaskQueryDTO
request
);
@MapKey
(
"userId"
)
Map
<
Integer
,
MapperQueryEmployeeTrainingInfoDTO
>
queryStudyHours
(
@Param
(
"beiSenUserIdList"
)
List
<
Integer
>
beiSenUserIdList
,
@Param
(
"startDate"
)
String
startDate
,
@Param
(
"endDate"
)
String
endDate
);
@MapKey
(
"userId"
)
Map
<
Integer
,
MapperQueryEmployeeTrainingInfoDTO
>
queryCompletedCourses
(
@Param
(
"beiSenUserIdList"
)
List
<
Integer
>
beiSenUserIdList
,
@Param
(
"startDate"
)
String
startDate
,
@Param
(
"endDate"
)
String
endDate
);
@MapKey
(
"phone"
)
Map
<
String
,
MapperQueryEmployeeTrainingInfoDTO
>
queryCoachingTimes
(
@Param
(
"phoneList"
)
List
<
String
>
phoneList
,
@Param
(
"startDate"
)
String
startDate
,
@Param
(
"endDate"
)
String
endDate
);
}
}
\ No newline at end of file
\ No newline at end of file
rpc-dj-supervisor/src/main/java/cn/com/glsx/dj/supervisor/remote/PersonCourseRecommendationRemoteImpl.java
0 → 100644
View file @
99d0708
package
cn
.
com
.
glsx
.
dj
.
supervisor
.
remote
;
import
cn.com.glsx.dj.supervisor.dto.MyselfCourseRecommendDTO
;
import
cn.com.glsx.dj.supervisor.service.PersonCourseRecommendationService
;
import
cn.com.glsx.framework.core.beans.rpc.RpcPagination
;
import
cn.com.glsx.framework.core.beans.rpc.RpcResponse
;
import
cn.com.glsx.framework.core.enums.DefaultErrorEnum
;
import
cn.com.glsx.framework.core.exception.RpcServiceException
;
import
com.github.pagehelper.Page
;
import
lombok.extern.slf4j.Slf4j
;
import
org.apache.dubbo.config.annotation.DubboService
;
import
org.springframework.beans.factory.annotation.Autowired
;
/**
* @Title:
* @Description:
* @Author xiehx
* @Date 2026/3/10
**/
@Slf4j
@DubboService
(
version
=
"1.0.0"
,
retries
=
0
,
timeout
=
30000
,
validation
=
"true"
,
protocol
=
"dubbo"
)
public
class
PersonCourseRecommendationRemoteImpl
implements
PersonCourseRecommendationRemote
{
@Autowired
private
PersonCourseRecommendationService
personCourseRecommendationService
;
@Override
public
RpcResponse
<
RpcPagination
<
MyselfCourseRecommendDTO
>>
getPersonCourseRecommendPage
(
RpcPagination
<
MyselfCourseRecommendDTO
>
pagination
)
{
try
{
Page
<
MyselfCourseRecommendDTO
>
pageRes
=
personCourseRecommendationService
.
getPersonCourseRecommendPage
(
pagination
);
return
RpcResponse
.
success
(
RpcPagination
.
copyPage
(
pageRes
));
}
catch
(
RpcServiceException
e
)
{
log
.
info
(
"getPersonCourseRecommendPage.exception!"
,
e
);
return
RpcResponse
.
error
(
e
.
getError
(),
e
.
getMessage
());
}
catch
(
Exception
e
)
{
log
.
info
(
"getPersonCourseRecommendPage.exception!"
,
e
);
return
RpcResponse
.
error
(
DefaultErrorEnum
.
SERVICE_ERROR
,
e
.
getMessage
());
}
}
}
rpc-dj-supervisor/src/main/java/cn/com/glsx/dj/supervisor/remote/SupervisorAiAnalysisRecordRemoteImpl.java
0 → 100644
View file @
99d0708
package
cn
.
com
.
glsx
.
dj
.
supervisor
.
remote
;
import
cn.com.glsx.dj.supervisor.model.SupervisorAiAnalysisRecord
;
import
cn.com.glsx.dj.supervisor.service.SupervisorAiAnalysisRecordService
;
import
cn.com.glsx.framework.core.beans.rpc.RpcResponse
;
import
cn.com.glsx.framework.core.enums.DefaultErrorEnum
;
import
cn.com.glsx.framework.core.exception.RpcServiceException
;
import
lombok.extern.slf4j.Slf4j
;
import
org.apache.dubbo.config.annotation.DubboService
;
import
org.springframework.beans.factory.annotation.Autowired
;
@Slf4j
@DubboService
(
version
=
"1.0.0"
,
retries
=
0
,
timeout
=
30000
,
validation
=
"true"
)
public
class
SupervisorAiAnalysisRecordRemoteImpl
implements
SupervisorAiAnalysisRecordRemote
{
@Autowired
private
SupervisorAiAnalysisRecordService
supervisorAiAnalysisRecordService
;
@Override
public
RpcResponse
<
SupervisorAiAnalysisRecord
>
getAiAnalysisRecord
(
SupervisorAiAnalysisRecord
request
)
{
try
{
log
.
info
(
"查询 AI 分析记录,请求参数:{}"
,
request
);
SupervisorAiAnalysisRecord
result
=
supervisorAiAnalysisRecordService
.
getAiAnalysisRecord
(
request
);
log
.
info
(
"查询 AI 分析记录成功,记录 ID: {}"
,
result
!=
null
?
result
.
getId
()
:
null
);
return
RpcResponse
.
success
(
result
);
}
catch
(
RpcServiceException
e
)
{
log
.
error
(
"cn.com.glsx.dj.supervisor.remote.SupervisorAiAnalysisRecordRemoteImpl.getAiAnalysisRecord error {}"
,
e
);
return
RpcResponse
.
error
(
e
.
getError
(),
e
.
getMessage
());
}
catch
(
Exception
e
)
{
log
.
error
(
"cn.com.glsx.dj.supervisor.remote.SupervisorAiAnalysisRecordRemoteImpl.getAiAnalysisRecord system error {}"
,
e
);
return
RpcResponse
.
error
(
DefaultErrorEnum
.
SERVICE_ERROR
,
e
.
getMessage
());
}
}
}
rpc-dj-supervisor/src/main/java/cn/com/glsx/dj/supervisor/remote/SupervisorEmployeeTrainingInfoRemoteImpl.java
0 → 100644
View file @
99d0708
package
cn
.
com
.
glsx
.
dj
.
supervisor
.
remote
;
import
cn.com.glsx.dj.supervisor.dto.EmployeeTrainingInfoRequestDTO
;
import
cn.com.glsx.dj.supervisor.dto.EmployeeTrainingInfoDTO
;
import
cn.com.glsx.dj.supervisor.service.SupervisorEmployeeTrainingInfoService
;
import
cn.com.glsx.framework.core.beans.rpc.RpcResponse
;
import
cn.com.glsx.framework.core.enums.DefaultErrorEnum
;
import
cn.com.glsx.framework.core.exception.RpcServiceException
;
import
lombok.extern.slf4j.Slf4j
;
import
org.apache.dubbo.config.annotation.DubboService
;
import
org.springframework.beans.factory.annotation.Autowired
;
import
java.util.List
;
/**
* 督导 - 员工培训信息 RPC 实现类
*
* @author xiehx
* @date 2026 年 3 月 12 日
*/
@Slf4j
@DubboService
(
version
=
"1.0.0"
,
retries
=
0
,
timeout
=
30000
,
validation
=
"true"
)
public
class
SupervisorEmployeeTrainingInfoRemoteImpl
implements
SupervisorEmployeeTrainingInfoRemote
{
@Autowired
private
SupervisorEmployeeTrainingInfoService
supervisorEmployeeTrainingInfoService
;
@Override
public
RpcResponse
<
List
<
EmployeeTrainingInfoDTO
>>
getAllEmployeeTrainingInfo
(
EmployeeTrainingInfoRequestDTO
request
)
{
try
{
log
.
info
(
"查询全部员工培训信息,请求参数:{}"
,
request
);
// 调用 Service 层查询
List
<
EmployeeTrainingInfoDTO
>
result
=
supervisorEmployeeTrainingInfoService
.
getAllEmployeeTrainingInfo
(
request
);
log
.
info
(
"查询全部员工培训信息成功,总记录数:{}"
,
result
!=
null
?
result
.
size
()
:
0
);
return
RpcResponse
.
success
(
result
);
}
catch
(
RpcServiceException
e
)
{
log
.
error
(
"cn.com.glsx.dj.supervisor.remote.SupervisorEmployeeTrainingInfoRemoteImpl.getAllEmployeeTrainingInfo error {}"
,
e
);
return
RpcResponse
.
error
(
e
.
getError
(),
e
.
getMessage
());
}
catch
(
Exception
e
)
{
log
.
error
(
"cn.com.glsx.dj.supervisor.remote.SupervisorEmployeeTrainingInfoRemoteImpl.getAllEmployeeTrainingInfo system error {}"
,
e
);
return
RpcResponse
.
error
(
DefaultErrorEnum
.
SERVICE_ERROR
,
e
.
getMessage
());
}
}
}
rpc-dj-supervisor/src/main/java/cn/com/glsx/dj/supervisor/remote/SupervisorLearningCenterRemoteImpl.java
0 → 100644
View file @
99d0708
package
cn
.
com
.
glsx
.
dj
.
supervisor
.
remote
;
import
cn.com.glsx.dj.supervisor.dto.CoursePageInfo
;
import
cn.com.glsx.dj.supervisor.dto.CoursePushDTO
;
import
cn.com.glsx.dj.supervisor.dto.CourseSearchDTO
;
import
cn.com.glsx.dj.supervisor.service.SupervisorLearningCenterService
;
import
cn.com.glsx.framework.core.beans.rpc.RpcPagination
;
import
cn.com.glsx.framework.core.beans.rpc.RpcResponse
;
import
cn.com.glsx.framework.core.enums.DefaultErrorEnum
;
import
cn.com.glsx.framework.core.exception.RpcServiceException
;
import
com.github.pagehelper.Page
;
import
lombok.extern.slf4j.Slf4j
;
import
org.apache.dubbo.config.annotation.DubboService
;
import
org.springframework.beans.factory.annotation.Autowired
;
import
java.util.List
;
/**
* @Title:
* @Description:
* @Author xiehx
* @Date 2026/3/10
**/
@Slf4j
@DubboService
(
version
=
"1.0.0"
,
retries
=
0
,
timeout
=
30000
,
validation
=
"true"
,
protocol
=
"dubbo"
)
public
class
SupervisorLearningCenterRemoteImpl
implements
SupervisorLearningCenterRemote
{
@Autowired
private
SupervisorLearningCenterService
supervisorLearningCenterService
;
@Override
public
RpcResponse
<
RpcPagination
<
CoursePageInfo
>>
allCourse
(
RpcPagination
<
CourseSearchDTO
>
pagination
)
{
try
{
Page
<
CoursePageInfo
>
pageRes
=
supervisorLearningCenterService
.
allCourse
(
pagination
);
return
RpcResponse
.
success
(
RpcPagination
.
copyPage
(
pageRes
));
}
catch
(
RpcServiceException
e
)
{
log
.
info
(
"allCourse.exception!"
,
e
);
return
RpcResponse
.
error
(
e
.
getError
(),
e
.
getMessage
());
}
catch
(
Exception
e
)
{
log
.
info
(
"allCourse.exception!"
,
e
);
return
RpcResponse
.
error
(
DefaultErrorEnum
.
SERVICE_ERROR
,
e
.
getMessage
());
}
}
@Override
public
RpcResponse
<
Boolean
>
batchPushCourseToStoreManager
(
List
<
CoursePushDTO
>
coursePushList
)
{
try
{
Boolean
result
=
supervisorLearningCenterService
.
batchPushCourseToStoreManager
(
coursePushList
);
return
RpcResponse
.
success
(
result
);
}
catch
(
RpcServiceException
e
)
{
log
.
info
(
"batchPushCourseToStoreManager.exception!"
,
e
);
return
RpcResponse
.
error
(
e
.
getError
(),
e
.
getMessage
());
}
catch
(
Exception
e
)
{
log
.
info
(
"batchPushCourseToStoreManager.exception!"
,
e
);
return
RpcResponse
.
error
(
DefaultErrorEnum
.
SERVICE_ERROR
,
e
.
getMessage
());
}
}
}
rpc-dj-supervisor/src/main/java/cn/com/glsx/dj/supervisor/remote/SupervisorTaskInfoRemoteImpl.java
View file @
99d0708
package
cn
.
com
.
glsx
.
dj
.
supervisor
.
remote
;
package
cn
.
com
.
glsx
.
dj
.
supervisor
.
remote
;
import
cn.com.glsx.dj.supervisor.dto.AudioReceptionDTO
;
import
cn.com.glsx.dj.supervisor.dto.AudioSummaryDTO
;
import
cn.com.glsx.dj.supervisor.dto.SupervisorTaskDTO
;
import
cn.com.glsx.dj.supervisor.dto.SupervisorTaskDTO
;
import
cn.com.glsx.dj.supervisor.dto.SupervisorTaskQueryDTO
;
import
cn.com.glsx.dj.supervisor.dto.SupervisorTaskQueryDTO
;
import
cn.com.glsx.dj.supervisor.model.SupervisorAudioReviewInfo
;
import
cn.com.glsx.dj.supervisor.service.SupervisorAudioReviewInfoService
;
import
cn.com.glsx.dj.supervisor.service.SupervisorTaskInfoService
;
import
cn.com.glsx.dj.supervisor.service.SupervisorTaskInfoService
;
import
cn.com.glsx.framework.core.beans.rpc.RpcPagination
;
import
cn.com.glsx.framework.core.beans.rpc.RpcPagination
;
import
cn.com.glsx.framework.core.beans.rpc.RpcResponse
;
import
cn.com.glsx.framework.core.beans.rpc.RpcResponse
;
...
@@ -18,6 +22,9 @@ public class SupervisorTaskInfoRemoteImpl implements SupervisorTaskInfoRemote {
...
@@ -18,6 +22,9 @@ public class SupervisorTaskInfoRemoteImpl implements SupervisorTaskInfoRemote {
@Autowired
@Autowired
private
SupervisorTaskInfoService
supervisorTaskInfoService
;
private
SupervisorTaskInfoService
supervisorTaskInfoService
;
@Autowired
private
SupervisorAudioReviewInfoService
supervisorAudioReviewInfoService
;
@Override
@Override
public
RpcResponse
<
Boolean
>
submitDayTask
(
SupervisorTaskDTO
request
)
{
public
RpcResponse
<
Boolean
>
submitDayTask
(
SupervisorTaskDTO
request
)
{
try
{
try
{
...
@@ -87,4 +94,62 @@ public class SupervisorTaskInfoRemoteImpl implements SupervisorTaskInfoRemote {
...
@@ -87,4 +94,62 @@ public class SupervisorTaskInfoRemoteImpl implements SupervisorTaskInfoRemote {
return
RpcResponse
.
error
(
DefaultErrorEnum
.
SERVER_ERROR
,
e
.
getMessage
());
return
RpcResponse
.
error
(
DefaultErrorEnum
.
SERVER_ERROR
,
e
.
getMessage
());
}
}
}
}
@Override
public
RpcResponse
<
RpcPagination
<
AudioReceptionDTO
>>
pageAudioReception
(
RpcPagination
<
SupervisorTaskQueryDTO
>
request
)
{
try
{
Page
result
=
supervisorAudioReviewInfoService
.
pageAudioReception
(
request
);
return
RpcResponse
.
success
(
RpcPagination
.
copyPage
(
result
));
}
catch
(
RpcServiceException
e
)
{
log
.
error
(
"cn.com.glsx.dj.supervisor.remote.SupervisorTaskInfoRemoteImpl.pageAudioReception error {}"
,
e
);
return
RpcResponse
.
error
(
e
.
getError
(),
e
.
getMessage
());
}
catch
(
Exception
e
)
{
log
.
error
(
"cn.com.glsx.dj.supervisor.remote.SupervisorTaskInfoRemoteImpl.pageAudioReception system error {}"
,
e
);
return
RpcResponse
.
error
(
DefaultErrorEnum
.
SERVER_ERROR
,
e
.
getMessage
());
}
}
@Override
public
RpcResponse
<
AudioSummaryDTO
>
getAudioSummary
(
SupervisorTaskQueryDTO
request
)
{
try
{
AudioSummaryDTO
result
=
supervisorAudioReviewInfoService
.
getAudioSummary
(
request
);
return
RpcResponse
.
success
(
result
);
}
catch
(
RpcServiceException
e
)
{
log
.
error
(
"cn.com.glsx.dj.supervisor.remote.SupervisorTaskInfoRemoteImpl.getAudioSummary error {}"
,
e
);
return
RpcResponse
.
error
(
e
.
getError
(),
e
.
getMessage
());
}
catch
(
Exception
e
)
{
log
.
error
(
"cn.com.glsx.dj.supervisor.remote.SupervisorTaskInfoRemoteImpl.getAudioSummary system error {}"
,
e
);
return
RpcResponse
.
error
(
DefaultErrorEnum
.
SERVER_ERROR
,
e
.
getMessage
());
}
}
@Override
public
RpcResponse
<
Boolean
>
submitAudioReview
(
SupervisorAudioReviewInfo
request
)
{
try
{
Boolean
result
=
supervisorAudioReviewInfoService
.
submitAudioReview
(
request
);
return
RpcResponse
.
success
(
result
);
}
catch
(
RpcServiceException
e
)
{
log
.
error
(
"cn.com.glsx.dj.supervisor.remote.SupervisorTaskInfoRemoteImpl.submitAudioReview error {}"
,
e
);
return
RpcResponse
.
error
(
e
.
getError
(),
e
.
getMessage
());
}
catch
(
Exception
e
)
{
log
.
error
(
"cn.com.glsx.dj.supervisor.remote.SupervisorTaskInfoRemoteImpl.submitAudioReview system error {}"
,
e
);
return
RpcResponse
.
error
(
DefaultErrorEnum
.
SERVER_ERROR
,
e
.
getMessage
());
}
}
@Override
public
RpcResponse
<
Long
>
submitCoaching
(
SupervisorTaskDTO
request
)
{
try
{
log
.
info
(
"发起带教 - 提交,请求参数:{}"
,
request
);
Long
taskId
=
supervisorTaskInfoService
.
submitCoaching
(
request
);
log
.
info
(
"发起带教 - 提交成功,taskId={}"
,
taskId
);
return
RpcResponse
.
success
(
taskId
);
}
catch
(
RpcServiceException
e
)
{
log
.
error
(
"cn.com.glsx.dj.supervisor.remote.SupervisorTaskInfoRemoteImpl.submitCoaching error {}"
,
e
);
return
RpcResponse
.
error
(
e
.
getError
(),
e
.
getMessage
());
}
catch
(
Exception
e
)
{
log
.
error
(
"cn.com.glsx.dj.supervisor.remote.SupervisorTaskInfoRemoteImpl.submitCoaching system error {}"
,
e
);
return
RpcResponse
.
error
(
DefaultErrorEnum
.
SERVER_ERROR
,
e
.
getMessage
());
}
}
}
}
rpc-dj-supervisor/src/main/java/cn/com/glsx/dj/supervisor/service/PersonCourseRecommendationService.java
0 → 100644
View file @
99d0708
package
cn
.
com
.
glsx
.
dj
.
supervisor
.
service
;
import
cn.com.glsx.dj.supervisor.dto.MyselfCourseRecommendDTO
;
import
cn.com.glsx.dj.supervisor.mapper.PersonCourseRecommendationMapper
;
import
cn.com.glsx.framework.core.beans.rpc.RpcPagination
;
import
com.github.pagehelper.Page
;
import
com.github.pagehelper.PageHelper
;
import
lombok.extern.slf4j.Slf4j
;
import
org.springframework.beans.factory.annotation.Autowired
;
import
org.springframework.stereotype.Service
;
/**
* @Title:
* @Description:
* @Author xiehx
* @Date 2026/3/10
**/
@Service
@Slf4j
public
class
PersonCourseRecommendationService
{
@Autowired
private
PersonCourseRecommendationMapper
personCourseRecommendationMapper
;
/**
* 分页查询人员课程推荐数据
*
* @param pagination 分页参数
* @return 分页结果
*/
public
Page
<
MyselfCourseRecommendDTO
>
getPersonCourseRecommendPage
(
RpcPagination
<
MyselfCourseRecommendDTO
>
pagination
)
{
Page
<
MyselfCourseRecommendDTO
>
page
=
PageHelper
.
startPage
(
pagination
.
getPageNum
(),
pagination
.
getPageSize
());
personCourseRecommendationMapper
.
getPersonCourseRecommendPage
(
pagination
.
getCondition
());
log
.
info
(
"分页查询人员课程推荐数据,pagination={}"
,
pagination
);
return
page
;
}
}
rpc-dj-supervisor/src/main/java/cn/com/glsx/dj/supervisor/service/SupervisorAiAnalysisRecordService.java
0 → 100644
View file @
99d0708
package
cn
.
com
.
glsx
.
dj
.
supervisor
.
service
;
import
cn.com.glsx.dj.supervisor.mapper.SupervisorAiAnalysisRecordMapper
;
import
cn.com.glsx.dj.supervisor.model.SupervisorAiAnalysisRecord
;
import
cn.com.glsx.framework.core.beans.BaseModel
;
import
cn.hutool.core.date.DateUtil
;
import
lombok.extern.slf4j.Slf4j
;
import
org.springframework.beans.factory.annotation.Autowired
;
import
org.springframework.stereotype.Service
;
/**
* 督导 AI 分析记录 Service 实现类
*
* @author Alvin
* @date 2026 年 3 月 11 日
*/
@Slf4j
@Service
public
class
SupervisorAiAnalysisRecordService
{
@Autowired
private
SupervisorAiAnalysisRecordMapper
supervisorAiAnalysisRecordMapper
;
public
SupervisorAiAnalysisRecord
getAiAnalysisRecord
(
SupervisorAiAnalysisRecord
record
)
{
try
{
log
.
info
(
"查询 AI 分析记录,查询条件:{}"
,
record
);
// 如果 startDate 和 endDate 包含时间,转换为纯日期格式
if
(
record
.
getStartDate
()
!=
null
)
{
// 去除时间部分,只保留日期
record
.
setStartDate
(
DateUtil
.
beginOfDay
(
record
.
getStartDate
()));
}
if
(
record
.
getEndDate
()
!=
null
)
{
record
.
setEndDate
(
DateUtil
.
endOfDay
(
record
.
getEndDate
()));
}
record
.
setDeletedFlag
(
BaseModel
.
DeletedFlagEnum
.
N
.
name
());
SupervisorAiAnalysisRecord
result
=
supervisorAiAnalysisRecordMapper
.
selectByCondition
(
record
);
return
result
;
}
catch
(
Exception
e
)
{
log
.
error
(
"查询 AI 分析记录异常"
,
e
);
throw
new
RuntimeException
(
"查询失败:"
+
e
.
getMessage
(),
e
);
}
}
}
rpc-dj-supervisor/src/main/java/cn/com/glsx/dj/supervisor/service/SupervisorAudioReviewInfoService.java
View file @
99d0708
package
cn
.
com
.
glsx
.
dj
.
supervisor
.
service
;
package
cn
.
com
.
glsx
.
dj
.
supervisor
.
service
;
import
cn.com.glsx.dj.supervisor.dto.AudioReceptionDTO
;
import
cn.com.glsx.dj.supervisor.dto.AudioSummaryDTO
;
import
cn.com.glsx.dj.supervisor.dto.SupervisorTaskQueryDTO
;
import
cn.com.glsx.dj.supervisor.enums.ReviewStatusEnum
;
import
cn.com.glsx.dj.supervisor.enums.TaskStatusEnum
;
import
cn.com.glsx.dj.supervisor.mapper.SupervisorAudioReviewInfoMapper
;
import
cn.com.glsx.dj.supervisor.mapper.SupervisorAudioReviewInfoMapper
;
import
cn.com.glsx.dj.supervisor.model.SupervisorAudioReviewInfo
;
import
cn.com.glsx.dj.supervisor.model.SupervisorAudioReviewInfo
;
import
cn.com.glsx.framework.core.beans.BaseModel
;
import
cn.com.glsx.framework.core.beans.BaseModel
;
import
cn.com.glsx.framework.core.beans.rpc.RpcPagination
;
import
cn.com.glsx.framework.core.enums.DefaultErrorEnum
;
import
cn.com.glsx.framework.core.exception.RpcServiceException
;
import
com.github.pagehelper.Page
;
import
com.github.pagehelper.PageHelper
;
import
lombok.extern.slf4j.Slf4j
;
import
lombok.extern.slf4j.Slf4j
;
import
org.apache.commons.collections.CollectionUtils
;
import
org.oreframework.distribute.lock.annotation.GlsxDistributeLockable
;
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.transaction.annotation.Propagation
;
import
org.springframework.transaction.annotation.Transactional
;
import
tk.mybatis.mapper.entity.Example
;
import
tk.mybatis.mapper.entity.Example
;
import
java.util.Arrays
;
import
java.util.Date
;
import
java.util.List
;
import
java.util.List
;
@Service
@Service
...
@@ -17,6 +33,10 @@ public class SupervisorAudioReviewInfoService {
...
@@ -17,6 +33,10 @@ public class SupervisorAudioReviewInfoService {
@Autowired
@Autowired
private
SupervisorAudioReviewInfoMapper
supervisorAudioReviewInfoMapper
;
private
SupervisorAudioReviewInfoMapper
supervisorAudioReviewInfoMapper
;
@Autowired
private
SupervisorTaskInfoService
supervisorTaskInfoService
;
/**
/**
* 根据任务id列表,查询录音信息
* 根据任务id列表,查询录音信息
...
@@ -29,6 +49,73 @@ public class SupervisorAudioReviewInfoService {
...
@@ -29,6 +49,73 @@ public class SupervisorAudioReviewInfoService {
}
}
/**
* 分页查询录音复盘记录
* @param request
* @return
*/
public
Page
<
AudioReceptionDTO
>
pageAudioReception
(
RpcPagination
<
SupervisorTaskQueryDTO
>
request
)
{
//分页查询
Page
<
AudioReceptionDTO
>
page
=
PageHelper
.
startPage
(
request
.
getPageNum
(),
request
.
getPageSize
());
supervisorAudioReviewInfoMapper
.
listAudionByReceptionId
(
request
.
getCondition
().
getId
());
return
page
;
}
/**
* 查询录音复盘汇总信息
* @param request
* @return
*/
public
AudioSummaryDTO
getAudioSummary
(
SupervisorTaskQueryDTO
request
)
{
List
<
SupervisorAudioReviewInfo
>
list
=
listByTaskIds
(
Arrays
.
asList
(
request
.
getId
()));
AudioSummaryDTO
dto
=
new
AudioSummaryDTO
();
if
(
CollectionUtils
.
isNotEmpty
(
list
))
{
//根据复盘状态,统计已复盘,未复盘数量,并设置到返回结果
long
reviewedCount
=
list
.
stream
().
filter
(
item
->
ReviewStatusEnum
.
COMPLETED
.
getCode
().
equals
(
item
.
getReviewStatus
())).
count
();
long
unreviewedCount
=
list
.
stream
().
filter
(
item
->
ReviewStatusEnum
.
PENDING
.
getCode
().
equals
(
item
.
getReviewStatus
())).
count
();
dto
.
setReviewedCount
((
int
)
reviewedCount
);
dto
.
setUnreviewedCount
((
int
)
unreviewedCount
);
dto
.
setTotalCount
(
list
.
size
());
}
return
dto
;
}
/**
* 提交录音复盘记录, 添加事务,分布式锁
* @param request
* @return
*/
@GlsxDistributeLockable
(
name
=
"SupervisorAudioReviewInfoService_submitAudioReview"
)
@Transactional
(
propagation
=
Propagation
.
REQUIRED
,
rollbackFor
=
Exception
.
class
)
public
Boolean
submitAudioReview
(
SupervisorAudioReviewInfo
request
)
{
//根据id查询录音复盘记录,判断是否存在
SupervisorAudioReviewInfo
info
=
supervisorAudioReviewInfoMapper
.
selectByPrimaryKey
(
request
.
getId
());
if
(
info
==
null
)
{
log
.
error
(
"提交录音复盘记录,录音复盘记录不存在,id={}"
,
request
.
getId
());
throw
new
RpcServiceException
(
DefaultErrorEnum
.
DATA_NOT_EXIST
,
"录音复盘记录不存在"
);
}
//判断是否已复盘
if
(
ReviewStatusEnum
.
COMPLETED
.
getCode
().
equals
(
info
.
getReviewStatus
()))
{
log
.
error
(
"提交录音复盘记录,录音复盘记录已复盘,id={}"
,
request
.
getId
());
throw
new
RpcServiceException
(
DefaultErrorEnum
.
SERVER_ERROR
,
"录音复盘记录已复盘,不能重复提交"
);
}
request
.
setUpdatedDate
(
new
Date
());
request
.
setReviewStatus
(
ReviewStatusEnum
.
COMPLETED
.
getCode
());
supervisorAudioReviewInfoMapper
.
updateByPrimaryKeySelective
(
request
);
//查询关联任务中其他录音是否全部复盘,若全部复盘,则更新任务状态为已完成
List
<
SupervisorAudioReviewInfo
>
list
=
listByTaskIds
(
Arrays
.
asList
(
info
.
getRelationId
()));
if
(
CollectionUtils
.
isNotEmpty
(
list
))
{
//判断是否全部复盘
boolean
allReviewed
=
list
.
stream
().
allMatch
(
item
->
ReviewStatusEnum
.
COMPLETED
.
getCode
().
equals
(
item
.
getReviewStatus
()));
if
(
allReviewed
)
{
//更新任务状态为已完成
supervisorTaskInfoService
.
updateTaskStatus
(
info
.
getRelationId
(),
TaskStatusEnum
.
COMPLETED
.
getCode
(),
request
.
getUpdatedBy
());
}
}
return
true
;
}
...
...
rpc-dj-supervisor/src/main/java/cn/com/glsx/dj/supervisor/service/SupervisorEmployeeTrainingInfoService.java
0 → 100644
View file @
99d0708
package
cn
.
com
.
glsx
.
dj
.
supervisor
.
service
;
import
cn.com.glsx.dj.supervisor.dto.EmployeeTrainingInfoDTO
;
import
cn.com.glsx.dj.supervisor.dto.EmployeeTrainingInfoRequestDTO
;
import
cn.com.glsx.dj.supervisor.dto.MapperQueryEmployeeTrainingInfoDTO
;
import
cn.com.glsx.dj.supervisor.mapper.SupervisorTaskInfoMapper
;
import
cn.com.glsx.merchants.dto.beisen.BeiSenEmployeeListResonseDTO
;
import
lombok.extern.slf4j.Slf4j
;
import
org.springframework.beans.factory.annotation.Autowired
;
import
org.springframework.stereotype.Service
;
import
java.util.ArrayList
;
import
java.util.List
;
import
java.util.Map
;
import
java.util.stream.Collectors
;
/**
* 督导 - 员工培训信息 Service
*
* @author xiehx
* @date 2026 年 3 月 12 日
*/
@Service
@Slf4j
public
class
SupervisorEmployeeTrainingInfoService
{
@Autowired
private
SupervisorLearningCenterService
supervisorLearningCenterService
;
@Autowired
private
SupervisorTaskInfoMapper
supervisorTaskInfoMapper
;
/**
* 根据条件查询全部员工培训信息列表
*
* @param request 查询条件
* @return 员工培训信息列表
*/
public
List
<
EmployeeTrainingInfoDTO
>
getAllEmployeeTrainingInfo
(
EmployeeTrainingInfoRequestDTO
request
)
{
// TODO 1、根据督导手机号、业务类型 关联查询全部员工信息 判空处理等
List
<
String
>
phoneList
=
new
ArrayList
<
String
>();
phoneList
.
add
(
"13603070903"
);
List
<
BeiSenEmployeeListResonseDTO
>
beiSenEmployeeList
=
supervisorLearningCenterService
.
listEmployeeInfoByStaffPhone
(
phoneList
);
List
<
Integer
>
beiSenUserIdList
=
beiSenEmployeeList
.
stream
().
map
(
beiSenEmployeeListResonseDTO
->
beiSenEmployeeListResonseDTO
.
getUserID
()).
collect
(
Collectors
.
toList
());
Map
<
Integer
,
MapperQueryEmployeeTrainingInfoDTO
>
studyHoursMap
=
supervisorTaskInfoMapper
.
queryStudyHours
(
beiSenUserIdList
,
request
.
getStartDate
(),
request
.
getEndDate
());
Map
<
Integer
,
MapperQueryEmployeeTrainingInfoDTO
>
completedCoursesMap
=
supervisorTaskInfoMapper
.
queryCompletedCourses
(
beiSenUserIdList
,
request
.
getStartDate
(),
request
.
getEndDate
());
Map
<
String
,
MapperQueryEmployeeTrainingInfoDTO
>
coachingTimesMap
=
supervisorTaskInfoMapper
.
queryCoachingTimes
(
phoneList
,
request
.
getStartDate
(),
request
.
getEndDate
());
List
<
EmployeeTrainingInfoDTO
>
employeeTrainingInfoList
=
beiSenEmployeeList
.
stream
().
map
(
beiSenEmployeeListResonseDTO
->
{
EmployeeTrainingInfoDTO
employeeTrainingInfo
=
new
EmployeeTrainingInfoDTO
();
employeeTrainingInfo
.
setEmployeeName
(
beiSenEmployeeListResonseDTO
.
getName
());
employeeTrainingInfo
.
setPhone
(
beiSenEmployeeListResonseDTO
.
getMobilePhone
());
MapperQueryEmployeeTrainingInfoDTO
studyHours
=
studyHoursMap
.
get
(
beiSenEmployeeListResonseDTO
.
getUserID
().
intValue
());
employeeTrainingInfo
.
setStudyHours
(
studyHours
!=
null
?
studyHours
.
getStudyHours
()
:
null
);
MapperQueryEmployeeTrainingInfoDTO
completedCourses
=
completedCoursesMap
.
get
(
beiSenEmployeeListResonseDTO
.
getUserID
().
intValue
());
employeeTrainingInfo
.
setCompletedCourses
(
completedCourses
!=
null
?
completedCourses
.
getCompletedCourses
()
:
null
);
MapperQueryEmployeeTrainingInfoDTO
coachingTimes
=
coachingTimesMap
.
get
(
beiSenEmployeeListResonseDTO
.
getMobilePhone
());
employeeTrainingInfo
.
setCoachingTimes
(
coachingTimes
!=
null
?
coachingTimes
.
getCoachingTimes
()
:
null
);
return
employeeTrainingInfo
;
}).
collect
(
Collectors
.
toList
());
// 根据排序参数值进行排序
employeeTrainingInfoList
.
sort
((
o1
,
o2
)
->
{
if
(
request
.
getSortField
()
==
1
)
{
return
request
.
getSortOrder
()
==
1
?
o1
.
getStudyHours
().
compareTo
(
o2
.
getStudyHours
())
:
o2
.
getStudyHours
().
compareTo
(
o1
.
getStudyHours
());
}
else
if
(
request
.
getSortField
()
==
2
)
{
return
request
.
getSortOrder
()
==
1
?
o1
.
getCompletedCourses
().
compareTo
(
o2
.
getCompletedCourses
())
:
o2
.
getCompletedCourses
().
compareTo
(
o1
.
getCompletedCourses
());
}
else
if
(
request
.
getSortField
()
==
3
)
{
return
request
.
getSortOrder
()
==
1
?
o1
.
getCoachingTimes
().
compareTo
(
o2
.
getCoachingTimes
())
:
o2
.
getCoachingTimes
().
compareTo
(
o1
.
getCoachingTimes
());
}
return
0
;
});
return
employeeTrainingInfoList
;
}
}
rpc-dj-supervisor/src/main/java/cn/com/glsx/dj/supervisor/service/SupervisorLearningCenterService.java
0 → 100644
View file @
99d0708
package
cn
.
com
.
glsx
.
dj
.
supervisor
.
service
;
import
cn.com.glsx.dj.supervisor.dto.CoursePageInfo
;
import
cn.com.glsx.dj.supervisor.dto.CoursePushDTO
;
import
cn.com.glsx.dj.supervisor.dto.CourseSearchDTO
;
import
cn.com.glsx.dj.supervisor.enums.BeisenCourseStatusEnum
;
import
cn.com.glsx.dj.supervisor.enums.PushSourceEnum
;
import
cn.com.glsx.dj.supervisor.mapper.PersonCourseRecommendationMapper
;
import
cn.com.glsx.dj.supervisor.model.PersonCourseRecommendation
;
import
cn.com.glsx.framework.core.beans.BaseModel
;
import
cn.com.glsx.framework.core.beans.rpc.RpcPagination
;
import
cn.com.glsx.framework.core.beans.rpc.RpcResponse
;
import
cn.com.glsx.framework.core.enums.DefaultErrorEnum
;
import
cn.com.glsx.framework.core.util.RpcAssert
;
import
cn.com.glsx.merchants.dto.beisen.BeiSenEmployeeListRequestDTO
;
import
cn.com.glsx.merchants.dto.beisen.BeiSenEmployeeListResonseDTO
;
import
cn.com.glsx.merchants.remote.MerchantStaffRemote
;
import
com.github.pagehelper.Page
;
import
com.github.pagehelper.PageHelper
;
import
lombok.extern.slf4j.Slf4j
;
import
org.springframework.beans.BeanUtils
;
import
org.springframework.beans.factory.annotation.Autowired
;
import
org.springframework.stereotype.Service
;
import
org.springframework.transaction.annotation.Transactional
;
import
org.springframework.util.CollectionUtils
;
import
java.util.*
;
import
java.util.stream.Collectors
;
/**
* @Title:
* @Description:
* @Author xiehx
* @Date 2026/3/10
**/
@Service
@Slf4j
public
class
SupervisorLearningCenterService
{
@Autowired
private
PersonCourseRecommendationMapper
personCourseRecommendationMapper
;
@Autowired
private
MerchantStaffRemote
merchantStaffRemote
;
public
Page
<
CoursePageInfo
>
allCourse
(
RpcPagination
<
CourseSearchDTO
>
pagination
)
{
CourseSearchDTO
condition
=
pagination
.
getCondition
();
condition
.
setCourseStatus
(
BeisenCourseStatusEnum
.
RELEASED
.
getCode
());
//分页查询
Page
<
CoursePageInfo
>
page
=
PageHelper
.
startPage
(
pagination
.
getPageNum
(),
pagination
.
getPageSize
());
personCourseRecommendationMapper
.
allCourse
(
condition
);
return
page
;
}
/**
* 批量推送课程给驻店人员
*
* @param coursePushList 课程推送列表
* @return 操作结果
*/
@Transactional
public
Boolean
batchPushCourseToStoreManager
(
List
<
CoursePushDTO
>
coursePushList
)
{
if
(
CollectionUtils
.
isEmpty
(
coursePushList
))
{
log
.
warn
(
"批量推送课程给驻店人员,参数为空"
);
return
false
;
}
List
<
String
>
phoneList
=
coursePushList
.
stream
().
map
(
CoursePushDTO:
:
getStoreManagerPhone
).
distinct
().
collect
(
Collectors
.
toList
());
List
<
BeiSenEmployeeListResonseDTO
>
employeeList
=
listEmployeeInfoByStaffPhone
(
phoneList
);
Map
<
String
,
Integer
>
phoneUserIdMap
=
Collections
.
EMPTY_MAP
;
if
(
org
.
apache
.
commons
.
collections4
.
CollectionUtils
.
isNotEmpty
(
employeeList
))
{
//构建map
phoneUserIdMap
=
employeeList
.
stream
().
collect
(
Collectors
.
toMap
(
BeiSenEmployeeListResonseDTO:
:
getMobilePhone
,
BeiSenEmployeeListResonseDTO:
:
getUserID
));
}
Date
date
=
new
Date
();
List
<
PersonCourseRecommendation
>
recordList
=
new
ArrayList
<>();
// 遍历参数,转换为 PersonCourseRecommendation 对象
for
(
CoursePushDTO
dto
:
coursePushList
)
{
PersonCourseRecommendation
record
=
new
PersonCourseRecommendation
();
BeanUtils
.
copyProperties
(
dto
,
record
);
record
.
setPersonPhone
(
dto
.
getStoreManagerPhone
());
record
.
setPersonName
(
dto
.
getStoreManagerName
());
record
.
setBeisenUserId
(
phoneUserIdMap
.
get
(
dto
.
getStoreManagerPhone
()));
record
.
setPushSource
(
PushSourceEnum
.
SUPERVISOR
.
getCode
());
record
.
setCreatedTime
(
date
);
record
.
setDeletedFlag
(
BaseModel
.
DeletedFlagEnum
.
N
.
name
());
recordList
.
add
(
record
);
}
// 批量插入
int
count
=
personCourseRecommendationMapper
.
insertList
(
recordList
);
log
.
info
(
"批量推送课程给驻店人员成功,记录数={}, coursePushList={}"
,
count
,
coursePushList
.
size
());
return
count
>
0
;
}
public
List
<
BeiSenEmployeeListResonseDTO
>
listEmployeeInfoByStaffPhone
(
List
<
String
>
phoneList
)
{
RpcAssert
.
assertNotEmpty
(
phoneList
,
DefaultErrorEnum
.
PARAMETER_NULL
,
"员工手机号不能为空"
);
RpcPagination
<
BeiSenEmployeeListRequestDTO
>
pagination
=
new
RpcPagination
<>();
BeiSenEmployeeListRequestDTO
condition
=
new
BeiSenEmployeeListRequestDTO
();
pagination
.
setCondition
(
condition
);
pagination
.
setPageNum
(
1
);
pagination
.
setPageSize
(
phoneList
.
size
());
condition
.
setMobilePhoneList
(
phoneList
);
RpcResponse
<
RpcPagination
<
BeiSenEmployeeListResonseDTO
>>
rpcRes
=
merchantStaffRemote
.
getBeisenUserWithConditions
(
pagination
);
RpcPagination
<
BeiSenEmployeeListResonseDTO
>
result
=
rpcRes
.
getResult
();
if
(
result
==
null
||
org
.
apache
.
commons
.
collections4
.
CollectionUtils
.
isEmpty
(
result
.
getList
()))
{
return
null
;
}
return
result
.
getList
();
}
}
rpc-dj-supervisor/src/main/java/cn/com/glsx/dj/supervisor/service/SupervisorTaskCourseService.java
0 → 100644
View file @
99d0708
package
cn
.
com
.
glsx
.
dj
.
supervisor
.
service
;
import
cn.com.glsx.dj.supervisor.mapper.SupervisorTaskCourseMapper
;
import
cn.com.glsx.dj.supervisor.model.SupervisorTaskCourse
;
import
cn.com.glsx.framework.core.beans.BaseModel
;
import
lombok.extern.slf4j.Slf4j
;
import
org.springframework.beans.factory.annotation.Autowired
;
import
org.springframework.stereotype.Service
;
import
tk.mybatis.mapper.entity.Example
;
import
java.util.List
;
@Service
@Slf4j
public
class
SupervisorTaskCourseService
{
@Autowired
private
SupervisorTaskCourseMapper
supervisorTaskCourseMapper
;
/**
* 根据任务ID查询带教任务课程列表
*
* @param taskId
* @return
*/
public
List
<
SupervisorTaskCourse
>
selectByTaskId
(
Long
taskId
)
{
Example
example
=
new
Example
(
SupervisorTaskCourse
.
class
);
example
.
createCriteria
().
andEqualTo
(
"taskId"
,
taskId
).
andEqualTo
(
"deletedFlag"
,
BaseModel
.
DeletedFlagEnum
.
N
.
name
());
return
supervisorTaskCourseMapper
.
selectByExample
(
example
);
}
}
rpc-dj-supervisor/src/main/java/cn/com/glsx/dj/supervisor/service/SupervisorTaskInfoService.java
View file @
99d0708
package
cn
.
com
.
glsx
.
dj
.
supervisor
.
service
;
package
cn
.
com
.
glsx
.
dj
.
supervisor
.
service
;
import
cn.com.glsx.dj.supervisor.dto.CoursePushDTO
;
import
cn.com.glsx.dj.supervisor.dto.SupervisorTaskDTO
;
import
cn.com.glsx.dj.supervisor.dto.SupervisorTaskDTO
;
import
cn.com.glsx.dj.supervisor.dto.SupervisorTaskQueryDTO
;
import
cn.com.glsx.dj.supervisor.dto.SupervisorTaskQueryDTO
;
import
cn.com.glsx.dj.supervisor.enums.ReviewStatusEnum
;
import
cn.com.glsx.dj.supervisor.enums.ReviewStatusEnum
;
import
cn.com.glsx.dj.supervisor.enums.TaskStatusEnum
;
import
cn.com.glsx.dj.supervisor.enums.TaskStatusEnum
;
import
cn.com.glsx.dj.supervisor.enums.TaskTypeEnum
;
import
cn.com.glsx.dj.supervisor.enums.TaskTypeEnum
;
import
cn.com.glsx.dj.supervisor.mapper.SupervisorTaskCourseMapper
;
import
cn.com.glsx.dj.supervisor.mapper.SupervisorTaskImageMapper
;
import
cn.com.glsx.dj.supervisor.mapper.SupervisorTaskInfoMapper
;
import
cn.com.glsx.dj.supervisor.mapper.SupervisorTaskInfoMapper
;
import
cn.com.glsx.dj.supervisor.model.SupervisorAudioReviewInfo
;
import
cn.com.glsx.dj.supervisor.model.*
;
import
cn.com.glsx.dj.supervisor.model.SupervisorTaskInfo
;
import
cn.com.glsx.dj.supervisor.model.SupervisorWeekTaskStaff
;
import
cn.com.glsx.framework.core.beans.BaseModel
;
import
cn.com.glsx.framework.core.beans.BaseModel
;
import
cn.com.glsx.framework.core.beans.rpc.RpcPagination
;
import
cn.com.glsx.framework.core.beans.rpc.RpcPagination
;
import
cn.com.glsx.framework.core.beans.rpc.RpcResponse
;
import
cn.com.glsx.framework.core.beans.rpc.RpcResponse
;
...
@@ -30,6 +31,7 @@ import org.springframework.stereotype.Service;
...
@@ -30,6 +31,7 @@ import org.springframework.stereotype.Service;
import
org.springframework.transaction.annotation.Propagation
;
import
org.springframework.transaction.annotation.Propagation
;
import
org.springframework.transaction.annotation.Transactional
;
import
org.springframework.transaction.annotation.Transactional
;
import
java.util.ArrayList
;
import
java.util.Date
;
import
java.util.Date
;
import
java.util.List
;
import
java.util.List
;
import
java.util.Map
;
import
java.util.Map
;
...
@@ -57,8 +59,17 @@ public class SupervisorTaskInfoService {
...
@@ -57,8 +59,17 @@ public class SupervisorTaskInfoService {
@Autowired
@Autowired
private
SupervisorAudioReviewInfoService
supervisorAudioReviewInfoService
;
private
SupervisorAudioReviewInfoService
supervisorAudioReviewInfoService
;
@Autowired
private
SupervisorTaskCourseService
supervisorTaskCourseService
;
@Autowired
private
SupervisorTaskImageMapper
supervisorTaskImageMapper
;
@Autowired
private
SupervisorTaskCourseMapper
supervisorTaskCourseMapper
;
@Autowired
private
SupervisorLearningCenterService
supervisorLearningCenterService
;
/**
/**
* 生成日报信息
* 生成日报信息
...
@@ -214,7 +225,10 @@ public class SupervisorTaskInfoService {
...
@@ -214,7 +225,10 @@ public class SupervisorTaskInfoService {
List
<
SupervisorWeekTaskStaff
>
weekTaskStaffList
=
supervisorWeekTaskStaffService
.
selectByRelationId
(
id
);
List
<
SupervisorWeekTaskStaff
>
weekTaskStaffList
=
supervisorWeekTaskStaffService
.
selectByRelationId
(
id
);
taskInfo
.
setWeekTaskStaffList
(
weekTaskStaffList
);
taskInfo
.
setWeekTaskStaffList
(
weekTaskStaffList
);
}
}
//TODO: 处理带教类型
if
(
TaskTypeEnum
.
TRAINING
.
getCode
().
equals
(
taskInfo
.
getTaskType
()))
{
List
<
SupervisorTaskCourse
>
taskCourseList
=
supervisorTaskCourseService
.
selectByTaskId
(
id
);
taskInfo
.
setTaskCourseList
(
taskCourseList
);
}
return
taskInfo
;
return
taskInfo
;
}
}
...
@@ -254,7 +268,107 @@ public class SupervisorTaskInfoService {
...
@@ -254,7 +268,107 @@ public class SupervisorTaskInfoService {
return
page
;
return
page
;
}
}
/**
* 更新任务完成状态
* @param relationId
* @param taskStatus
* @param updatedBy
* @return
*/
public
Boolean
updateTaskStatus
(
Long
relationId
,
Integer
taskStatus
,
String
updatedBy
)
{
RpcAssert
.
assertNotNull
(
relationId
,
DefaultErrorEnum
.
PARAMETER_NULL
,
"任务ID不能为空"
);
RpcAssert
.
assertNotNull
(
taskStatus
,
DefaultErrorEnum
.
PARAMETER_NULL
,
"任务状态不能为空"
);
RpcAssert
.
assertNotNull
(
updatedBy
,
DefaultErrorEnum
.
PARAMETER_NULL
,
"更新人不能为空"
);
//更新任务状态
SupervisorTaskInfo
supervisorTaskInfo
=
new
SupervisorTaskInfo
();
supervisorTaskInfo
.
setId
(
relationId
);
//设置属性
supervisorTaskInfo
.
setTaskStatus
(
taskStatus
);
supervisorTaskInfo
.
setUpdatedBy
(
updatedBy
);
supervisorTaskInfo
.
setUpdatedDate
(
new
Date
());
int
count
=
supervisorTaskInfoMapper
.
updateByPrimaryKeySelective
(
supervisorTaskInfo
);
if
(
count
<=
0
)
{
log
.
error
(
"更新任务状态失败,id={}, taskStatus={}"
,
relationId
,
taskStatus
);
throw
new
RpcServiceException
(
DefaultErrorEnum
.
DATABASE_ERROR
,
"更新任务状态失败"
);
}
return
true
;
}
/**
* 发起带教 - 提交
* @param request 带教信息
* @return 任务 ID
*/
@GlsxDistributeLockable
(
name
=
"'SupervisorTaskInfoService_submitCoaching_' + #request.supervisorPhone"
,
timeoutException
=
Exception
.
class
)
@Transactional
(
propagation
=
Propagation
.
REQUIRED
,
rollbackFor
=
Exception
.
class
)
public
Long
submitCoaching
(
SupervisorTaskDTO
request
)
{
try
{
Date
date
=
new
Date
();
// 构建带教任务信息
SupervisorTaskInfo
taskInfo
=
new
SupervisorTaskInfo
();
BeanUtils
.
copyProperties
(
request
,
taskInfo
);
taskInfo
.
setTaskType
(
TaskTypeEnum
.
TRAINING
.
getCode
());
// 5-带教
taskInfo
.
setTaskStatus
(
TaskStatusEnum
.
COMPLETED
.
getCode
());
// 直接设为已完成
taskInfo
.
setDeletedFlag
(
BaseModel
.
DeletedFlagEnum
.
N
.
name
());
taskInfo
.
setCreateTime
(
date
);
taskInfo
.
setCreatedBy
(
request
.
getSupervisorPhone
());
// 插入带教任务
int
count
=
supervisorTaskInfoMapper
.
insertSelective
(
taskInfo
);
if
(
count
<=
0
)
{
log
.
error
(
"插入带教任务失败"
);
throw
new
RpcServiceException
(
DefaultErrorEnum
.
DATABASE_ERROR
,
"插入带教任务失败"
);
}
Long
taskId
=
taskInfo
.
getId
();
log
.
info
(
"插入带教任务成功,taskId={}"
,
taskId
);
// 插入图片列表
if
(
CollectionUtils
.
isNotEmpty
(
request
.
getTaskImageList
()))
{
for
(
SupervisorTaskImage
image
:
request
.
getTaskImageList
())
{
image
.
setRelationId
(
taskId
);
image
.
setCreateTime
(
date
);
image
.
setCreatedBy
(
request
.
getSupervisorName
());
image
.
setDeletedFlag
(
BaseModel
.
DeletedFlagEnum
.
N
.
name
());
}
int
imageCount
=
supervisorTaskImageMapper
.
insertList
(
request
.
getTaskImageList
());
log
.
info
(
"插入带教图片成功,imageCount={}"
,
imageCount
);
}
// 插入课程列表
if
(
CollectionUtils
.
isNotEmpty
(
request
.
getTaskCourseList
()))
{
ArrayList
<
CoursePushDTO
>
coursePushList
=
new
ArrayList
<>();
for
(
SupervisorTaskCourse
course
:
request
.
getTaskCourseList
())
{
course
.
setTaskId
(
taskId
);
course
.
setCreatedTime
(
date
);
course
.
setCreatedBy
(
request
.
getSupervisorName
());
course
.
setDeletedFlag
(
BaseModel
.
DeletedFlagEnum
.
N
.
name
());
CoursePushDTO
coursePushDTO
=
new
CoursePushDTO
();
coursePushDTO
.
setStoreManagerPhone
(
request
.
getStoreManagerPhone
());
coursePushDTO
.
setStoreManagerName
(
request
.
getStoreManagerName
());
coursePushDTO
.
setBcCourseId
(
course
.
getBcCourseId
());
coursePushDTO
.
setBcCourseName
(
course
.
getBcCourseName
());
coursePushList
.
add
(
coursePushDTO
);
}
int
courseCount
=
supervisorTaskCourseMapper
.
insertList
(
request
.
getTaskCourseList
());
// 推送课程给驻店人员
supervisorLearningCenterService
.
batchPushCourseToStoreManager
(
coursePushList
);
log
.
info
(
"插入带教课程成功,courseCount={}"
,
courseCount
);
}
log
.
info
(
"发起带教 - 提交成功,taskId={}"
,
taskId
);
return
taskId
;
}
catch
(
RpcServiceException
e
)
{
throw
e
;
}
catch
(
Exception
e
)
{
log
.
error
(
"发起带教 - 提交异常"
,
e
);
throw
new
RpcServiceException
(
DefaultErrorEnum
.
SERVICE_ERROR
,
"发起带教失败:"
+
e
.
getMessage
());
}
}
}
}
rpc-dj-supervisor/src/main/resources/META-INF/orm/PersonCourseRecommendationMapper.xml
View file @
99d0708
...
@@ -8,6 +8,7 @@
...
@@ -8,6 +8,7 @@
<id
column=
"id"
property=
"id"
jdbcType=
"BIGINT"
/>
<id
column=
"id"
property=
"id"
jdbcType=
"BIGINT"
/>
<result
column=
"person_phone"
property=
"personPhone"
jdbcType=
"VARCHAR"
/>
<result
column=
"person_phone"
property=
"personPhone"
jdbcType=
"VARCHAR"
/>
<result
column=
"person_name"
property=
"personName"
jdbcType=
"VARCHAR"
/>
<result
column=
"person_name"
property=
"personName"
jdbcType=
"VARCHAR"
/>
<result
column=
"beisen_userid"
property=
"beisenUserId"
jdbcType=
"INTEGER"
/>
<result
column=
"bc_course_id"
property=
"bcCourseId"
jdbcType=
"VARCHAR"
/>
<result
column=
"bc_course_id"
property=
"bcCourseId"
jdbcType=
"VARCHAR"
/>
<result
column=
"bc_course_name"
property=
"bcCourseName"
jdbcType=
"VARCHAR"
/>
<result
column=
"bc_course_name"
property=
"bcCourseName"
jdbcType=
"VARCHAR"
/>
<result
column=
"push_source"
property=
"pushSource"
jdbcType=
"INTEGER"
/>
<result
column=
"push_source"
property=
"pushSource"
jdbcType=
"INTEGER"
/>
...
@@ -17,11 +18,81 @@
...
@@ -17,11 +18,81 @@
<result
column=
"updated_time"
property=
"updatedTime"
jdbcType=
"TIMESTAMP"
/>
<result
column=
"updated_time"
property=
"updatedTime"
jdbcType=
"TIMESTAMP"
/>
<result
column=
"deleted_flag"
property=
"deletedFlag"
jdbcType=
"CHAR"
/>
<result
column=
"deleted_flag"
property=
"deletedFlag"
jdbcType=
"CHAR"
/>
</resultMap>
</resultMap>
<resultMap
id=
"CoursePageMap"
type=
"cn.com.glsx.dj.supervisor.dto.CoursePageInfo"
>
<result
column=
"id"
property=
"courseId"
jdbcType=
"VARCHAR"
/>
<result
column=
"title"
property=
"title"
jdbcType=
"VARCHAR"
/>
<result
column=
"course_file_type"
property=
"courseFileType"
jdbcType=
"VARCHAR"
/>
<result
column=
"total_duration"
property=
"totalDuration"
/>
<result
column=
"course_status"
property=
"courseStatus"
jdbcType=
"VARCHAR"
/>
<result
column=
"categoryName"
property=
"categoryName"
jdbcType=
"VARCHAR"
/>
<result
column=
"categoryId"
property=
"categoryId"
/>
<result
column=
"parentId"
property=
"parentId"
/>
<result
column=
"organizationName"
property=
"organizationName"
jdbcType=
"VARCHAR"
/>
<result
column=
"learn_total"
property=
"learnTotal"
/>
<result
column=
"total_star"
property=
"totalStar"
/>
<result
column=
"beisen_created_time"
property=
"createdTime"
/>
</resultMap>
<sql
id=
"Base_Column_List"
>
<sql
id=
"Base_Column_List"
>
<!--
<!--
WARNING - @mbg.generated
WARNING - @mbg.generated
-->
-->
id, person_phone, person_name, b
c_course_id, bc_course_name, push_source, created_by,
id, person_phone, person_name, b
eisen_userid, bc_course_id, bc_course_name, push_source, created_by,
created_time, updated_by, updated_time, deleted_flag
created_time, updated_by, updated_time, deleted_flag
</sql>
</sql>
<select
id=
"allCourse"
resultType=
"cn.com.glsx.dj.supervisor.dto.CoursePageInfo"
resultMap=
"CoursePageMap"
>
select bc.id as courseId, bc.title, bc.course_file_type, bc.total_duration, bc.course_status,
bc.learn_total, round(bc.total_star,1) as total_star, bc.beisen_created_time
from dj_beisen_course bc
left join dj_car_life_learning_center_course_category_rel ccr on bc.id = ccr.course_id and ccr.deleted_flag = 'N'
<where>
bc.deleted_flag = 'N' and ccr.id is not null and ccr.category_id
<![CDATA[<>]]>
1
<if
test=
"courseCategoryId != null"
>
and (ccr.category_id = #{courseCategoryId} or ccr.parent_id = #{courseCategoryId})
</if>
<if
test=
"title != null and title != ''"
>
and bc.title like concat('%', #{title}, '%')
</if>
<if
test=
"courseFileType != null and courseFileType != ''"
>
and bc.course_file_type = #{courseFileType}
</if>
<if
test=
"courseStatus != null and courseStatus != ''"
>
and bc.course_status = #{courseStatus}
</if>
<if
test=
"totalStar != null"
>
and bc.total_star
>
= #{totalStar}
</if>
</where>
<if
test=
"sortType != null"
>
<choose>
<when
test=
"sortType == 0"
>
order by bc.learn_total ${sortOrder}, bc.title asc
</when>
<when
test=
"sortType == 1"
>
order by bc.total_star ${sortOrder}, bc.title asc
</when>
<otherwise>
order by bc.beisen_created_time ${sortOrder}, bc.title asc
</otherwise>
</choose>
</if>
</select>
<select
id=
"getPersonCourseRecommendPage"
resultType=
"cn.com.glsx.dj.supervisor.dto.MyselfCourseRecommendDTO"
>
SELECT
ROUND(t2.process * 100, 0) AS process,
t2.process AS process,
t2.course_id AS courseId,
t1.title AS title,
t1.total_duration AS totalDuration,
t1.total_star AS totalStar,
t1.learn_total AS learnTotal,
t1.course_file_type AS courseFileType
FROM person_course_recommendation t
INNER JOIN dj_beisen_course t1 ON t.bc_course_id = t1.id AND t1.course_status = '40' AND t1.deleted_flag = 'N'
LEFT JOIN dj_beisen_course_staff t2 ON t.bc_course_id = t2.course_id AND t.beisen_userid = t2.user_id AND t2.deleted_flag = 'N'
WHERE t.person_phone = #{phone}
AND t.deleted_flag = 'N'
ORDER BY t.created_time DESC
</select>
</mapper>
</mapper>
rpc-dj-supervisor/src/main/resources/META-INF/orm/SupervisorAiAnalysisRecordMapper.xml
View file @
99d0708
...
@@ -43,4 +43,28 @@
...
@@ -43,4 +43,28 @@
-->
-->
ai_request_params, ai_generate_result
ai_request_params, ai_generate_result
</sql>
</sql>
<select
id=
"selectByCondition"
resultMap=
"BaseResultMap"
>
select * from supervisor_ai_analysis_record
<where>
deleted_flag = 'N'
<if
test=
"type != null"
>
AND type = #{type,jdbcType=INTEGER}
</if>
<if
test=
"supervisorPhone != null"
>
AND supervisor_phone = #{supervisorPhone,jdbcType=VARCHAR}
</if>
<if
test=
"timeDimension != null"
>
AND time_dimension = #{timeDimension,jdbcType=INTEGER}
</if>
<if
test=
"storeManagerPhone != null"
>
AND store_manager_phone = #{storeManagerPhone,jdbcType=VARCHAR}
</if>
<if
test=
"startDate != null"
>
AND start_date = #{startDate,jdbcType=DATE}
</if>
<if
test=
"endDate != null"
>
AND end_date = #{endDate,jdbcType=DATE}
</if>
</where>
</select>
</mapper>
</mapper>
rpc-dj-supervisor/src/main/resources/META-INF/orm/SupervisorAudioReviewInfoMapper.xml
View file @
99d0708
...
@@ -24,4 +24,24 @@
...
@@ -24,4 +24,24 @@
id, reception_id, relation_id, review_status, review_context, review_target, created_by,
id, reception_id, relation_id, review_status, review_context, review_target, created_by,
create_time, updated_by, updated_date, deleted_flag
create_time, updated_by, updated_date, deleted_flag
</sql>
</sql>
<select
id=
"listAudionByReceptionId"
resultType=
"cn.com.glsx.dj.supervisor.dto.AudioReceptionDTO"
>
select sari.id, sari.receptionId as batchId, sari.reviewStatus,
t2.audio_time as staticDate,t1.employee_name employeeName,re.customer_name customerName,re.phone_number as phoneNumber,
re.merchant_id merchantNo,re.car_model carModel, re.car_brand as carBrand,
ind.customer_type as customerType,ind.avg_defence as avgDefence,
cb.start_time startTime,cb.end_time endTime,cb.duration as totalDuration, cb.score as qualityCheckScore,cb.file_url fileUrl
from supervisor_audio_review_info sari
left join inspection_conversation_batch cb on cb.id = sari.reception_id
left join reception_customer_info re on cb.task_id = re.id
left join inspection_defence ind on ind.batch_id = cb.id and ind.deleted_flag = 'N'
left join inspection_conversation_date t2 on cb.conversation_id = t2.id
left join inspection_employee_badge t1 on t1.badge_id = t2.badge_id
<where>
sari.deleted_flag = 'N' and cb.deleted_flag = 'N'
and sari.relation_id = #{relationId}
</where>
order by cb.start_time desc
</select>
</mapper>
</mapper>
\ No newline at end of file
\ No newline at end of file
rpc-dj-supervisor/src/main/resources/META-INF/orm/SupervisorTaskInfoMapper.xml
View file @
99d0708
...
@@ -39,8 +39,10 @@
...
@@ -39,8 +39,10 @@
<result
column=
"on_duty_flag"
property=
"onDutyFlag"
/>
<result
column=
"on_duty_flag"
property=
"onDutyFlag"
/>
<result
column=
"merchant_id"
property=
"merchantId"
/>
<result
column=
"merchant_id"
property=
"merchantId"
/>
<result
column=
"merchant_name"
property=
"merchantName"
/>
<result
column=
"merchant_name"
property=
"merchantName"
/>
<result
column=
"task_desc"
property=
"taskDesc"
/>
<result
column=
"task_context"
property=
"taskContext"
/>
<result
column=
"task_context"
property=
"taskContext"
/>
<result
column=
"store_manager_name"
property=
"storeManagerName"
/>
<result
column=
"store_manager_name"
property=
"storeManagerName"
/>
<result
column=
"create_time"
property=
"createTime"
jdbcType=
"TIMESTAMP"
/>
<result
column=
"updated_date"
property=
"updatedDate"
jdbcType=
"TIMESTAMP"
/>
<result
column=
"updated_date"
property=
"updatedDate"
jdbcType=
"TIMESTAMP"
/>
<collection
property=
"taskImageList"
ofType=
"cn.com.glsx.dj.supervisor.model.SupervisorTaskImage"
>
<collection
property=
"taskImageList"
ofType=
"cn.com.glsx.dj.supervisor.model.SupervisorTaskImage"
>
<result
column=
"image_url"
property=
"imageUrl"
/>
<result
column=
"image_url"
property=
"imageUrl"
/>
...
@@ -63,10 +65,10 @@
...
@@ -63,10 +65,10 @@
</sql>
</sql>
<select
id=
"getTaskDetailById"
resultMap=
"TaskDetailMap"
>
<select
id=
"getTaskDetailById"
resultMap=
"TaskDetailMap"
>
select sti.id, sti.task_type, sti.task_status, sti.on_duty_flag, sti.merchant_id, sti.merchant_name,
sti.task_context
,sti.updated_date,
select sti.id, sti.task_type, sti.task_status, sti.on_duty_flag, sti.merchant_id, sti.merchant_name,
sti.task_desc,sti.task_context,sti.create_time
,sti.updated_date,
sti.image_url
sti
m
.image_url
from supervisor_task_info sti
from supervisor_task_info sti
left join supervisor_task_image sti
on sti.relation_id = sti.id and sti
.deleted_flag = 'N'
left join supervisor_task_image sti
m on stim.relation_id = sti.id and stim
.deleted_flag = 'N'
<where>
<where>
sti.deleted_flag = 'N' and sti.id = #{id}
sti.deleted_flag = 'N' and sti.id = #{id}
</where>
</where>
...
@@ -99,5 +101,53 @@
...
@@ -99,5 +101,53 @@
</where>
</where>
order by sti.task_status asc, sti.create_time desc
order by sti.task_status asc, sti.create_time desc
</select>
</select>
<select
id=
"queryStudyHours"
resultType=
"cn.com.glsx.dj.supervisor.dto.MapperQueryEmployeeTrainingInfoDTO"
>
SELECT
staff AS userId,
TRUNCATE(SUM(COALESCE(duration, 0)) / 3600.0, 1) AS studyHours
FROM dj_beisen_learn_staff_progress_daily
WHERE
staff IN
<foreach
collection=
"beiSenUserIdList"
open=
"("
item=
"i"
close=
")"
separator=
","
>
#{i}
</foreach>
AND cast(date as date)
>
= #{startDate, jdbcType=DATE}
AND cast(date as date)
<
= #{endDate, jdbcType=DATE}
AND deleted_flag = 'N'
GROUP BY staff
</select>
<select
id=
"queryCompletedCourses"
resultType=
"cn.com.glsx.dj.supervisor.dto.MapperQueryEmployeeTrainingInfoDTO"
>
SELECT
user_id AS userId,
COUNT(*) AS completedCourses
FROM dj_beisen_course_staff
WHERE
user_id IN
<foreach
collection=
"beiSenUserIdList"
open=
"("
item=
"i"
close=
")"
separator=
","
>
#{i}
</foreach>
AND learn_status = '50'
AND cast(learn_end_time as date)
>
= #{startDate, jdbcType=DATE}
AND cast(learn_end_time as date)
<
= #{endDate, jdbcType=DATE}
AND deleted_flag = 'N'
GROUP BY user_id
</select>
<select
id=
"queryCoachingTimes"
resultType=
"cn.com.glsx.dj.supervisor.dto.MapperQueryEmployeeTrainingInfoDTO"
>
SELECT
store_manager_phone AS phone,
COUNT(*) AS coachingTimes
FROM supervisor_task_info
WHERE
store_manager_phone IN
<foreach
collection=
"phoneList"
open=
"("
item=
"i"
close=
")"
separator=
","
>
#{i}
</foreach>
AND task_type = 5
AND task_status = 2
AND cast(create_time as date)
>
= #{startDate, jdbcType=DATE}
AND cast(create_time as date)
<
= #{endDate, jdbcType=DATE}
AND deleted_flag = 'N'
GROUP BY store_manager_phone
</select>
</mapper>
</mapper>
\ No newline at end of file
\ No newline at end of file
rpc-dj-supervisor/src/test/java/cn/com/glsx/dj/supervisor/service/PersonCourseRecommendationServiceTest.java
0 → 100644
View file @
99d0708
package
cn
.
com
.
glsx
.
dj
.
supervisor
.
service
;
import
cn.com.glsx.dj.supervisor.dto.MyselfCourseRecommendDTO
;
import
cn.com.glsx.framework.core.beans.rpc.RpcPagination
;
import
com.alibaba.fastjson.JSON
;
import
com.github.pagehelper.Page
;
import
org.junit.Test
;
import
org.springframework.beans.factory.annotation.Autowired
;
/**
* @Title:
* @Description:
* @Author xiehx
* @Date 2026/3/11
**/
public
class
PersonCourseRecommendationServiceTest
extends
BaseServiceTest
{
@Autowired
private
PersonCourseRecommendationService
personCourseRecommendationService
;
@Test
public
void
testGetPersonCourseRecommendPage
()
{
RpcPagination
<
MyselfCourseRecommendDTO
>
pagination
=
new
RpcPagination
<>();
pagination
.
setPageNum
(
1
);
pagination
.
setPageSize
(
10
);
MyselfCourseRecommendDTO
condition
=
new
MyselfCourseRecommendDTO
();
condition
.
setPhone
(
"13603070903"
);
pagination
.
setCondition
(
condition
);
Page
<
MyselfCourseRecommendDTO
>
page
=
personCourseRecommendationService
.
getPersonCourseRecommendPage
(
pagination
);
System
.
out
.
println
(
JSON
.
toJSONString
(
page
));
}
}
\ No newline at end of file
\ No newline at end of file
rpc-dj-supervisor/src/test/java/cn/com/glsx/dj/supervisor/service/SupervisorAiAnalysisRecordServiceTest.java
0 → 100644
View file @
99d0708
package
cn
.
com
.
glsx
.
dj
.
supervisor
.
service
;
import
cn.com.glsx.dj.supervisor.model.SupervisorAiAnalysisRecord
;
import
com.alibaba.fastjson.JSON
;
import
org.junit.Test
;
import
org.springframework.beans.factory.annotation.Autowired
;
import
java.util.Date
;
/**
* @Title:
* @Description:
* @Author xiehx
* @Date 2026/3/11
**/
public
class
SupervisorAiAnalysisRecordServiceTest
extends
BaseServiceTest
{
@Autowired
private
SupervisorAiAnalysisRecordService
supervisorAiAnalysisRecordService
;
@Test
public
void
testGetAiAnalysisRecord
()
{
SupervisorAiAnalysisRecord
record
=
new
SupervisorAiAnalysisRecord
();
record
.
setType
(
3
);
record
.
setSupervisorPhone
(
"13603070903"
);
record
.
setTimeDimension
(
1
);
record
.
setStartDate
(
new
Date
());
record
.
setEndDate
(
new
Date
());
SupervisorAiAnalysisRecord
aiAnalysisRecord
=
supervisorAiAnalysisRecordService
.
getAiAnalysisRecord
(
record
);
System
.
out
.
println
(
JSON
.
toJSONString
(
aiAnalysisRecord
));
}
}
\ No newline at end of file
\ No newline at end of file
rpc-dj-supervisor/src/test/java/cn/com/glsx/dj/supervisor/service/SupervisorEmployeeTrainingInfoServiceTest.java
0 → 100644
View file @
99d0708
package
cn
.
com
.
glsx
.
dj
.
supervisor
.
service
;
import
cn.com.glsx.dj.supervisor.dto.EmployeeTrainingInfoDTO
;
import
cn.com.glsx.dj.supervisor.dto.EmployeeTrainingInfoRequestDTO
;
import
com.alibaba.fastjson.JSON
;
import
org.junit.Test
;
import
org.springframework.beans.factory.annotation.Autowired
;
import
java.util.List
;
/**
* @Title:
* @Description:
* @Author xiehx
* @Date 2026/3/12
**/
public
class
SupervisorEmployeeTrainingInfoServiceTest
extends
BaseServiceTest
{
@Autowired
private
SupervisorEmployeeTrainingInfoService
supervisorEmployeeTrainingInfoService
;
@Test
public
void
testGetAllEmployeeTrainingInfo
()
{
EmployeeTrainingInfoRequestDTO
request
=
new
EmployeeTrainingInfoRequestDTO
();
request
.
setStartDate
(
"2021-03-12"
);
request
.
setEndDate
(
"2026-03-12"
);
request
.
setSortField
(
1
);
request
.
setSortOrder
(
1
);
List
<
EmployeeTrainingInfoDTO
>
trainingInfo
=
supervisorEmployeeTrainingInfoService
.
getAllEmployeeTrainingInfo
(
request
);
System
.
out
.
println
(
JSON
.
toJSONString
(
trainingInfo
));
}
}
\ No newline at end of file
\ No newline at end of file
rpc-dj-supervisor/src/test/java/cn/com/glsx/dj/supervisor/service/SupervisorLearningCenterServiceTest.java
0 → 100644
View file @
99d0708
package
cn
.
com
.
glsx
.
dj
.
supervisor
.
service
;
import
cn.com.glsx.dj.supervisor.dto.CoursePageInfo
;
import
cn.com.glsx.dj.supervisor.dto.CoursePushDTO
;
import
cn.com.glsx.dj.supervisor.dto.CourseSearchDTO
;
import
cn.com.glsx.framework.core.beans.rpc.RpcPagination
;
import
com.alibaba.fastjson.JSON
;
import
com.github.pagehelper.Page
;
import
org.junit.Test
;
import
org.springframework.beans.factory.annotation.Autowired
;
import
java.util.ArrayList
;
/**
* @Title:
* @Description:
* @Author xiehx
* @Date 2026/3/10
**/
public
class
SupervisorLearningCenterServiceTest
extends
BaseServiceTest
{
@Autowired
private
SupervisorLearningCenterService
supervisorLearningCenterService
;
@Test
public
void
testAllCourse
()
{
RpcPagination
<
CourseSearchDTO
>
pagination
=
new
RpcPagination
<>();
pagination
.
setCondition
(
new
CourseSearchDTO
());
pagination
.
setPageNum
(
1
);
pagination
.
setPageSize
(
10
);
Page
<
CoursePageInfo
>
pageInfos
=
supervisorLearningCenterService
.
allCourse
(
pagination
);
System
.
out
.
println
(
JSON
.
toJSONString
(
pageInfos
));
}
@Test
public
void
testBatchPushCourseToStoreManager
()
{
ArrayList
<
CoursePushDTO
>
coursePushDTOs
=
new
ArrayList
<>();
CoursePushDTO
coursePushDTO
=
new
CoursePushDTO
();
coursePushDTO
.
setStoreManagerPhone
(
"13603070903"
);
coursePushDTO
.
setStoreManagerName
(
"谢海旭"
);
coursePushDTO
.
setBcCourseId
(
"4d86438b-917a-4bc9-86e2-d2beb6ff26d2"
);
coursePushDTO
.
setBcCourseName
(
"冒烟"
);
coursePushDTOs
.
add
(
coursePushDTO
);
Boolean
b
=
supervisorLearningCenterService
.
batchPushCourseToStoreManager
(
coursePushDTOs
);
System
.
out
.
println
(
b
);
}
}
\ No newline at end of file
\ No newline at end of file
rpc-dj-supervisor/src/test/java/cn/com/glsx/dj/supervisor/service/SupervisorTaskInfoServiceTest.java
0 → 100644
View file @
99d0708
package
cn
.
com
.
glsx
.
dj
.
supervisor
.
service
;
import
cn.com.glsx.dj.supervisor.dto.SupervisorTaskDTO
;
import
cn.com.glsx.dj.supervisor.model.SupervisorTaskCourse
;
import
cn.com.glsx.dj.supervisor.model.SupervisorTaskImage
;
import
com.alibaba.fastjson.JSON
;
import
org.junit.Test
;
import
org.springframework.beans.factory.annotation.Autowired
;
import
java.util.ArrayList
;
/**
* @Title:
* @Description:
* @Author xiehx
* @Date 2026/3/11
**/
public
class
SupervisorTaskInfoServiceTest
extends
BaseServiceTest
{
@Autowired
private
SupervisorTaskInfoService
supervisorTaskInfoService
;
@Test
public
void
testGetTaskDetailById
()
{
SupervisorTaskDTO
detail
=
supervisorTaskInfoService
.
getTaskDetailById
(
1L
);
System
.
out
.
println
(
JSON
.
toJSONString
(
detail
));
}
@Test
public
void
testSubmitCoaching
()
{
SupervisorTaskDTO
request
=
new
SupervisorTaskDTO
();
request
.
setSupervisorPhone
(
"13603070903"
);
request
.
setSupervisorName
(
"张三"
);
request
.
setStoreManagerName
(
"赵惠惠"
);
request
.
setStoreManagerPhone
(
"18902640418"
);
// 设置其他全部参数
request
.
setMerchantId
(
43423334
);
request
.
setMerchantName
(
"萨达梵蒂冈"
);
request
.
setTaskContext
(
"督导记录sdhnasuihfasifnasfnassjasidjkioasdasfn"
);
ArrayList
<
SupervisorTaskCourse
>
taskCourseList
=
new
ArrayList
<>();
SupervisorTaskCourse
course
=
new
SupervisorTaskCourse
();
course
.
setBcCourseId
(
"7454d3dc-1df1-485a-8d14-196ac03703ab"
);
course
.
setBcCourseName
(
"智界R7谈客案例-攻防能力篇"
);
taskCourseList
.
add
(
course
);
request
.
setTaskCourseList
(
taskCourseList
);
ArrayList
<
SupervisorTaskImage
>
taskImageList
=
new
ArrayList
<>();
SupervisorTaskImage
image
=
new
SupervisorTaskImage
();
image
.
setImageUrl
(
"http://oss.glsx.com/123456.jpg"
);
taskImageList
.
add
(
image
);
request
.
setTaskImageList
(
taskImageList
);
Long
id
=
supervisorTaskInfoService
.
submitCoaching
(
request
);
System
.
out
.
println
(
id
);
}
}
\ No newline at end of file
\ No newline at end of file
Write
Preview
Markdown
is supported
Attach a file
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to post a comment