From 4d8de83cdc1de7c0900cc3b7e243b9d3d4c555bd Mon Sep 17 00:00:00 2001 From: Fabian Braun Date: Tue, 23 Jul 2024 08:32:08 +0200 Subject: [PATCH] chore: Release 3.1.4 (#1482) * Update CHANGELOG.rst * Update __init__.py * Fix: Crash when moving files from a filtered directory listing Co-authored-by: @W1ldPo1nter * Update CHANGELOG.rst --- CHANGELOG.rst | 14 ++++++++++++-- filer/__init__.py | 2 +- filer/admin/folderadmin.py | 3 +-- 3 files changed, 14 insertions(+), 5 deletions(-) diff --git a/CHANGELOG.rst b/CHANGELOG.rst index 944ec9489..55b601400 100644 --- a/CHANGELOG.rst +++ b/CHANGELOG.rst @@ -2,12 +2,22 @@ CHANGELOG ========= -3.1.3 (2025-05-17) +3.1.4 (2024-07-15) +================== + +* feat: Accept new `STORAGES` setting, introduced in Django 4.2 by @fsbraun in https://github.com/django-cms/django-filer/pull/1472 +* feat: Replace `render` with `TemplateResponse` in admin views by @fsbraun in https://github.com/django-cms/django-filer/pull/1473 +* fix: File expand url incorrect and worked not with custom image models by @fsbraun in https://github.com/django-cms/django-filer/pull/1471 +* fix: Crash when moving files from a filtered directory listing by @W1ldPo1nter in https://github.com/django-cms/django-filer/pull/1482 +* ci: pre-commit autoupdate by @pre-commit-ci in https://github.com/django-cms/django-filer/pull/1477 + + +3.1.3 (2024-05-17) ================== * Fix: Folder select widget did not render correctly with standard Django admin styles. -3.1.2 (2025-05-17) +3.1.2 (2024-05-17) ================== * Made the filer check command compatible with custom image models. diff --git a/filer/__init__.py b/filer/__init__.py index f324e2e66..7bd0b5d4e 100644 --- a/filer/__init__.py +++ b/filer/__init__.py @@ -13,4 +13,4 @@ 8. Publish the release and it will automatically release to pypi """ -__version__ = '3.1.3' +__version__ = '3.1.4' diff --git a/filer/admin/folderadmin.py b/filer/admin/folderadmin.py index 26f0b9be2..9ed16a2e9 100644 --- a/filer/admin/folderadmin.py +++ b/filer/admin/folderadmin.py @@ -321,14 +321,13 @@ def directory_listing(self, request, folder_id=None, viewtype=None): order_by = request.GET.get('order_by', None) order_by_annotation = None if order_by is None: - file_qs = file_qs.annotate(coalesce_sort_field=Coalesce( + order_by_annotation = Lower(Coalesce( Case( When(name__exact='', then=None), When(name__isnull=False, then='name') ), 'original_filename' )) - order_by_annotation = Lower('coalesce_sort_field') order_by = order_by.split(',') if order_by else [] order_by = [field for field in order_by