...
|
...
|
@@ -212,14 +212,14 @@ type SummaryEvaluationCycle struct { |
|
|
}
|
|
|
|
|
|
// 查询周期列表
|
|
|
// 条件:确认考核结果已过截止时间
|
|
|
func (d *SummaryEvaluationDao) ListCycle(companyId int) ([]SummaryEvaluationCycle, error) {
|
|
|
sqlStr := ` select
|
|
|
distinct summary_evaluation.cycle_id ,summary_evaluation.cycle_name ,summary_evaluation.company_id
|
|
|
from summary_evaluation
|
|
|
where summary_evaluation."types" =5 and summary_evaluation.end_time <now()
|
|
|
where summary_evaluation."types" =5
|
|
|
and summary_evaluation.company_id =?
|
|
|
order by summary_evaluation.cycle_id desc `
|
|
|
order by summary_evaluation.cycle_id desc
|
|
|
limit 1000 `
|
|
|
result := []SummaryEvaluationCycle{}
|
|
|
tx := d.transactionContext.PgTx
|
|
|
_, err := tx.Query(&result, sqlStr, companyId)
|
...
|
...
|
|