Fix refactoring bugs

This commit is contained in:
Lance Edgar 2020-03-17 16:36:31 -05:00
parent cb63644c7d
commit 42184e34b7

View file

@ -65,11 +65,11 @@ class FromCOREAPIToRattail(NewDataSyncImportConsumer):
# normal logic works fine for this (maybe?) # normal logic works fine for this (maybe?)
self.invoke_importer(session, change) self.invoke_importer(session, change)
else: else:
# import customer data from API, into various Rattail tables # import member data from API, into various Rattail tables
customer = self.get_host_object(session, change) member = self.get_host_object(session, change)
self.process_change(session, self.importers['Customer'], self.process_change(session, self.importers['Customer'],
host_object=customer) host_object=member)
people = self.importers['Person'].get_person_objects_for_customer(customer) people = self.importers['Person'].get_person_objects_for_member(member)
for person in people: for person in people:
self.process_change(session, self.importers['Person'], self.process_change(session, self.importers['Person'],
host_object=person) host_object=person)