Changeset 2404 in products


Ignore:
Timestamp:
May 31, 2010 1:20:46 PM (9 years ago)
Author:
mylan
Message:

#131: use default plone.app.vocabularies.ReallyUserFriendlyTypes? vocabulary for list allowable portal tyeps. Create new portal types vocabulary sceleton for associate portal type name to it's type-interface

Location:
quintagroup.plonegooglesitemaps/trunk/quintagroup/plonegooglesitemaps/content
Files:
1 added
2 edited

Legend:

Unmodified
Added
Removed
  • quintagroup.plonegooglesitemaps/trunk/quintagroup/plonegooglesitemaps/content/configure.zcml

    r1593 r2404  
    2121    </class> 
    2222 
     23    <utility 
     24      component=".vocabularies.TypesWithInterfaceVocabularyFactory" 
     25      name="googlesitemaps.vocabularies.TypesWithInterfaceVocabulary" 
     26      /> 
     27 
    2328</configure> 
  • quintagroup.plonegooglesitemaps/trunk/quintagroup/plonegooglesitemaps/content/sitemap.py

    r1593 r2404  
    3333        required=True, 
    3434        default=['Document',], 
    35         vocabulary="availablePortalTypes", 
     35        vocabulary_factory="plone.app.vocabularies.ReallyUserFriendlyTypes", 
    3636        #schemata ='default', 
    3737        widget=atapi.MultiSelectionWidget( 
    3838            label=_(u"Define the types"), 
    39             description=_(u"Define the types to be included in sitemap."), 
     39            description=_(u"Define the types to be included in sitemap. " \ 
     40                "All listed types automaticall will be extended with " \ 
     41                "additional fields, if its applicable."), 
    4042        ), 
    4143    ), 
     
    135137        self._setProperty('layout', default_layout) 
    136138 
    137     def availablePortalTypes(self): 
    138         pt = getToolByName(self, 'portal_types') 
    139         types = pt.listContentTypes() 
    140         return atapi.DisplayList(zip(types,types)) 
     139    # def setPortalTypes(self): 
     140    #     pt = getToolByName(self, 'portal_types') 
     141    #     types = pt.listContentTypes() 
     142    #     return atapi.DisplayList(zip(types,types)) 
    141143 
    142144    def getWorkflowStates(self): 
Note: See TracChangeset for help on using the changeset viewer.