Ignore:
Timestamp:
6 Nov 2011, 17:18:51 (13 years ago)
Author:
Henrik Bettermann
Message:

Define target method for breadcrumbs. We can't use the viewname attribute.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • main/waeup.sirp/trunk/src/waeup/sirp/browser/interfaces.py

    r5957 r7008  
    99    ICourseContainer, ICourse, ICourseAdd, ICertificateContainer,
    1010    ICertificate, ICertificateAdd, ICertificateCourse, ICertificateCourseAdd)
     11
    1112class IBreadcrumb(Interface):
    1213    """Provide breadcrumbs.
    1314    """
    14     title = schema.TextLine(
    15         title = u'Context description',
    16         readonly = True,
    17         )
    18     viewname = schema.TextLine(
    19         title = u'The viewname, for which the breadcrumb is provided.',
    20         readonly = True,
    21         default = u'index'
    22         )
    23     parent_viewname = schema.TextLine(
    24         title = u'The viewname of the parent to use.',
    25         readonly = True,
    26         default = u'index'
    27         )
     15    title = Attribute("Context description")
     16    viewname = Attribute("The viewname, for which the breadcrumb is provided.")
     17    parent_viewname = Attribute("The viewname of the parent to use.")
    2818    parent = Attribute("The parent object.")
    2919    context = Attribute("The context of the breadcrumb.")
    30 
    31 
    32     def getURL(view=None):
    33         """Return a URL to the breadcrumb target.
    34         """
     20    target = Attribute("The link target.")
    3521
    3622class IBreadcrumbIgnorable(Interface):
Note: See TracChangeset for help on using the changeset viewer.