Improved dashboard
This commit is contained in:
parent
e7d914f223
commit
8c631f4e26
@ -36,10 +36,7 @@ func dashboard(ctx *aero.Context) string {
|
||||
flow.Parallel(func() {
|
||||
posts, err = arn.AllPostsSlice()
|
||||
arn.SortPostsLatestFirst(posts)
|
||||
|
||||
if len(posts) > maxPosts {
|
||||
posts = posts[:maxPosts]
|
||||
}
|
||||
posts = arn.FilterPostsWithUniqueThreads(posts, maxPosts)
|
||||
}, func() {
|
||||
followIDList = user.Following
|
||||
userList, err = arn.DB.GetMany("User", followIDList)
|
||||
|
@ -15,7 +15,7 @@ component Dashboard(posts []*arn.Post, following []*arn.User)
|
||||
h3.widget-title Forums
|
||||
|
||||
each post in posts
|
||||
a.widget-element.ajax(href=post.Link())
|
||||
a.widget-element.ajax(href=post.Thread().Link())
|
||||
.widget-element-text
|
||||
Icon(arn.GetForumIcon(post.Thread().Tags[0]))
|
||||
span= post.Thread().Title
|
||||
|
Loading…
Reference in New Issue
Block a user