Mercurial > piecrust2
diff foodtruck/views/menu.py @ 772:3885421c29a3
admin: Make the whole FoodTruck site into a blueprint.
This makes it possible to use an app factory, which makes it easier to write
unit tests.
author | Ludovic Chabant <ludovic@chabant.com> |
---|---|
date | Sun, 03 Jul 2016 07:54:54 -0700 |
parents | efc1dc916e7c |
children |
line wrap: on
line diff
--- a/foodtruck/views/menu.py Sun Jul 03 07:53:17 2016 -0700 +++ b/foodtruck/views/menu.py Sun Jul 03 07:54:54 2016 -0700 @@ -20,8 +20,8 @@ elif 'blog' in s.name: source_icon = 'filing' - url_write = url_for('write_page', source_name=s.name) - url_listall = url_for('list_source', source_name=s.name) + url_write = url_for('.write_page', source_name=s.name) + url_listall = url_for('.list_source', source_name=s.name) ctx = { 'url': url_listall, @@ -35,12 +35,12 @@ entries.append(ctx) entries.append({ - 'url': url_for('publish'), + 'url': url_for('.publish'), 'title': "Publish", 'icon': 'upload'}) # entries.append({ - # 'url': url_for('settings'), + # 'url': url_for('.settings'), # 'title': "Settings", # 'icon': 'gear-b'}) @@ -62,7 +62,7 @@ data = {'entries': entries, 'user': current_user, - 'url_logout': url_for('logout')} + 'url_logout': url_for('.logout')} return data