from Products.ATContentTypes.content import schemata
from Products.ATContentTypes.configuration import zconf

from ejn.types import typesMessageFactory as _
from ejn.types.vocabs import site_themes
from ejn.types.vocabs import site_regions
from ejn.types.interfaces import IReporterResource
from ejn.types.config import PROJECTNAME

ReporterResourceSchema = schemata.ATContentTypeSchema.copy() + atapi.Schema((
    atapi.TextField(
        'text',
        searchable=1,
        default_output_type='text/x-html-safe',
        widget=atapi.TinyMCEWidget(
            label=_(u'label_story_text', default=u"Story Text"),
            rows=8,
            allow_file_upload=zconf.ATDocument.allow_document_upload,
        ),
    ),
    atapi.ImageField('image',
                     sizes={
                         'large': (768, 768),
                         'preview': (400, 400),
                         'twoeightfive': (285, 285),
                         'mini': (200, 200),
                         'thumb': (128, 128),
                         'tiny': (84, 84),
                         'tile': (64, 64),
                     },
                     widget=atapi.ImageWidget(
Example #2
0
from Products.ATContentTypes.content import base
from Products.ATContentTypes.content import schemata
from Products.ATContentTypes.configuration import zconf

from ejn.types import typesMessageFactory as _
from ejn.types.interfaces import IOpportunity
from ejn.types.config import PROJECTNAME

OpportunitySchema = schemata.ATContentTypeSchema.copy() + atapi.Schema((

    atapi.TextField(
        'text',
        searchable=1,
        default_output_type='text/x-html-safe',
        widget=atapi.TinyMCEWidget(
            label=_(u'label_program_narrative', default=u"Opportunity Narrative"),
            rows=8,
            allow_file_upload=zconf.ATDocument.allow_document_upload,
        ),
    ),

    atapi.StringField(
        'linkURL',
        widget=atapi.StringWidget(
            label=_(u'label_link_URL', default=u"Link URL"),
        ),
    ),

    atapi.ReferenceField('program',
              widget=atapi.SelectionWidget(label='Under Program'),
              allowed_types=('Program'),
from Products.ATContentTypes.content import schemata
from Products.ATContentTypes.configuration import zconf

from ejn.types.vocabs import site_themes
from ejn.types.vocabs import site_regions
from ejn.types import typesMessageFactory as _
from ejn.types.interfaces import IProgramUpdate
from ejn.types.config import PROJECTNAME

ProgramUpdateSchema = schemata.ATContentTypeSchema.copy() + atapi.Schema((
    atapi.TextField(
        'text',
        searchable=1,
        default_output_type='text/x-html-safe',
        widget=atapi.TinyMCEWidget(
            label=_(u'label_program_narrative', default=u"Program Narrative"),
            rows=8,
            allow_file_upload=zconf.ATDocument.allow_document_upload,
        ),
    ),
    atapi.ImageField('image',
                     sizes={
                         'large': (768, 768),
                         'preview': (400, 400),
                         'twoeightfive': (285, 285),
                         'mini': (200, 200),
                         'thumb': (128, 128),
                         'tiny': (84, 84),
                         'tile': (64, 64),
                     },
                     widget=atapi.ImageWidget(
         'icon': (32, 32),
         'listing': (16, 16),
     },
     widget=atapi.ImageWidget(
         description="",
         label="Image",
         label_msgid="label_image",
         i18n_domain="plone",
         show_content_type=False,
     )),
 atapi.TextField(
     'profile',
     searchable=1,
     default_output_type='text/x-html-safe',
     widget=atapi.TinyMCEWidget(
         label=_(u'label_biography_profile', default=u"Biography/Profile"),
         rows=8,
         allow_file_upload=zconf.ATDocument.allow_document_upload,
     ),
 ),
 atapi.LinesField(
     'interests',
     vocabulary=site_themes,
     index='KeywordIndex',
     multiValued=True,
     widget=atapi.MultiSelectionWidget(
         label="Area of Environmental Journalism Interest",
         format='checkbox',
         description="",
     ),
 ),
from Products.ATContentTypes.content import base
from Products.ATContentTypes.content import schemata
from Products.ATContentTypes.configuration import zconf

from ejn.types import typesMessageFactory as _
from ejn.types.vocabs import site_themes
from ejn.types.interfaces import ITheme
from ejn.types.config import PROJECTNAME

ThemeSchema = schemata.ATContentTypeSchema.copy() + atapi.Schema((
    atapi.TextField(
        'text',
        searchable=1,
        default_output_type='text/x-html-safe',
        widget=atapi.TinyMCEWidget(
            label=_(u'label_intro_text', default=u"Intro Text"),
            rows=8,
            allow_file_upload=zconf.ATDocument.allow_document_upload,
        ),
    ),
    atapi.ImageField('image',
                     sizes={
                         'large': (768, 768),
                         'preview': (400, 400),
                         'twoeightfive': (285, 285),
                         'mini': (200, 200),
                         'thumb': (128, 128),
                         'tiny': (84, 84),
                         'tile': (64, 64),
                     },
                     widget=atapi.ImageWidget(