From 71d7972a1a99c91845040c32c9e2f397fd50ac94 Mon Sep 17 00:00:00 2001 From: Sam Wolfe Date: Thu, 14 Nov 2024 14:56:26 -0800 Subject: [PATCH] Sync inactive resources --- djautotask/__init__.py | 2 +- djautotask/sync.py | 8 +++++++- 2 files changed, 8 insertions(+), 2 deletions(-) diff --git a/djautotask/__init__.py b/djautotask/__init__.py index b29a95a..109c353 100644 --- a/djautotask/__init__.py +++ b/djautotask/__init__.py @@ -1,5 +1,5 @@ # -*- coding: utf-8 -*- -VERSION = (1, 6, 11, 'final') +VERSION = (1, 6, 12, 'final') # pragma: no cover if VERSION[-1] != "final": diff --git a/djautotask/sync.py b/djautotask/sync.py index e9a7139..1ad9865 100644 --- a/djautotask/sync.py +++ b/djautotask/sync.py @@ -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']