Lots of work for ISHLT badge printing.

This commit is contained in:
Scott Idem
2023-02-01 17:57:22 -05:00
parent a9f0e2bf3d
commit a176248104
6 changed files with 332 additions and 161 deletions

View File

@@ -273,6 +273,8 @@ def get_event_registrants(
# ### BEGIN ### API External Impexium Methods ### get_individual_profile() ###
# Updated 2022-04-22
# NOTE: Without details the results are very basic. Pretty much just their name.
# Including details adds the addresses, customFields, emails, memberships, phones, etc
@logger_reset
def get_individual_profile(
individual_id: str,
@@ -309,6 +311,7 @@ def get_individual_profile(
# log.debug(resp.json())
if resp.status_code == 200:
log.info('Status 200')
log.debug(resp.json())
impexium_individual_profile_raw = resp.json() # .get('data').get('dataList')[0]
@@ -319,7 +322,7 @@ def get_individual_profile(
try_request = False
elif resp.status_code == 404:
log.info('No results returned.')
log.info('No results returned (status 404)')
try_request = False
impexium_individual_profile = None
elif resp.status_code == 429:
@@ -328,6 +331,7 @@ def get_individual_profile(
try_request = True
impexium_individual_profile = False
else:
log.info('Not trying again')
try_request = False
impexium_event_registration_list = False