浏览代码

no message

xingzai 3 年之前
父节点
当前提交
143a435af0
共有 2 个文件被更改,包括 2 次插入2 次删除
  1. 1 1
      controllers/article.go
  2. 1 1
      models/user.go

+ 1 - 1
controllers/article.go

@@ -467,7 +467,7 @@ func (this *ArticleController) AddStopTime() {
 	}
 
 	if stopTime == 0 {
-		br.Msg = "时间错误"
+		br.ErrMsg = "时间错误"
 		return
 	}
 	detail := new(models.ArticleDetail)

+ 1 - 1
models/user.go

@@ -176,7 +176,7 @@ func GetArticleUserBrowseHistoryCount(userId int, endDate string) (count int, er
 
 func GetArticleUserBrowseHistoryList(startSize, pageSize, userId int, endDate string) (items []*ArticleInterviewApplyList, err error) {
 	sql := `SELECT a.* FROM cygx_article_history_record AS a
-			WHERE a.user_id=? AND a.create_time>=? 
+			WHERE a.user_id=? AND a.create_time>=?  GROUP BY a.article_id
            ORDER BY a.modify_time DESC LIMIT ?,? `
 	_, err = orm.NewOrm().Raw(sql, userId, endDate, startSize, pageSize).QueryRows(&items)
 	return