Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Switch af_dispositions and adr_dispositions to dispositions #6529

Open
wants to merge 1 commit into
base: develop
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 3 additions & 3 deletions fec/data/api_caller.py
Original file line number Diff line number Diff line change
Expand Up @@ -180,13 +180,13 @@ def load_legal_adr(adr_no):
# Or any default value you prefer if the list is empty
adr["disposition_text"] = None

adr["collated_dispositions"] = collate_dispositions(adr["adr_dispositions"])
adr["collated_dispositions"] = collate_dispositions(adr["dispositions"])
adr["complainants"] = complainants
adr["participants_by_type"] = _get_sorted_participants_by_type(adr)

referring_office = None # Initialize referring_office variable

for disposition in adr["adr_dispositions"]:
for disposition in adr["dispositions"]:
if "Received from" in disposition["disposition"]:
referring_office = disposition["disposition"]
# Transformation dictionary for referring office
Expand Down Expand Up @@ -228,7 +228,7 @@ def load_legal_admin_fines(admin_fine_no):
documents_by_type[doc["category"]] = [doc]
admin_fine["documents_by_type"] = documents_by_type
disposition_items = OrderedDict()
for item in admin_fine["af_dispositions"]:
for item in admin_fine["dispositions"]:
if item["disposition_description"] in disposition_items:
disposition_items[item["disposition_description"]].append(item)
else:
Expand Down
2 changes: 1 addition & 1 deletion fec/legal/templates/legal-admin_fine.jinja
Original file line number Diff line number Diff line change
Expand Up @@ -73,7 +73,7 @@
</tr>
</thead>
<tbody>
{% if 'af_dispositions' in admin_fine and admin_fine.disposition_items %}
{% if 'dispositions' in admin_fine and admin_fine.disposition_items %}
{% for item in admin_fine.disposition_items %}
{% set itemloop = loop %}
{% for item in admin_fine.disposition_items[item] %}
Expand Down