Added sidebar link to Attract projects.
This commit is contained in:
@@ -144,6 +144,14 @@ class AttractExtension(PillarExtension):
|
||||
return False
|
||||
return True
|
||||
|
||||
def sidebar_links(self, project):
|
||||
|
||||
if not self.is_attract_project(project):
|
||||
return ''
|
||||
|
||||
return flask.render_template('attract/sidebar.html',
|
||||
project=project)
|
||||
|
||||
|
||||
def _get_current_attract():
|
||||
"""Returns the Attract extension of the current application."""
|
||||
|
6
src/templates/attract/sidebar.jade
Normal file
6
src/templates/attract/sidebar.jade
Normal file
@@ -0,0 +1,6 @@
|
||||
li.tabs-attract(
|
||||
title="Attract",
|
||||
data-toggle="tooltip",
|
||||
data-placement="left")
|
||||
a(href="{{url_for('attract.project_index', project_url=project.url, _external=True)}}")
|
||||
i.pi-film-thick
|
Reference in New Issue
Block a user