Skip to content

Commit

Permalink
Add a filter for unblocked_at for Tasks API
Browse files Browse the repository at this point in the history
closes: #6165
  • Loading branch information
git-hyagi committed Jan 6, 2025
1 parent 5cd170b commit 57d64d3
Show file tree
Hide file tree
Showing 3 changed files with 3 additions and 1 deletion.
1 change: 1 addition & 0 deletions CHANGES/6165.feature
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
Added the unblocked_at filter for Tasks API.
2 changes: 1 addition & 1 deletion pulpcore/app/viewsets/base.py
Original file line number Diff line number Diff line change
Expand Up @@ -45,7 +45,7 @@
# e.g.
# /?name=foo
# /?name__in=foo,bar
DATETIME_FILTER_OPTIONS = ["exact", "lt", "lte", "gt", "gte", "range"]
DATETIME_FILTER_OPTIONS = ["exact", "lt", "lte", "gt", "gte", "range", "isnull"]
# e.g.
# /?pulp_created__gte=2018-04-12T19:45:52
# /?pulp_created__range=2018-04-12T19:45:52,2018-04-13T19:45:52
Expand Down
1 change: 1 addition & 0 deletions pulpcore/app/viewsets/task.py
Original file line number Diff line number Diff line change
Expand Up @@ -65,6 +65,7 @@ class Meta:
"logging_cid": ["exact", "contains"],
"started_at": DATETIME_FILTER_OPTIONS,
"finished_at": DATETIME_FILTER_OPTIONS,
"unblocked_at": DATETIME_FILTER_OPTIONS,
"parent_task": ["exact"],
"child_tasks": ["exact"],
"task_group": ["exact"],
Expand Down

0 comments on commit 57d64d3

Please sign in to comment.