|
@@ -486,7 +486,8 @@ func GetArticleIdsBySubId(subjectId string) (articleIds string, err error) {
|
|
|
type ArticleCollectionResp struct {
|
|
|
ArticleId int `description:"文章id"`
|
|
|
Title string `description:"标题"`
|
|
|
- PublishDate string `description:"发布时间"`
|
|
|
+ PublishDate string `description:"发布日期"`
|
|
|
+ PublishTime time.Time `description:"发布时间"`
|
|
|
IndustrialManagementId int `description:"产业Id"`
|
|
|
IndustryName string `description:"产业名称"`
|
|
|
DepartmentId int `description:"作者Id"`
|
|
@@ -628,7 +629,7 @@ func GetArticleResearchList(condition string, pars []interface{}, startSize, pag
|
|
|
sql := `SELECT
|
|
|
a.article_id,
|
|
|
a.title,
|
|
|
- date_format( a.publish_date, '%Y-%m-%d' ) AS publish_date,
|
|
|
+ a.publish_date AS publish_time,
|
|
|
a.article_type_id,
|
|
|
d.nick_name,
|
|
|
d.department_id,
|
|
@@ -658,7 +659,7 @@ func GetArticleResearchList(condition string, pars []interface{}, startSize, pag
|
|
|
SELECT
|
|
|
a.id AS article_id,
|
|
|
a.title AS title,
|
|
|
- date_format( a.publish_time, '%Y-%m-%d' ) AS publish_date,
|
|
|
+ a.publish_time AS publish_time,
|
|
|
-1 AS article_type_id,
|
|
|
b.nick_name AS nick_name,
|
|
|
a.user_id AS department_id,
|
|
@@ -676,10 +677,10 @@ func GetArticleResearchList(condition string, pars []interface{}, startSize, pag
|
|
|
JOIN cygx_yanxuan_special_author AS b ON a.user_id = b.user_id
|
|
|
WHERE
|
|
|
1 = 1 AND a.status = 3 `
|
|
|
- sql += ` ORDER BY publish_date DESC LIMIT ?,? `
|
|
|
+ sql += ` ORDER BY publish_time DESC LIMIT ?,? `
|
|
|
_, err = o.Raw(sql, userId, userId, pars, startSize, pageSize).QueryRows(&items)
|
|
|
} else {
|
|
|
- sql += ` ORDER BY publish_date DESC LIMIT ?,? `
|
|
|
+ sql += ` ORDER BY publish_time DESC LIMIT ?,? `
|
|
|
_, err = o.Raw(sql, userId, pars, startSize, pageSize).QueryRows(&items)
|
|
|
}
|
|
|
|