xingzai 2 жил өмнө
parent
commit
3076b59caa

+ 0 - 5
controllers/article.go

@@ -578,11 +578,6 @@ func (this *ArticleController) ArticleHotList() {
 		br.ErrMsg = "获取品种信息失败,Err:" + err.Error()
 		return
 	}
-	for k, v := range list {
-		if v.MyCollectNum > 0 {
-			list[k].IsCollect = true
-		}
-	}
 	resp := new(models.ArticleCollectionLIstResp)
 	if len(list) == 0 {
 		list = make([]*models.ArticleCollectionResp, 0)

+ 4 - 3
models/article.go

@@ -106,9 +106,10 @@ type ArticleCollectionResp struct {
 	DepartmentId           int    `description:"作者Id"`
 	NickName               string `description:"作者昵称"`
 	IsCollect              bool   `description:"本人是否收藏"`
-	Pv                     int    `description:"PV"`
-	CollectNum             int    `description:"收藏人数"`
-	Source                 int    `description:"来源 1:弘则资源包(报告)、2:研选主题(报告)"`
+
+	Pv         int `description:"PV"`
+	CollectNum int `description:"收藏人数"`
+	Source     int `description:"来源 1:弘则资源包(报告)、2:研选主题(报告)"`
 }
 
 //列表