diff options
Diffstat (limited to 'ishtar_common/models.py')
-rw-r--r-- | ishtar_common/models.py | 17 |
1 files changed, 17 insertions, 0 deletions
diff --git a/ishtar_common/models.py b/ishtar_common/models.py index 08276fa9f..1562280ef 100644 --- a/ishtar_common/models.py +++ b/ishtar_common/models.py @@ -1631,6 +1631,23 @@ post_save.connect(cached_site_changed, sender=IshtarSiteProfile) post_delete.connect(cached_site_changed, sender=IshtarSiteProfile) +class CustomForm(models.Model): + name = models.CharField(_(u"Name"), max_length=250) + form = models.CharField(_(u"Form"), max_length=250) + available = models.BooleanField(_(u"Available"), default=True) + apply_to_all = models.BooleanField( + _(u"Apply to all"), default=False, + help_text=_(u"Apply this form to all users. If set to True, selecting " + u"user and user type is useless.")) + users = models.ManyToManyField('IshtarUser', blank=True) + user_types = models.ManyToManyField('PersonType', blank=True) + + class Meta: + verbose_name = _(u"Custom form") + verbose_name_plural = _(u"Custom forms") + ordering = ['name', 'form'] + + class GlobalVar(models.Model, Cached): slug = models.SlugField(_(u"Variable name"), unique=True) description = models.TextField(_(u"Description of the variable"), |