Skip to content

Commit

Permalink
menu is a more appropriate way to call the folder rather than items
Browse files Browse the repository at this point in the history
  • Loading branch information
Angelo Dini committed Jan 18, 2013
1 parent 1bc0d2a commit 7a31036
Show file tree
Hide file tree
Showing 5 changed files with 6 additions and 6 deletions.
File renamed without changes.
File renamed without changes.
File renamed without changes.
4 changes: 2 additions & 2 deletions cms/tests/toolbar.py
Original file line number Diff line number Diff line change
Expand Up @@ -62,7 +62,7 @@ def test_toolbar_no_page_anon(self):
# check the login form is there
login = items[1]
self.assertTrue(isinstance(login, TemplateHTML))
self.assertEqual(login.template, 'cms/toolbar/items/login.html')
self.assertEqual(login.template, 'cms/toolbar/menu/login.html')

def test_toolbar_no_page_staff(self):
request = self.request_factory.get('/')
Expand Down Expand Up @@ -141,7 +141,7 @@ def test_toolbar_anon(self):
# check the login form is there
login = items[1]
self.assertTrue(isinstance(login, TemplateHTML))
self.assertEqual(login.template, 'cms/toolbar/items/login.html')
self.assertEqual(login.template, 'cms/toolbar/menu/login.html')

def test_toolbar_staff(self):
page = create_page('test', 'nav_playground.html', 'en', published=True)
Expand Down
8 changes: 4 additions & 4 deletions cms/toolbar/items.py
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ def get_context(self):
return {}

class List(BaseItem):
template = "cms/toolbar/items/list.html"
template = "cms/toolbar/menu/list.html"
def __init__(self, url, name):
self.items = []
self.url = url
Expand All @@ -19,7 +19,7 @@ def get_context(self):
return {'items':self.items, 'url':self.url, 'title':self.name}

class Item(BaseItem):
template = "cms/toolbar/items/item.html"
template = "cms/toolbar/menu/item.html"

def __init__(self, url, title, load_side_frame=False, ajax=False, active=False, question=""):
if load_side_frame and ajax:
Expand All @@ -44,10 +44,10 @@ def get_context(self):


class Break(BaseItem):
template = "cms/toolbar/items/break.html"
template = "cms/toolbar/menu/break.html"

class Dialog(BaseItem):
template = "cms/toolbar/items/dialog.html"
template = "cms/toolbar/menu/dialog.html"

def __init__(self, url, title, question):
self.url = url
Expand Down

0 comments on commit 7a31036

Please sign in to comment.