Merge pull request #34 from nephila/feature/fix_toolbar

Temporary disable the current_app check due to a bug in django CMS 3.0.3
This commit is contained in:
Iacopo Spalletti 2014-07-23 08:09:52 +02:00
commit 67c4eaa16b

View file

@ -12,7 +12,8 @@ from .models import BLOG_CURRENT_POST_IDENTIFIER
class BlogToolbar(CMSToolbar): class BlogToolbar(CMSToolbar):
def populate(self): def populate(self):
if not (self.is_current_app and self.request.user.has_perm('djangocms_blog.add_post')): # TODO: Readd if not self.is_current_app condition when CMS 3.0.4 is released
if not self.request.user.has_perm('djangocms_blog.add_post'):
return # pragma: no cover return # pragma: no cover
admin_menu = self.toolbar.get_or_create_menu("djangocms_blog", _('Blog')) admin_menu = self.toolbar.get_or_create_menu("djangocms_blog", _('Blog'))
url = reverse('admin:djangocms_blog_post_changelist') url = reverse('admin:djangocms_blog_post_changelist')