正在显示
1 个修改的文件
包含
3 行增加
和
3 行删除
| @@ -212,14 +212,14 @@ type SummaryEvaluationCycle struct { | @@ -212,14 +212,14 @@ type SummaryEvaluationCycle struct { | ||
| 212 | } | 212 | } |
| 213 | 213 | ||
| 214 | // 查询周期列表 | 214 | // 查询周期列表 |
| 215 | -// 条件:确认考核结果已过截止时间 | ||
| 216 | func (d *SummaryEvaluationDao) ListCycle(companyId int) ([]SummaryEvaluationCycle, error) { | 215 | func (d *SummaryEvaluationDao) ListCycle(companyId int) ([]SummaryEvaluationCycle, error) { |
| 217 | sqlStr := ` select | 216 | sqlStr := ` select |
| 218 | distinct summary_evaluation.cycle_id ,summary_evaluation.cycle_name ,summary_evaluation.company_id | 217 | distinct summary_evaluation.cycle_id ,summary_evaluation.cycle_name ,summary_evaluation.company_id |
| 219 | from summary_evaluation | 218 | from summary_evaluation |
| 220 | - where summary_evaluation."types" =5 and summary_evaluation.end_time <now() | 219 | + where summary_evaluation."types" =5 |
| 221 | and summary_evaluation.company_id =? | 220 | and summary_evaluation.company_id =? |
| 222 | - order by summary_evaluation.cycle_id desc ` | 221 | + order by summary_evaluation.cycle_id desc |
| 222 | + limit 1000 ` | ||
| 223 | result := []SummaryEvaluationCycle{} | 223 | result := []SummaryEvaluationCycle{} |
| 224 | tx := d.transactionContext.PgTx | 224 | tx := d.transactionContext.PgTx |
| 225 | _, err := tx.Query(&result, sqlStr, companyId) | 225 | _, err := tx.Query(&result, sqlStr, companyId) |
-
请 注册 或 登录 后发表评论