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"
|
- in mail ändern "Deine mailadresse" in "ansprechpartner_in"
|
||||||
|
|
||||||
- true/false übersetzen in dataloop
|
- true/false übersetzen in dataloop
|
||||||
|
|
|
@ -1,9 +1,4 @@
|
||||||
{% autoescape off %}
|
{% autoescape off %}
|
||||||
{% for key, value in data.items %}
|
{% for key, value in data.items %}{% if key == 'laptop' %} {{ key }}: {{ value | safe}}{% else %}
|
||||||
{% if key == 'laptop' %}
|
{{ key }}: {{ value }}{% endif %}{% endfor %}
|
||||||
{{ key }}: {{ value | safe}}
|
|
||||||
{% else %}
|
|
||||||
{{ key }}: {{ value }}
|
|
||||||
{% endif %}
|
|
||||||
{% endfor %}
|
|
||||||
{% endautoescape %}
|
{% endautoescape %}
|
||||||
|
|
|
@ -178,7 +178,10 @@ class EvaFormView(LoginRequiredMixin, CookieWizardView):
|
||||||
data['accounts'] = [ACCOUNT_CHOICES[c] for c in data['accounts']]
|
data['accounts'] = [ACCOUNT_CHOICES[c] for c in data['accounts']]
|
||||||
|
|
||||||
# replace keys in data dictionary with verbose_name
|
# replace keys in data dictionary with verbose_name
|
||||||
|
mail = ''
|
||||||
|
if 'email' in data:
|
||||||
mail = data.pop('email')
|
mail = data.pop('email')
|
||||||
newdata = {self.instance._meta.get_field(k).verbose_name.title() : v for k,v in data.items()}
|
newdata = {self.instance._meta.get_field(k).verbose_name.title() : v for k,v in data.items()}
|
||||||
|
if mail:
|
||||||
newdata['email'] = mail
|
newdata['email'] = mail
|
||||||
return newdata
|
return newdata
|
||||||
|
|
Loading…
Reference in New Issue