Commit be831914 authored by Thom Wiggers's avatar Thom Wiggers 📐

Merge branch 'feature/mailinglists-translation' into 'master'

Translation mailinglist models

Closes #337

See merge request !386
parents 6a1283d9 35ba8d1c
......@@ -7,17 +7,49 @@ msgid ""
msgstr ""
"Project-Id-Version: \n"
"Report-Msgid-Bugs-To: \n"
"POT-Creation-Date: 2016-11-14 22:19+0100\n"
"PO-Revision-Date: 2016-11-14 22:19+0100\n"
"POT-Creation-Date: 2017-02-26 18:17+0100\n"
"PO-Revision-Date: 2017-02-26 18:18+0100\n"
"Last-Translator: Sébastiaan Versteeg <se_bastiaan@outlook.com>\n"
"Language-Team: \n"
"Language: nl\n"
"MIME-Version: 1.0\n"
"Content-Type: text/plain; charset=UTF-8\n"
"Content-Transfer-Encoding: 8bit\n"
"Plural-Forms: nplurals=2; plural=(n != 1);\n"
"Last-Translator: Joost Rijneveld <joost@joostrijneveld.nl>\n"
"Language-Team: \n"
"X-Generator: Poedit 1.8.11\n"
"X-Generator: Poedit 1.8.12\n"
#: models.py:12
msgid "Name"
msgstr "Naam"
#: models.py:13 models.py:51
#: models.py:16 models.py:75
msgid "Enter a simpler name"
msgstr "Vul een eenvoudigere naam in"
#: models.py:21
msgid "Prefix"
msgstr "Voorvoegsel"
#: models.py:26
msgid "Archived"
msgstr "Gearchiveerd"
#: models.py:31
msgid "Moderated"
msgstr "Gemodereerd"
#: models.py:36
msgid "Members"
msgstr "Leden"
#: models.py:39
msgid "Committees"
msgstr "Commissies"
#: models.py:59 models.py:71
msgid "Email Address"
msgstr "E-mailadres"
#: models.py:61 models.py:79
msgid "Mailing list"
msgstr "Mailing list"
# -*- coding: utf-8 -*-
# Generated by Django 1.10.3 on 2017-02-26 17:22
from __future__ import unicode_literals
import django.core.validators
from django.db import migrations, models
import django.db.models.deletion
class Migration(migrations.Migration):
dependencies = [
('mailinglists', '0005_auto_20160805_2245'),
]
operations = [
migrations.AlterField(
model_name='listalias',
name='alias',
field=models.CharField(max_length=100, validators=[django.core.validators.RegexValidator(message='Enter a simpler name', regex='^[a-zA-Z0-9]+$')], verbose_name='Email Address'),
),
migrations.AlterField(
model_name='listalias',
name='mailinglist',
field=models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, related_name='aliasses', to='mailinglists.MailingList', verbose_name='Mailing list'),
),
migrations.AlterField(
model_name='mailinglist',
name='archived',
field=models.BooleanField(default=True, verbose_name='Archived'),
),
migrations.AlterField(
model_name='mailinglist',
name='committees',
field=models.ManyToManyField(blank=True, to='activemembers.Committee', verbose_name='Committees'),
),
migrations.AlterField(
model_name='mailinglist',
name='members',
field=models.ManyToManyField(blank=True, to='members.Member', verbose_name='Members'),
),
migrations.AlterField(
model_name='mailinglist',
name='moderated',
field=models.BooleanField(default=False, verbose_name='Moderated'),
),
migrations.AlterField(
model_name='mailinglist',
name='name',
field=models.CharField(max_length=100, validators=[django.core.validators.RegexValidator(message='Enter a simpler name', regex='^[a-zA-Z0-9]+$')], verbose_name='Name'),
),
migrations.AlterField(
model_name='mailinglist',
name='prefix',
field=models.CharField(max_length=200, verbose_name='Prefix'),
),
migrations.AlterField(
model_name='verbatimaddress',
name='address',
field=models.EmailField(max_length=254, verbose_name='Email Address'),
),
migrations.AlterField(
model_name='verbatimaddress',
name='mailinglist',
field=models.ForeignKey(on_delete=django.db.models.deletion.CASCADE, related_name='addresses', to='mailinglists.MailingList', verbose_name='Mailing list'),
),
]
......@@ -8,17 +8,36 @@ from members.models import Member
class MailingList(models.Model):
name = models.CharField(max_length=100,
validators=[validators.RegexValidator(
regex=r'^[a-zA-Z0-9]+$',
message=_('Enter a simpler name'))
],
)
prefix = models.CharField(max_length=200)
archived = models.BooleanField(default=True)
moderated = models.BooleanField(default=False)
members = models.ManyToManyField(Member, blank=True)
committees = models.ManyToManyField(Committee, blank=True)
name = models.CharField(
verbose_name=_("Name"),
max_length=100,
validators=[validators.RegexValidator(
regex=r'^[a-zA-Z0-9]+$',
message=_('Enter a simpler name'))
],
)
prefix = models.CharField(
verbose_name=_("Prefix"),
max_length=200
)
archived = models.BooleanField(
verbose_name=_("Archived"),
default=True
)
moderated = models.BooleanField(
verbose_name=_("Moderated"),
default=False
)
members = models.ManyToManyField(Member,
verbose_name=_("Members"),
blank=True)
committees = models.ManyToManyField(Committee,
verbose_name=_("Committees"),
blank=True)
def all_addresses(self):
for member in self.members.all():
......@@ -37,8 +56,9 @@ class MailingList(models.Model):
class VerbatimAddress(models.Model):
address = models.EmailField()
address = models.EmailField(_("Email Address"))
mailinglist = models.ForeignKey(MailingList,
verbose_name=_("Mailing list"),
on_delete=models.CASCADE,
related_name='addresses')
......@@ -47,12 +67,15 @@ class VerbatimAddress(models.Model):
class ListAlias(models.Model):
alias = models.CharField(max_length=100,
validators=[validators.RegexValidator(
regex=r'^[a-zA-Z0-9]+$',
message=_('Enter a simpler name'))
],
)
alias = models.CharField(
verbose_name=_("Email Address"),
max_length=100,
validators=[validators.RegexValidator(
regex=r'^[a-zA-Z0-9]+$',
message=_('Enter a simpler name'))
],
)
mailinglist = models.ForeignKey(MailingList,
verbose_name=_("Mailing list"),
on_delete=models.CASCADE,
related_name='aliasses')
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment