small refactor in as_operations to prepare for m2m
This commit is contained in:
parent
5474ff6ae5
commit
8a9ab6396f
1 changed files with 9 additions and 7 deletions
|
@ -589,13 +589,15 @@ class ChangedObjectCollection(BaseSchema):
|
||||||
ended_situations.append(situation)
|
ended_situations.append(situation)
|
||||||
|
|
||||||
if done_situation:
|
if done_situation:
|
||||||
result = DatabaseOperationCollection(
|
operations = done_situation.operations
|
||||||
prev=self.prev,
|
else:
|
||||||
)
|
# todo: what to do if we can't fully solve it?
|
||||||
result.extend(done_situation.operations)
|
raise NotImplementedError('couldnt fully solve as_operations')
|
||||||
return result
|
|
||||||
|
|
||||||
# todo: m2m
|
# todo: m2m
|
||||||
|
|
||||||
# todo: what to do if we can't fully solve it?
|
result = DatabaseOperationCollection(
|
||||||
raise NotImplementedError('couldnt fully solve as_operations')
|
prev=self.prev,
|
||||||
|
)
|
||||||
|
result.extend(operations)
|
||||||
|
return result
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue