|
@@ -110,7 +110,7 @@ func GetCygxArticleHistoryRecordAllDetailLast(articleId, userId int) (item *Cygx
|
|
|
// 根据用户ID,文章ID获取用户最新一条阅读记录
|
|
|
func GetCygxArticleHistoryRecordAllDetailLastByMobile(articleId int, mobile string) (item *CygxArticleHistoryRecordAll, err error) {
|
|
|
o := orm.NewOrmUsingDB("hz_cygx")
|
|
|
- sql := `SELECT * FROM cygx_article_history_record_all WHERE article_id = ? AND mobile = ? AND is_del = 0 ORDER BY id DESC LIMIT 1 `
|
|
|
+ sql := `SELECT * FROM cygx_article_history_record_all WHERE article_id = ? AND mobile = ? AND is_del = 0 AND stop_time > 0 ORDER BY id DESC LIMIT 1 `
|
|
|
err = o.Raw(sql, articleId, mobile).QueryRow(&item)
|
|
|
return
|
|
|
}
|