fix(我的培训):「我的培训」的“与我相关”判定(学习任务/讲师/部门范围)不含「参加人员」——线下课不生成学习任务,参加人员只落场次名单与文案,刘义亮(资讯组)被课程部门范围(人事课)拦在页签外。
deploy-hxtesting / build-and-deploy (push) Successful in 20m39s

This commit is contained in:
runny committed 2026-11-24 21:22:27 +08:00
1 parent 448fbcdaff
commit 11450bdb96
8 files changed
+167 -2

No files matched your search

@@ -367,6 +367,18 @@ func (h *Handler) ListMyLearningTasks(c *gin.Context) {
c.JSON(http.StatusOK, gin.H{"success": true, "data": items})
}
// ListMyEnrolledCourseIds GET /training/my/enrolled-course-ids — 我经场次学员
// 名单报名的课程 id 去重集合(我的培训「我参加」判定数据源,前端与学习任务/
// 讲师/部门范围口径互补;登录即可查,自身名单本身即个人数据)。
func (h *Handler) ListMyEnrolledCourseIds(c *gin.Context) {
ids, err := h.svc.ListMyEnrolledCourseIDs(c.Request.Context(), callerTenantID(c), callerUserID(c))
if err != nil {
_ = c.Error(err)
return
}
c.JSON(http.StatusOK, gin.H{"success": true, "data": ids})
}
// ListCourseLearningTasks GET /training/learning-tasks/all?course_id= —
// 按课程返回全员学习任务(人事/课长/讲师的「学习考试」课程学习情况视图)。
func (h *Handler) ListCourseLearningTasks(c *gin.Context) {