chore: Bump copyright year
[mailman-postorious.git] / src / postorius / forms / member_forms.py
blob7ba37f03860f4aa45a99c2c931a4b6130ae6f809
1 # -*- coding: utf-8 -*-
2 # Copyright (C) 2017-2023 by the Free Software Foundation, Inc.
4 # This file is part of Postorius.
6 # Postorius is free software: you can redistribute it and/or modify it under
7 # the terms of the GNU General Public License as published by the Free
8 # Software Foundation, either version 3 of the License, or (at your option)
9 # any later version.
11 # Postorius is distributed in the hope that it will be useful, but WITHOUT
12 # ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
13 # FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for
14 # more details.
16 # You should have received a copy of the GNU General Public License along with
17 # Postorius. If not, see <http://www.gnu.org/licenses/>.
20 from django import forms
21 from django.utils.translation import gettext_lazy as _
24 class MemberForm(forms.Form):
25 """Assign a role to the member"""
27 email = forms.EmailField(
28 label=_('Email Address'),
29 error_messages={
30 'required': _('Please enter an email address.'),
31 'invalid': _('Please enter a valid email address.'),
34 display_name = forms.CharField(
35 label=_('Display Name'),
36 required=False,
37 error_messages={'invalid': _('Please enter a display name.')},