ソースを参照

Merge branch 'CRM_14.5'

zwxi 1 年間 前
コミット
fbe4d37e0f
1 ファイル変更2 行追加2 行削除
  1. 2 2
      models/company/company_user.go

+ 2 - 2
models/company/company_user.go

@@ -140,8 +140,8 @@ func GetCompanyUserListV2(condition string, pars []interface{}, companyId, start
 	if condition != "" {
 		sql += condition
 	}
-	//sql += ` group by a.user_id ORDER BY a.is_register desc,a.report_last_view_time desc,a.last_updated_time DESC LIMIT ?,? `
-	sql += ` group by a.user_id ORDER BY CASE WHEN is_follow = 1 AND (report_last_view_time < NOW()  - INTERVAL 7 DAY or report_last_view_time is NULL ) THEN 0 ELSE 1 END,a.is_register desc,a.report_last_view_time ASC,a.last_updated_time  ASC LIMIT ?,? `
+	sql += ` group by a.user_id ORDER BY CASE WHEN is_follow = 1 AND (report_last_view_time < NOW()  - INTERVAL 7 DAY or report_last_view_time is NULL ) THEN 0 ELSE 1 END,a.report_last_view_time desc,a.last_updated_time DESC LIMIT ?,? `
+	//sql += ` group by a.user_id ORDER BY CASE WHEN is_follow = 1 AND (report_last_view_time < NOW()  - INTERVAL 7 DAY or report_last_view_time is NULL ) THEN 0 ELSE 1 END,a.is_register desc,a.report_last_view_time ASC,a.last_updated_time  ASC LIMIT ?,? `
 	_, err = o.Raw(sql, companyId, pars, startSize, pageSize).QueryRows(&items)
 	return
 }