Generated: Wed 2013-03-13 10:33 CET
Source file: /media/Envs/Envs/filer-gallery/lib/python2.7/site-packages/cms/plugins/teaser/models.py
Stats: 0 executed, 7 missed, 5 excluded, 13 ignored
from django.db import modelsfrom django.utils.translation import ugettext_lazy as _from cms.models import CMSPlugin, Pageclass Teaser(CMSPlugin): """ A Teaser """ title = models.CharField(_("title"), max_length=255) image = models.ImageField(_("image"), upload_to=CMSPlugin.get_media_path, blank=True, null=True) page_link = models.ForeignKey( Page, verbose_name=_("page"), help_text=_("If present image will be clickable"), blank=True, null=True, limit_choices_to={'publisher_is_draft': True} ) url = models.CharField(_("link"), max_length=255, blank=True, null=True, help_text=_("If present image will be clickable.")) description = models.TextField(_("description"), blank=True, null=True) def __unicode__(self): return self.title search_fields = ('description',)