Hide "Reason" in Application PDF if there is none.

This commit is contained in:
Norman Jäckel 2012-07-06 15:30:14 +02:00
parent 59e6218a80
commit e4367051df
1 changed files with 3 additions and 2 deletions

View File

@ -828,8 +828,9 @@ class ApplicationPDF(PDFView):
# text
story.append(Paragraph("%s" % application.public_version.text.replace('\r\n','<br/>'), stylesheet['Paragraph']))
# reason
story.append(Paragraph(_("Reason")+":", stylesheet['Heading3']))
story.append(Paragraph("%s" % application.public_version.reason.replace('\r\n','<br/>'), stylesheet['Paragraph']))
if application.public_version.reason:
story.append(Paragraph(_("Reason")+":", stylesheet['Heading3']))
story.append(Paragraph("%s" % application.public_version.reason.replace('\r\n','<br/>'), stylesheet['Paragraph']))
return story