def leftnav_actions(self, current=None): ''' Returns the html for the leftnav @param current: a string of the current action that will be highlighted ''' actions = ('Add Host',) action_links = ('/hosts/add',) return submenu(values=actions, links=action_links, title="Actions", selected=current)
def leftnav_actions(self, current=None): '''Returns the html for actions in the leftnav @param current: a string of the current action''' selected = None counter = 0 actions = ('Add Domain',) action_links = ('/domains/add',) # Run through our actions list and highlight the currently selected action for action in actions: if action == current: selected = counter counter += 1 return submenu(actions, action_links, "Actions", selected)
def leftnav_actions(self, current=None): '''Returns the html for actions in the leftnav @param current: a string of the current action''' selected = None counter = 0 actions = ('Add Domain', ) action_links = ('/dns/add', ) # Run through our actions list and highlight the currently selected action for action in actions: if action == current: selected = counter counter += 1 return submenu(actions, action_links, "Actions", selected)