diff options
-rwxr-xr-x | roka.py | 3 | ||||
-rw-r--r-- | templates/index.html | 6 |
2 files changed, 8 insertions, 1 deletions
@@ -49,7 +49,8 @@ def list_books(): form = {'WWW-Authenticate': 'Basic realm="o/"'} return Response('unauthorized', 401, form) - return render_template('index.html', books=books) + return render_template('index.html', books=books, + show_path=app.config.get('SHOW_PATH', True)) if __name__ == '__main__': desc = 'roka: listen to audiobooks with podcast apps via RSS' diff --git a/templates/index.html b/templates/index.html index a30577e..a31b763 100644 --- a/templates/index.html +++ b/templates/index.html @@ -29,6 +29,9 @@ <tr> <th>Title</th> <th>Author</th> + {% if show_path %} + <th>Path</th> + {% endif %} <th>Tracks</th> <th>Duration</th> <th>Size</th> @@ -37,6 +40,9 @@ <tr> <td><a href="?a={{ b }}">{{ v['title']|escape }}</a></td> <td>{{ v['author'] }}</td> + {% if show_path %} + <td>{{ v['path']|escape }}</td> + {% endif %} <td>{{ v['files']|length }}</td> <td>{{ v['duration_str'] }}</td> <td>{{ v['size_str'] }}</td> |