mirror of
https://github.com/go-vikunja/vikunja.git
synced 2026-07-16 14:52:35 -05:00
sort_by=relevance renders as pdb.score(tasks.id) DESC at its requested position, so clients can express orderings like done,relevance (undone first, most relevant within each group). The implicit no-sort ranking reuses the same mechanism via an injected sort param. When the database or query shape cannot score, relevance params are dropped and the remaining sorts plus the id tiebreaker apply, so the field is safe to send unconditionally; getOrderByDBStatement also only emits pdb.score when ParadeDB is actually available. The quick-actions search sends sort_by=done,relevance (typed via TaskFilterParams) and keeps surfacing undone tasks first.