Permalink
Browse files

added ability to change CategoriesPortlet attr from templatetag

  • Loading branch information...
1 parent 8d3a4ce commit b6640acb243eb2333b084fa05333dfec9698e692 @suvit suvit committed Jul 16, 2012
Showing with 4 additions and 1 deletion.
  1. +4 −1 lfs/portlet/templatetags/lfs_portlets_tags.py
@@ -100,14 +100,17 @@ def lfs_cart_portlet(context, title=None):
@register.inclusion_tag('lfs/portlets/portlet.html', takes_context=True)
-def lfs_categories_portlet(context, title=None):
+def lfs_categories_portlet(context, title=None,
+ start_level=1, expand_level=1):
"""Tag to render the related products portlet.
"""
if title is None:
title = _(u"Categories")
portlet = CategoriesPortlet()
portlet.title = title
+ portlet.start_level = start_level
+ portlet.expand_level = expand_level
return {
"html": portlet.render(context)

0 comments on commit b6640ac

Please sign in to comment.