diff --git a/publichealth/home/migrations/0011_auto_20170412_1256.py b/publichealth/home/migrations/0011_auto_20170412_1256.py new file mode 100644 index 0000000..a65c1e3 --- /dev/null +++ b/publichealth/home/migrations/0011_auto_20170412_1256.py @@ -0,0 +1,42 @@ +# -*- coding: utf-8 -*- +# Generated by Django 1.10.6 on 2017-04-12 10:56 +from __future__ import unicode_literals + +from django.db import migrations, models + + +class Migration(migrations.Migration): + + dependencies = [ + ('home', '0010_auto_20170410_2307'), + ] + + operations = [ + migrations.RenameField( + model_name='contactform', + old_name='intro_de', + new_name='intro', + ), + migrations.RenameField( + model_name='contactform', + old_name='intro_fr', + new_name='thanks', + ), + migrations.RemoveField( + model_name='contactform', + name='thanks_de', + ), + migrations.RemoveField( + model_name='contactform', + name='thanks_fr', + ), + migrations.RemoveField( + model_name='contactform', + name='title_fr', + ), + migrations.AlterField( + model_name='articlepage', + name='on_homepage', + field=models.BooleanField(default=False, help_text='Auf der Frontpage anzeigen', verbose_name='Featured'), + ), + ] diff --git a/publichealth/home/models/forms.py b/publichealth/home/models/forms.py index f4c1f09..620ac4d 100644 --- a/publichealth/home/models/forms.py +++ b/publichealth/home/models/forms.py @@ -19,32 +19,12 @@ class ContactFormField(AbstractFormField): page = ParentalKey('ContactForm', related_name='form_fields') class ContactForm(AbstractEmailForm): - title_fr = CharField(max_length=255, default="") - trans_title = TranslatedField( - 'title', - 'title_fr', - ) - - intro_de = RichTextField(default='', blank=True) - intro_fr = RichTextField(default='', blank=True) - trans_intro = TranslatedField( - 'intro_de', - 'intro_fr', - ) - - thanks_de = RichTextField(default='', blank=True) - thanks_fr = RichTextField(default='', blank=True) - trans_thanks = TranslatedField( - 'thanks_de', - 'thanks_fr', - ) + intro = RichTextField(default='', blank=True) + thanks = RichTextField(default='', blank=True) content_panels = AbstractEmailForm.content_panels + [ - FieldPanel('intro_de', classname="full"), - FieldPanel('thanks_de', classname="full"), - FieldPanel('title_fr', classname="full"), - FieldPanel('intro_fr', classname="full"), - FieldPanel('thanks_fr', classname="full"), + FieldPanel('intro', classname="full"), + FieldPanel('thanks', classname="full"), InlinePanel('form_fields', label="Form fields"), MultiFieldPanel([ FieldRowPanel([