From 1be08e4420bb0a8ab5e1d864f98d26e7e91404b5 Mon Sep 17 00:00:00 2001 From: Oliver Date: Thu, 12 Mar 2026 18:03:31 +1100 Subject: [PATCH] [API] Allow filtering ScheduledTask objects by name (#11497) * [API] Allow filtering ScheduledTask objects by name * Bump API version --- src/backend/InvenTree/InvenTree/api_version.py | 5 ++++- src/backend/InvenTree/common/api.py | 2 +- 2 files changed, 5 insertions(+), 2 deletions(-) diff --git a/src/backend/InvenTree/InvenTree/api_version.py b/src/backend/InvenTree/InvenTree/api_version.py index 68b040ae75..5b266f89e8 100644 --- a/src/backend/InvenTree/InvenTree/api_version.py +++ b/src/backend/InvenTree/InvenTree/api_version.py @@ -1,11 +1,14 @@ """InvenTree API version information.""" # InvenTree API version -INVENTREE_API_VERSION = 461 +INVENTREE_API_VERSION = 462 """Increment this API version number whenever there is a significant change to the API that any clients need to know about.""" INVENTREE_API_TEXT = """ +v462 -> 2026-03-12 : https://github.com/inventree/InvenTree/pull/11497 + - Allow "ScheduledTask" API endpoint to be filtered by "name" field + v461 -> 2026-03-10 : https://github.com/inventree/InvenTree/pull/11479 - Adds option to copy parameters when duplicating an order via the API diff --git a/src/backend/InvenTree/common/api.py b/src/backend/InvenTree/common/api.py index 3b6cc14de5..69f41e80ff 100644 --- a/src/backend/InvenTree/common/api.py +++ b/src/backend/InvenTree/common/api.py @@ -608,7 +608,7 @@ class ScheduledTaskList(ListAPI): ordering_fields = ['pk', 'func', 'last_run', 'next_run'] - search_fields = ['func'] + search_fields = ['func', 'name'] def get_queryset(self): """Return annotated queryset."""