class LoginAlerts(Viewlet): viewletmanager(Top) order(15) context(LoginRoot) layer(DefaultLayer) template = get_template('messages.pt', __file__)
class Alerts(Viewlet): viewletmanager(Top) order(15) context(GateKeeper) layer(DefaultLayer) template = get_template('messages.pt', __file__)
class FlashMessages(uvclight.Viewlet): uvclight.order(2) uvclight.layer(IVBGTheme) uvclight.viewletmanager(managers.IAboveContent) template = uvclight.get_template('flash.cpt', __file__) def update(self): self.messages = [msg.message for msg in receive()]
class ContextualMenuDisplay(Viewlet): viewletmanager(Top) order(20) layer(DefaultLayer) def update(self): self.menu = ContextualActions(self.context, self.request, self.view) self.menu.update() def render(self): return self.menu.render()
class FooterViewlet(MenuViewlet): uvclight.viewletmanager(managers.IFooter) uvclight.layer(IVBGTheme) uvclight.order(20) menu = menus.PersonalMenu template = get_template('footer.cpt') def getFooter(self): menu = menus.FooterMenu(self.context, self.request, self.view) menu.update() return menu.entries
class DocumentActionsViewlet(MenuViewlet): uvclight.viewletmanager(managers.IAboveContent) uvclight.layer(IVBGTheme) uvclight.order(20) template = get_template('documentactionstemplate.cpt') name = u'Aktion' id = u'documentactionsviewlet' def update(self): self.menu = menus.DocumentActionsMenu( self.context, self.request, self.view) self.menu.update()
class NavigationMenuViewlet(MenuViewlet): uvclight.viewletmanager(Navigation) uvclight.layer(IVBGTheme) uvclight.order(30) menu = menus.NavigationMenu template = get_template('navigationtemplate.cpt') id = u'globalmenuviewlet' def getNavigation(self): menu = menus.NavigationMenu(self.context, self.request, self.view) menu.update() return menu.entries def getUser(self): menu = menus.UserMenu(self.context, self.request, self.view) menu.update() return menu.entries def getRenderableItems(self): return list() def getQuicklinks(self): menu = menus.Quicklinks(self.context, self.request, self.view) menu.update() return menu.entries def getPersonal(self): menu = menus.PersonalMenu(self.context, self.request, self.view) menu.update() return menu.entries def isAuth(self): if hasattr(self.request, 'principal'): if self.request.principal.id != 'user.unauthenticated': return True return False
class RGPDCK(uvclight.Viewlet): uvclight.viewletmanager(managers.IAboveContent) uvclight.order(00) uvclight.name('rgpdck') template = uvclight.get_template('rgpdck.cpt', __file__)
class AddMenuViewlet(MenuViewlet): uvclight.viewletmanager(managers.IAboveContent) uvclight.layer(IVBGTheme) uvclight.order(20) menu = menus.AddMenu
class ObjectActionMenuViewlet(MenuViewlet): uvclight.viewletmanager(managers.IAboveContent) uvclight.context(IContent) uvclight.layer(IVBGTheme) uvclight.order(10) menu = menus.ContextualActionsMenu