mirror of
https://github.com/miniflux/v2.git
synced 2025-08-26 18:21:01 +00:00
Do not show save link if no integration is configured
This commit is contained in:
parent
b166ceaea7
commit
31da4db14f
20 changed files with 133 additions and 100 deletions
|
@ -56,6 +56,7 @@ func (c *Controller) ShowStarredPage(w http.ResponseWriter, r *http.Request) {
|
|||
view.Set("menu", "starred")
|
||||
view.Set("user", user)
|
||||
view.Set("countUnread", c.store.CountUnreadEntries(user.ID))
|
||||
view.Set("hasSaveEntry", c.store.HasSaveEntry(user.ID))
|
||||
|
||||
html.OK(w, view.Render("starred"))
|
||||
html.OK(w, view.Render("bookmark_entries"))
|
||||
}
|
||||
|
|
|
@ -73,6 +73,7 @@ func (c *Controller) CategoryEntries(w http.ResponseWriter, r *http.Request) {
|
|||
view.Set("menu", "categories")
|
||||
view.Set("user", user)
|
||||
view.Set("countUnread", c.store.CountUnreadEntries(user.ID))
|
||||
view.Set("hasSaveEntry", c.store.HasSaveEntry(user.ID))
|
||||
|
||||
html.OK(w, view.Render("category_entries"))
|
||||
}
|
||||
|
|
|
@ -86,6 +86,7 @@ func (c *Controller) ShowStarredEntry(w http.ResponseWriter, r *http.Request) {
|
|||
view.Set("menu", "starred")
|
||||
view.Set("user", user)
|
||||
view.Set("countUnread", c.store.CountUnreadEntries(user.ID))
|
||||
view.Set("hasSaveEntry", c.store.HasSaveEntry(user.ID))
|
||||
|
||||
html.OK(w, view.Render("entry"))
|
||||
}
|
|
@ -93,6 +93,7 @@ func (c *Controller) ShowCategoryEntry(w http.ResponseWriter, r *http.Request) {
|
|||
view.Set("menu", "categories")
|
||||
view.Set("user", user)
|
||||
view.Set("countUnread", c.store.CountUnreadEntries(user.ID))
|
||||
view.Set("hasSaveEntry", c.store.HasSaveEntry(user.ID))
|
||||
|
||||
html.OK(w, view.Render("entry"))
|
||||
}
|
||||
|
|
|
@ -93,6 +93,7 @@ func (c *Controller) ShowFeedEntry(w http.ResponseWriter, r *http.Request) {
|
|||
view.Set("menu", "feeds")
|
||||
view.Set("user", user)
|
||||
view.Set("countUnread", c.store.CountUnreadEntries(user.ID))
|
||||
view.Set("hasSaveEntry", c.store.HasSaveEntry(user.ID))
|
||||
|
||||
html.OK(w, view.Render("entry"))
|
||||
}
|
||||
|
|
|
@ -76,6 +76,7 @@ func (c *Controller) ShowReadEntry(w http.ResponseWriter, r *http.Request) {
|
|||
view.Set("menu", "history")
|
||||
view.Set("user", user)
|
||||
view.Set("countUnread", c.store.CountUnreadEntries(user.ID))
|
||||
view.Set("hasSaveEntry", c.store.HasSaveEntry(user.ID))
|
||||
|
||||
html.OK(w, view.Render("entry"))
|
||||
}
|
||||
|
|
|
@ -87,6 +87,7 @@ func (c *Controller) ShowUnreadEntry(w http.ResponseWriter, r *http.Request) {
|
|||
view.Set("menu", "unread")
|
||||
view.Set("user", user)
|
||||
view.Set("countUnread", c.store.CountUnreadEntries(user.ID))
|
||||
view.Set("hasSaveEntry", c.store.HasSaveEntry(user.ID))
|
||||
|
||||
html.OK(w, view.Render("entry"))
|
||||
}
|
||||
|
|
|
@ -73,6 +73,7 @@ func (c *Controller) ShowFeedEntries(w http.ResponseWriter, r *http.Request) {
|
|||
view.Set("menu", "feeds")
|
||||
view.Set("user", user)
|
||||
view.Set("countUnread", c.store.CountUnreadEntries(user.ID))
|
||||
view.Set("hasSaveEntry", c.store.HasSaveEntry(user.ID))
|
||||
|
||||
html.OK(w, view.Render("feed_entries"))
|
||||
}
|
||||
|
|
|
@ -54,6 +54,7 @@ func (c *Controller) ShowHistoryPage(w http.ResponseWriter, r *http.Request) {
|
|||
view.Set("menu", "history")
|
||||
view.Set("user", user)
|
||||
view.Set("countUnread", c.store.CountUnreadEntries(user.ID))
|
||||
view.Set("hasSaveEntry", c.store.HasSaveEntry(user.ID))
|
||||
|
||||
html.OK(w, view.Render("history"))
|
||||
html.OK(w, view.Render("history_entries"))
|
||||
}
|
||||
|
|
|
@ -58,6 +58,7 @@ func (c *Controller) ShowUnreadPage(w http.ResponseWriter, r *http.Request) {
|
|||
view.Set("menu", "unread")
|
||||
view.Set("user", user)
|
||||
view.Set("countUnread", c.store.CountUnreadEntries(user.ID))
|
||||
view.Set("hasSaveEntry", c.store.HasSaveEntry(user.ID))
|
||||
|
||||
html.OK(w, view.Render("unread"))
|
||||
html.OK(w, view.Render("unread_entries"))
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue