1
0
Fork 0
mirror of https://github.com/miniflux/v2.git synced 2025-08-01 17:38:37 +00:00

feat: API: Allow filtering entries on globally_hidden

Currently there's no way through the API to mimic the Unread page of the client.
This is now possible by filtering on globally_visible=true and status=unread.
This commit is contained in:
Pontus Jensen Karlsson 2024-08-08 04:46:09 +00:00 committed by Frédéric Guillot
parent 770cc1dbb3
commit 6fb7e84ce1
4 changed files with 62 additions and 0 deletions

View file

@ -149,6 +149,15 @@ func (h *handler) findEntries(w http.ResponseWriter, r *http.Request, feedID int
builder.WithLimit(limit)
builder.WithTags(tags)
builder.WithEnclosures()
if request.HasQueryParam(r, "globally_visible") {
globallyVisible := request.QueryBoolParam(r, "globally_visible", true)
if globallyVisible {
builder.WithGloballyVisible()
}
}
configureFilters(builder, r)
entries, err := builder.GetEntries()