Skip to content

Commit

Permalink
Make interpretation location a variable
Browse files Browse the repository at this point in the history
We're adding inline interpretations to Regulation D. Unlike all of our other
regs, Reg D houses its interpretations in Appendix A instead of Supplement I.
We had "Supplement I" hardcoded into the text of the links at the end of all
inline interpretations, which didn't make sense for inline interps in Reg D.
This commit fixes that by making the reference to the location of the interps
in those links a variable and sets up a special case for Reg D interps.
  • Loading branch information
niqjohnson committed May 8, 2020
1 parent b0c4baa commit 3d3e171
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion cfgov/regulations3k/jinja2/regulations3k/inline_interps.html
Original file line number Diff line number Diff line change
@@ -1,3 +1,6 @@
{#- Part 1004 (Reg D) houses interps in Appendix A instead of Supplement I like every other reg -#}
{%- set interp_location = 'Appendix A' if regulation and regulation.part_number == '1004' else 'Supplement I' -%}

<div data-qa-hook="expandable"
class="o-expandable
o-expandable__padded
Expand Down Expand Up @@ -28,7 +31,7 @@
<div class="o-expandable_content">
{{ contents }}

<p><a href="{{ url }}">See interpretation of {% if section_title %}{{ section_title }}{% else %}this section{% endif %} in Supplement I</a></p>
<p><a href="{{ url }}">See interpretation of {% if section_title %}{{ section_title }}{% else %}this section{% endif %} in {{ interp_location }}</a></p>
</div>

</div>

0 comments on commit 3d3e171

Please sign in to comment.