Skip to content

Commit

Permalink
Merge pull request #2211 from coronasafe/develop
Browse files Browse the repository at this point in the history
Merge Develop to Staging v24.23.0
  • Loading branch information
gigincg authored Jun 1, 2024
2 parents b0f7e80 + 59c05b9 commit fd2e71a
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 2 deletions.
3 changes: 2 additions & 1 deletion care/facility/templatetags/filters.py
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,8 @@ def suggestion_string(suggestion_code: str):

@register.filter()
def field_name_to_label(value):
return value.replace("_", " ").capitalize()
if value:
return value.replace("_", " ").capitalize()


@register.filter(expects_localtime=True)
Expand Down
2 changes: 1 addition & 1 deletion care/templates/reports/patient_discharge_summary_pdf.html
Original file line number Diff line number Diff line change
Expand Up @@ -67,7 +67,7 @@ <h3 class="text-lg text-gray-900">
<span class="text-sm text-gray-500">Address:</span> {{patient.address}}
</p>
<p class="flex-grow">
<span class="text-sm text-gray-500">Ration Card Category:</span> {{patient.get_ration_card_category_display|field_name_to_label}}
<span class="text-sm text-gray-500">Ration Card Category:</span> {{patient.get_ration_card_category_display}}
</p>
</div>
</div>
Expand Down

0 comments on commit fd2e71a

Please sign in to comment.