Change to person.contact_id and related bug fixes.

This commit is contained in:
Scott Idem
2021-08-08 12:35:59 -04:00
parent 3310d9fc8b
commit 4ea30cef62

View File

@@ -466,7 +466,7 @@ def create_update_person_obj(
person_obj.id = person_id
else:
# Insert record now and update later
person_dict_in = person_obj.dict(by_alias=False, exclude_unset=True, exclude={'contact', 'organization', 'user'})
person_dict_in = person_obj.dict(by_alias=False, exclude_unset=True, exclude={'contact_id', 'contact_id_random', 'contact', 'organization', 'user'})
log.debug(person_dict_in)
person_in_result = sql_insert(
data = person_dict_in,
@@ -525,7 +525,7 @@ def create_update_person_obj(
log.warning('Something may have gone wrong while trying to create or update a organization.')
# Process person data
person_dict_up = person_obj.dict(by_alias=False, exclude_unset=True, exclude={'contact', 'organization', 'user'})
person_dict_up = person_obj.dict(by_alias=False, exclude_unset=True, exclude={'contact_id', 'contact_id_random', 'contact', 'organization', 'user'})
# log.setLevel(logging.DEBUG) # DEBUG, INFO, WARNING, ERROR, EXCEPTION, CRITICAL
log.debug(person_obj)
log.debug(person_dict_up)