Add option to hide feeds from the global Unread list
This commit is contained in:
parent
8bc06a5d65
commit
9965abccfb
23 changed files with 49 additions and 5 deletions
|
@ -51,6 +51,7 @@ type Feed struct {
|
|||
Category *Category `json:"category,omitempty"`
|
||||
Entries Entries `json:"entries,omitempty"`
|
||||
Icon *FeedIcon `json:"icon"`
|
||||
HideGlobally bool `json:"hide_globally"`
|
||||
UnreadCount int `json:"-"`
|
||||
ReadCount int `json:"-"`
|
||||
}
|
||||
|
@ -134,6 +135,7 @@ type FeedCreationRequest struct {
|
|||
RewriteRules string `json:"rewrite_rules"`
|
||||
BlocklistRules string `json:"blocklist_rules"`
|
||||
KeeplistRules string `json:"keeplist_rules"`
|
||||
HideGlobally bool `json:"hide_globally"`
|
||||
}
|
||||
|
||||
// FeedModificationRequest represents the request to update a feed.
|
||||
|
@ -155,6 +157,7 @@ type FeedModificationRequest struct {
|
|||
IgnoreHTTPCache *bool `json:"ignore_http_cache"`
|
||||
AllowSelfSignedCertificates *bool `json:"allow_self_signed_certificates"`
|
||||
FetchViaProxy *bool `json:"fetch_via_proxy"`
|
||||
HideGlobally *bool `json:"hide_globally"`
|
||||
}
|
||||
|
||||
// Patch updates a feed with modified values.
|
||||
|
@ -226,6 +229,10 @@ func (f *FeedModificationRequest) Patch(feed *Feed) {
|
|||
if f.FetchViaProxy != nil {
|
||||
feed.FetchViaProxy = *f.FetchViaProxy
|
||||
}
|
||||
|
||||
if f.HideGlobally != nil {
|
||||
feed.HideGlobally = *f.HideGlobally
|
||||
}
|
||||
}
|
||||
|
||||
// Feeds is a list of feed
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue