Skip to content

Commit

Permalink
adding case name and court to alerts
Browse files Browse the repository at this point in the history
  • Loading branch information
v-anne committed Sep 30, 2024
1 parent b823d22 commit 81213af
Show file tree
Hide file tree
Showing 3 changed files with 7 additions and 1 deletion.
4 changes: 3 additions & 1 deletion cl/search/signals.py
Original file line number Diff line number Diff line change
Expand Up @@ -594,7 +594,7 @@ def handle_recap_doc_change(
html_template = loader.get_template("prayer_email.html")

case_name = instance.docket_entry.docket.case_name
court = instance.docket_entry.docket.court
# court = instance.docket_entry.docket.court.citation_string
document = instance.get_absolute_url()
num_waiting = len(email_recipients)
doc_price = price(instance)
Expand All @@ -603,6 +603,8 @@ def handle_recap_doc_change(
for email_recipient in email_recipients:

context = {
"case_name": case_name,
"court": court,
"document": document,
"num_waiting": num_waiting,
"price": doc_price,
Expand Down
2 changes: 2 additions & 0 deletions cl/search/templates/prayer_email.html
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,8 @@ <h1 class="bottom" style="font-size: 3em; font-weight: normal; line-height: 1;

<hr style="background: #ddd; color: #ddd; clear: both; float: none; width: 60%; height: .1em; margin: 0 0 1.45em; border: none;">

<p>{{case_name}}, {{court}}</p>

<p>A document you requested to be purchased is now available on CourtListener.</p>
<a href="https://www.courtlistener.com{{document}}" style="font-size: 100%; font-weight: inherit; font-family: inherit; color: #009; border: 0; font-style: inherit; padding: 0; text-decoration: none; vertical-align: baseline; margin: 0;">
Click here to view.
Expand Down
2 changes: 2 additions & 0 deletions cl/search/templates/prayer_email.txt
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,8 @@ We have news regarding your alerts at CourtListener.com
A document you requested to be purchased is now available on CourtListener.
-------------------------------------------------------

{{case_name}}, {{court}}

- View this item on our site: https://www.courtlistener.com{{document}}

Somebody paid ${{price}} for this document.
Expand Down

0 comments on commit 81213af

Please sign in to comment.