From 7a17913695c032362cffe483849d5d859f888ec0 Mon Sep 17 00:00:00 2001 From: Taha Yassine Kraiem Date: Tue, 31 Jan 2023 12:17:10 +0100 Subject: [PATCH] feat(chalice): fix errors sort --- api/chalicelib/core/errors.py | 4 ++-- ee/api/chalicelib/core/errors.py | 4 ++-- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/api/chalicelib/core/errors.py b/api/chalicelib/core/errors.py index 8d7c8c6e8..3ff0cf584 100644 --- a/api/chalicelib/core/errors.py +++ b/api/chalicelib/core/errors.py @@ -470,9 +470,9 @@ def search(data: schemas.SearchErrorsSchema, project_id, user_id): sort = __get_sort_key('datetime') if data.sort is not None: sort = __get_sort_key(data.sort) - order = schemas.SortOrderType.desc + order = schemas.SortOrderType.desc.value if data.order is not None: - order = data.order + order = data.order.value extra_join = "" params = { diff --git a/ee/api/chalicelib/core/errors.py b/ee/api/chalicelib/core/errors.py index adccdc558..c191c69cf 100644 --- a/ee/api/chalicelib/core/errors.py +++ b/ee/api/chalicelib/core/errors.py @@ -477,9 +477,9 @@ def search(data: schemas.SearchErrorsSchema, project_id, user_id): sort = __get_sort_key('datetime') if data.sort is not None: sort = __get_sort_key(data.sort) - order = schemas.SortOrderType.desc + order = schemas.SortOrderType.desc.value if data.order is not None: - order = data.order + order = data.order.value extra_join = "" params = {