Browse Source

no message

xingzai 1 year ago
parent
commit
f560ef4eac
1 changed files with 5 additions and 3 deletions
  1. 5 3
      models/report.go

+ 5 - 3
models/report.go

@@ -959,7 +959,8 @@ func GetArticleResearchListYx(condition string, pars []interface{}, startSize, p
 			0 AS special_type,
 			0 AS special_column_id,
 			'' AS company_tags, 
-			'' AS industry_tags
+			'' AS industry_tags,
+			a.top_time
 		FROM
 			cygx_article AS a
 			INNER JOIN cygx_article_department AS d ON d.department_id = a.department_id 
@@ -986,13 +987,14 @@ func GetArticleResearchListYx(condition string, pars []interface{}, startSize, p
 		a.type AS special_type,
 		b.id AS special_column_id,
 		a.company_tags AS company_tags, 
-		a.industry_tags AS industry_tags 
+		a.industry_tags AS industry_tags,
+		0 as top_time
 	FROM
 	cygx_yanxuan_special AS a
 	JOIN cygx_yanxuan_special_author AS b ON a.user_id = b.user_id
 	WHERE
 	1 = 1  AND a.status = 3 `
-	sql += `  GROUP BY  a.article_id ORDER  BY top_time DESC , a.publish_date DESC   LIMIT ?,? `
+	sql += ` 	GROUP BY  article_id ORDER  BY top_time DESC , publish_date DESC   LIMIT  ?,? `
 	_, err = o.Raw(sql, pars, startSize, pageSize).QueryRows(&items)
 	return
 }