removed empty lines in mails. bugfix regarding mail generation
This commit is contained in:
parent
334bffdad0
commit
910c24f703
2
TODO
2
TODO
|
@ -1,5 +1,3 @@
|
|||
- remove empty lines in mail
|
||||
|
||||
- in mail ändern "Deine mailadresse" in "ansprechpartner_in"
|
||||
|
||||
- true/false übersetzen in dataloop
|
||||
|
|
|
@ -1,9 +1,4 @@
|
|||
{% autoescape off %}
|
||||
{% for key, value in data.items %}
|
||||
{% if key == 'laptop' %}
|
||||
{{ key }}: {{ value | safe}}
|
||||
{% else %}
|
||||
{{ key }}: {{ value }}
|
||||
{% endif %}
|
||||
{% endfor %}
|
||||
{% for key, value in data.items %}{% if key == 'laptop' %} {{ key }}: {{ value | safe}}{% else %}
|
||||
{{ key }}: {{ value }}{% endif %}{% endfor %}
|
||||
{% endautoescape %}
|
||||
|
|
|
@ -178,7 +178,10 @@ class EvaFormView(LoginRequiredMixin, CookieWizardView):
|
|||
data['accounts'] = [ACCOUNT_CHOICES[c] for c in data['accounts']]
|
||||
|
||||
# replace keys in data dictionary with verbose_name
|
||||
mail = data.pop('email')
|
||||
mail = ''
|
||||
if 'email' in data:
|
||||
mail = data.pop('email')
|
||||
newdata = {self.instance._meta.get_field(k).verbose_name.title() : v for k,v in data.items()}
|
||||
newdata['email'] = mail
|
||||
if mail:
|
||||
newdata['email'] = mail
|
||||
return newdata
|
||||
|
|
Loading…
Reference in New Issue