Skip to content
This repository

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Browse code

Merge pull request #19 from julsam/generic_mail_subject

mail subject : using property instead of a hardwritten string
  • Loading branch information...
commit 7483a246b309cd6bfb3a2c70735deb0e9d5aa52b 2 parents bde6079 + a6f597e
Marc-Stefan Cassola authored September 21, 2011

Showing 1 changed file with 2 additions and 1 deletion. Show diff stats Hide diff stats

  1. 3  cmsplugin_contact/cms_plugins.py
3  cmsplugin_contact/cms_plugins.py
@@ -18,6 +18,7 @@ class ContactPlugin(CMSPluginBase):
18 18
     render_template = "cmsplugin_contact/contact.html"
19 19
     form = ContactAdminForm
20 20
     contact_form = ContactForm
  21
+    subject_template = "cmsplugin_contact/subject.txt"
21 22
     email_template = "cmsplugin_contact/email.txt"
22 23
     
23 24
     fieldsets = (
@@ -96,7 +97,7 @@ def send(self, form, site_email):
96 97
         if not subject:
97 98
             subject = _('No subject')
98 99
         email_message = EmailMessage(
99  
-            render_to_string("cmsplugin_contact/subject.txt", {
  100
+            render_to_string(self.subject_template, {
100 101
                 'subject': subject,
101 102
             }),
102 103
             render_to_string(self.email_template, {

0 notes on commit 7483a24

Please sign in to comment.
Something went wrong with that request. Please try again.