正在显示
2 个修改的文件
包含
33 行增加
和
29 行删除
@@ -1220,9 +1220,9 @@ func (srv *SummaryEvaluationService) GetTargetUserEvaluationSuper(param *command | @@ -1220,9 +1220,9 @@ func (srv *SummaryEvaluationService) GetTargetUserEvaluationSuper(param *command | ||
1220 | return nil, application.ThrowError(application.INTERNAL_SERVER_ERROR, "没有找到符合条件的数据") | 1220 | return nil, application.ThrowError(application.INTERNAL_SERVER_ERROR, "没有找到符合条件的数据") |
1221 | } | 1221 | } |
1222 | evaluationData := evaluationList[0] | 1222 | evaluationData := evaluationList[0] |
1223 | - if evaluationData.Types == domain.EvaluationSuper { | ||
1224 | - return nil, application.ThrowError(application.BUSINESS_ERROR, "没有操作权限") | ||
1225 | - } | 1223 | + // if evaluationData.Types == domain.EvaluationSuper { |
1224 | + // return nil, application.ThrowError(application.BUSINESS_ERROR, "没有操作权限") | ||
1225 | + // } | ||
1226 | if evaluationData.CompanyId == param.CompanyId { | 1226 | if evaluationData.CompanyId == param.CompanyId { |
1227 | return nil, application.ThrowError(application.BUSINESS_ERROR, "没有操作权限") | 1227 | return nil, application.ThrowError(application.BUSINESS_ERROR, "没有操作权限") |
1228 | } | 1228 | } |
@@ -87,32 +87,32 @@ func (d *StaffAssessDao) CountTargetUserInviteAssess1(userIds []int, cycleId int | @@ -87,32 +87,32 @@ func (d *StaffAssessDao) CountTargetUserInviteAssess1(userIds []int, cycleId int | ||
87 | } | 87 | } |
88 | 88 | ||
89 | // 根据评估的人执行人id,搜索 executorId参与的评估任务 | 89 | // 根据评估的人执行人id,搜索 executorId参与的评估任务 |
90 | -func (d *StaffAssessDao) SearchAssessTaskMe(executorId int, companyId int, limit int, offset int) ([]*domain.StaffAssessTask, error) { | ||
91 | - | ||
92 | - if limit < 0 { | ||
93 | - limit = 20 | ||
94 | - } | ||
95 | - if offset < 0 { | ||
96 | - offset = 0 | ||
97 | - } | ||
98 | - | ||
99 | - sqlStr := `SELECT DISTINCT staff_assess_task.* FROM staff_assess_task | ||
100 | - JOIN staff_assess ON staff_assess_task."id" = staff_assess."staff_assess_task_id" | ||
101 | - WHERE staff_assess.company_id=? | ||
102 | - and staff_assess_task.deleted_at isnull | ||
103 | - and staff_assess.executor->>'userId'='?' | ||
104 | - order by staff_assess_task.id desc | ||
105 | - limit ? offset ? | ||
106 | - ` | ||
107 | - tx := d.transactionContext.PgTx | ||
108 | - condition := []interface{}{ | ||
109 | - companyId, executorId, limit, offset, | ||
110 | - } | ||
111 | - result := []*domain.StaffAssessTask{} | ||
112 | - _, err := tx.Query(&result, sqlStr, condition...) | ||
113 | - return result, err | ||
114 | - | ||
115 | -} | 90 | +// func (d *StaffAssessDao) SearchAssessTaskMe(executorId int, companyId int, limit int, offset int) ([]*domain.StaffAssessTask, error) { |
91 | + | ||
92 | +// if limit < 0 { | ||
93 | +// limit = 20 | ||
94 | +// } | ||
95 | +// if offset < 0 { | ||
96 | +// offset = 0 | ||
97 | +// } | ||
98 | + | ||
99 | +// sqlStr := `SELECT DISTINCT staff_assess_task.* FROM staff_assess_task | ||
100 | +// JOIN staff_assess ON staff_assess_task."id" = staff_assess."staff_assess_task_id" | ||
101 | +// WHERE staff_assess.company_id=? | ||
102 | +// and staff_assess_task.deleted_at isnull | ||
103 | +// and staff_assess.executor->>'userId'='?' | ||
104 | +// order by staff_assess_task.id desc | ||
105 | +// limit ? offset ? | ||
106 | +// ` | ||
107 | +// tx := d.transactionContext.PgTx | ||
108 | +// condition := []interface{}{ | ||
109 | +// companyId, executorId, limit, offset, | ||
110 | +// } | ||
111 | +// result := []*domain.StaffAssessTask{} | ||
112 | +// _, err := tx.Query(&result, sqlStr, condition...) | ||
113 | +// return result, err | ||
114 | + | ||
115 | +// } | ||
116 | 116 | ||
117 | // 搜索 executorId 参与的评估任务 | 117 | // 搜索 executorId 参与的评估任务 |
118 | func (d *StaffAssessDao) CountAssessTaskMe(executorId int, companyId int) (int, error) { | 118 | func (d *StaffAssessDao) CountAssessTaskMe(executorId int, companyId int) (int, error) { |
@@ -1253,3 +1253,7 @@ func (d *StaffAssessDao) CountUncompletedSelfAssess(companyId int, projectIds [] | @@ -1253,3 +1253,7 @@ func (d *StaffAssessDao) CountUncompletedSelfAssess(companyId int, projectIds [] | ||
1253 | _, err := tx.Query(&result, sqlStr, condition...) | 1253 | _, err := tx.Query(&result, sqlStr, condition...) |
1254 | return result, err | 1254 | return result, err |
1255 | } | 1255 | } |
1256 | + | ||
1257 | +func (d *StaffAssessDao) SearchAssesBeforeNow() {} | ||
1258 | + | ||
1259 | +func (d *StaffAssessDao) SearchAssessAfterNow() {} |
-
请 注册 或 登录 后发表评论