feat:优化项目信息
This commit is contained in:
@ -22,7 +22,8 @@ type (
|
||||
PaperInfo struct {
|
||||
ID string `json:"id"`
|
||||
*model2.TechnologyPaper
|
||||
Tags []string `json:"tags"`
|
||||
Keywords []string `json:"keywords"`
|
||||
Tags []string `json:"tags"`
|
||||
}
|
||||
PaperParams struct {
|
||||
ID uint64
|
||||
@ -53,7 +54,8 @@ func (c *Paper) List(title string, page, pageSize int) (*controller.ReturnPages,
|
||||
list := make([]*PaperInfo, 0)
|
||||
|
||||
for _, v := range out {
|
||||
list = append(list, &PaperInfo{ID: v.GetEncodeID(), TechnologyPaper: v, Tags: v.GetTagAttribute()})
|
||||
list = append(list, &PaperInfo{ID: v.GetEncodeID(), TechnologyPaper: v, Keywords: v.GetKeywordAttribute(),
|
||||
Tags: v.GetTagAttribute()})
|
||||
}
|
||||
return &controller.ReturnPages{Data: list, Count: count}, nil
|
||||
}
|
||||
|
Reference in New Issue
Block a user