Skip to content
Snippets Groups Projects
Commit 9b868369 authored by Piotr Gawron's avatar Piotr Gawron
Browse files

activity_type is included on printable voucher

parent 25fc7b14
No related branches found
No related tags found
1 merge request!151Resolve "voucher should have optional activy type (free text)"
......@@ -293,11 +293,11 @@ class MailTemplate(models.Model):
if voucher is not None:
voucher_type = voucher.voucher_type.description
if voucher.activity_type != '':
voucher_type += ' ' + voucher.activity_type
voucher_type += ' (' + voucher.activity_type + ")"
return {
"##C_NUMBER##": voucher.number,
"##C_PATIENT_NAME##": voucher.study_subject.subject.first_name + ' ' + voucher.study_subject.subject.last_name,
"##C_VOUCHER_TYPE##": voucher.voucher_type.description,
"##C_VOUCHER_TYPE##": voucher_type,
"##C_ISSUE_DATE_SHORT##": voucher.issue_date.strftime(DATE_FORMAT_SHORT).decode(date_format_encoding()),
"##C_EXPIRY_START_SHORT##": voucher.expiry_date.strftime(DATE_FORMAT_SHORT).decode(
date_format_encoding()),
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment