Skip to content

Commit

Permalink
Sync inactive resources
Browse files Browse the repository at this point in the history
  • Loading branch information
Sam Wolfe committed Nov 14, 2024
1 parent a4359be commit 71d7972
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 2 deletions.
2 changes: 1 addition & 1 deletion djautotask/__init__.py
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
# -*- coding: utf-8 -*-
VERSION = (1, 6, 11, 'final')
VERSION = (1, 6, 12, 'final')

# pragma: no cover
if VERSION[-1] != "final":
Expand Down
8 changes: 7 additions & 1 deletion djautotask/sync.py
Original file line number Diff line number Diff line change
Expand Up @@ -1860,7 +1860,13 @@ class ResourceSynchronizer(Synchronizer):

def __init__(self, *args, **kwargs):
super().__init__(*args, **kwargs)
self.client.add_condition(A(op='eq', field='isActive', value=True))
self.client.add_condition(
A(
A(op='eq', field='isActive', value=True),
A(op='eq', field='isActive', value=False),
op='or'
)
)

def _assign_field_data(self, instance, object_data):
instance.id = object_data['id']
Expand Down

0 comments on commit 71d7972

Please sign in to comment.