- Timestamp:
- 12 Aug 2010, 13:20:48 (14 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
main/waeup.sirp/branches/henrik-contactforms/src/waeup/sirp/browser/viewlets.py
r5414 r5427 529 529 return self.view.application_url('faculties') 530 530 531 class SearchTab(PrimaryNavTab): 532 """Search tab in primary navigation. 533 """ 534 grok.order(3) 535 grok.require('waeup.View') 536 grok.template('primarynavtab') 537 538 pnav = 2 539 tab_title = u'Search' 540 541 @property 542 def link_target(self): 543 return self.view.application_url('@@search') 544 531 545 532 class ContactTab(PrimaryNavTab): 546 533 """Contact tab in primary navigation. 547 534 """ 548 535 grok.order(4) 549 grok.require('waeup. Public')536 grok.require('waeup.Anonymous') 550 537 grok.template('primarynavtab') 551 538 552 539 pnav = 3 553 540 def tab_title(self): 554 """Return True if the calling user is authenticated. 541 """Display tab only for anonymous. Authenticated users can call the 542 form from the user navigation bar. 555 543 """ 556 544 userid = self.request.principal.id 557 545 if userid != 'zope.anybody': 558 tt = u' Contact'546 tt = u'' 559 547 else: 560 548 tt = u'Enquiries'
Note: See TracChangeset for help on using the changeset viewer.