Changeset 6143 for main/waeup.sirp/trunk/src
- Timestamp:
- 19 May 2011, 13:46:42 (14 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
main/waeup.sirp/trunk/src/waeup/sirp/interfaces.py
r6141 r6143 12 12 from zope import schema 13 13 from zope.schema.vocabulary import SimpleVocabulary, SimpleTerm 14 from waeup.sirp.permissions import RoleSource15 14 16 15 … … 26 25 return SimpleVocabulary([ 27 26 SimpleTerm(value, value, title) for title, value in terms]) 27 28 class RoleSource(BasicSourceFactory): 29 def getValues(self): 30 from waeup.sirp.permissions import getRoles 31 return getRoles() 32 def getTitle(self, value): 33 if isinstance(value, basestring): 34 return value.split('.', 2)[1] 28 35 29 36 class IWAeUPObject(Interface): … … 213 220 """ 214 221 215 def names():222 def roles(): 216 223 """Return a list of role names assignable. 217 224 """
Note: See TracChangeset for help on using the changeset viewer.