Conjunto de mudanças 6104 no repositório publico


Ignorar:
Timestamp:
29/02/2012 19:06:53 (8 anos atrás)
Autor:
davilima6
Mensagem:

pep8

Arquivo:
1 editado

Legenda:

Não Modificado
Adicionado
Removido
  • PortalInterlegis/produtos/il.portal.theme/trunk/il/portal/theme/browser/tile.py

    r6084 r6104  
    11# -*- coding: utf-8 -*-
    22from zope.interface import Interface
     3from zope.schema import Text, Choice, List
    34from z3c.form import form, field
     5
    46from plone.z3cform import layout
    57from plone import tiles
    6 from zope.schema import Text
     8
     9from z3c.relationfield.schema import RelationChoice
     10from z3c.relationfield.schema import RelationList
     11
    712from plone.app.textfield import RichText
    813from plone.app.textfield.interfaces import ITransformer
    914
    10 from z3c.relationfield.schema import RelationChoice, RelationList
    11 
    12 from plone.formwidget.autocomplete.widget import (
    13     AutocompleteMultiFieldWidget,
    14     )
    15 from plone.formwidget.contenttree import (
    16     ContentTreeFieldWidget,
    17     ObjPathSourceBinder,
    18     )
     15from plone.formwidget.autocomplete.widget import AutocompleteMultiFieldWidget
     16from plone.formwidget.contenttree import ContentTreeFieldWidget, ObjPathSourceBinder
     17from plone.formwidget.contenttree import PathSourceBinder
    1918
    2019
    2120class IRichTextTileData(Interface):
    22    
    2321    text = RichText(title=u'Text')
     22
    2423
    2524class RichTextTile(tiles.PersistentTile):
     
    3332        return '<html><body>%s</body></html>' % text
    3433
     34
    3535class IPlainTextTileData(Interface):
    36    
     36
    3737    text = Text(title=u"Text")
    38    
     38
     39
    3940class PlainTextTile(tiles.PersistentTile):
    4041
     
    4546        return '<html><body>%s</body></html>' % text
    4647
     48
    4749class IRelatedItensTileData(Interface):
    48    
     50
    4951    related_itens = RelationChoice(title=u"Escolha o item relacionado",
    5052                       required=False,
    5153                       source=ObjPathSourceBinder())
    52    
     54
    5355    #import pdb;pdb.set_trace()
    54    
     56
     57
    5558class RelatedForm(form.EditForm):
    5659    fields = field.Fields(IRelatedItensTileData)
    5760    fields['related_itens'].widgetFactory = ContentTreeFieldWidget
    58    
     61
    5962RelatedView = layout.wrap_form(RelatedForm)
     63
    6064
    6165class RelatedItensTile(tiles.PersistentTile):
     
    6670            relateditens = self.data['related_itens']
    6771        return '<html><body>%s</body></html>' % relateditens
    68    
Note: Veja TracChangeset para ajuda no uso do visualizador de conjunto de mudanças.
 

The contents and data of this website are published under license:
Creative Commons 4.0 Brasil - Atribuir Fonte - Compartilhar Igual.