mirror of
https://github.com/lrnselfreliance/wrolpi.git
synced 2026-11-22 16:06:19 -05:00
Fixing Archive download sorting by moving nulls to the end.
This commit is contained in:
parent
fab3fd62ed
commit
13407af64c
1 changed files with 4 additions and 4 deletions
|
|
@ -442,12 +442,12 @@ def get_domains():
|
|||
|
||||
|
||||
ARCHIVE_ORDERS = {
|
||||
'published_datetime': (date := 'COALESCE(fg.published_datetime, fg.download_datetime) ASC'),
|
||||
'published_datetime': (date := 'COALESCE(fg.published_datetime, fg.download_datetime) ASC NULLS LAST'),
|
||||
'-published_datetime': (_date := 'COALESCE(fg.published_datetime, fg.download_datetime) DESC NULLS LAST'),
|
||||
'published_modified_datetime': f'fg.published_modified_datetime ASC NULLS LAST, {date}',
|
||||
'-published_modified_datetime': f'fg.published_modified_datetime DESC, {_date}',
|
||||
'download_datetime': 'fg.download_datetime ASC',
|
||||
'-download_datetime': 'fg.download_datetime DESC',
|
||||
'-published_modified_datetime': f'fg.published_modified_datetime DESC NULLS LAST, {_date}',
|
||||
'download_datetime': 'fg.download_datetime ASC NULLS LAST',
|
||||
'-download_datetime': 'fg.download_datetime DESC NULLS LAST',
|
||||
'rank': f'2 DESC, {_date}',
|
||||
'-rank': f'2 ASC, {date}',
|
||||
'size': 'fg.size ASC, LOWER(fg.primary_path) ASC',
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue