forms.py 534 B

12345678910111213141516
  1. from django.core.validators import RegexValidator
  2. from django.utils.translation import ugettext_lazy as _
  3. from django import forms
  4. from misago.forms import Form, YesNoSwitch
  5. class RoleForm(Form):
  6. name = forms.CharField(max_length=255)
  7. layout = (
  8. (
  9. _("Basic Role Options"),
  10. (
  11. ('name', {'label': _("Role Name"), 'help_text': _("Role Name is used to identify this role in Admin Control Panel.")}),
  12. ),
  13. ),
  14. )