mirror of
https://github.com/cisagov/manage.get.gov.git
synced 2025-05-17 01:57:03 +02:00
solidify the bool checks on db_check_for_unlocking_steps
This commit is contained in:
parent
b4cd403939
commit
81c8fe97fa
3 changed files with 42 additions and 24 deletions
|
@ -92,6 +92,12 @@ def parse_row(columns, domain_info: DomainInformation, security_emails_dict=None
|
|||
"Deleted": domain.deleted,
|
||||
}
|
||||
|
||||
# user_emails = [user.email for user in domain.permissions]
|
||||
|
||||
# Dynamically add user emails to the FIELDS dictionary
|
||||
# for i, user_email in enumerate(user_emails, start=1):
|
||||
# FIELDS[f"User{i} email"] = user_email
|
||||
|
||||
row = [FIELDS.get(column, "") for column in columns]
|
||||
return row
|
||||
|
||||
|
@ -127,6 +133,16 @@ def write_body(
|
|||
else:
|
||||
logger.warning("csv_export -> Domain was none for PublicContact")
|
||||
|
||||
# all_user_nums = 0
|
||||
# for domain_info in all_domain_infos:
|
||||
# user_num = len(domain_info.domain.permissions)
|
||||
# all_user_nums.append(user_num)
|
||||
|
||||
# if user_num > highest_user_nums:
|
||||
# highest_user_nums = user_num
|
||||
|
||||
# Build the header here passing to it highest_user_nums
|
||||
|
||||
# Reduce the memory overhead when performing the write operation
|
||||
paginator = Paginator(all_domain_infos, 1000)
|
||||
for page_num in paginator.page_range:
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue