Commit 863c31ea authored by Sebastien Robin's avatar Sebastien Robin

give all parameters to the Renderer


git-svn-id: https://svn.erp5.org/repos/public/erp5/trunk@3199 20353a03-c40f-0410-a6d1-a30d3c3de9de
parent 669e6367
...@@ -92,7 +92,7 @@ class Amount(Base, Variated): ...@@ -92,7 +92,7 @@ class Amount(Base, Variated):
'getVariationCategoryItemList') 'getVariationCategoryItemList')
def getVariationCategoryItemList(self, base_category_list=(), base=1, def getVariationCategoryItemList(self, base_category_list=(), base=1,
display_id='title', display_id='title',
current_category=None): current_category=None,**kw):
""" """
Returns the list of possible variations Returns the list of possible variations
XXX Copied and modified from Variated XXX Copied and modified from Variated
...@@ -112,20 +112,18 @@ class Amount(Base, Variated): ...@@ -112,20 +112,18 @@ class Amount(Base, Variated):
if x.getPortalType() == 'Category'] if x.getPortalType() == 'Category']
variation_category_item_list.extend(Renderer( variation_category_item_list.extend(Renderer(
is_right_display=0, is_right_display=0,
display_base_category=1,
display_none_category=0, base=base, display_none_category=0, base=base,
current_category=current_category, current_category=current_category,
display_id='logical_path').\ display_id='logical_path',**kw).\
render(category_list)) render(category_list))
object_list = [x for x in resource_list \ object_list = [x for x in resource_list \
if x.getPortalType() != 'Category'] if x.getPortalType() != 'Category']
variation_category_item_list.extend(Renderer( variation_category_item_list.extend(Renderer(
is_right_display=0, is_right_display=0,
display_base_category=1,
base_category=base_category, base_category=base_category,
display_none_category=0, base=base, display_none_category=0, base=base,
current_category=current_category, current_category=current_category,
display_id=display_id).\ display_id=display_id,**kw).\
render(object_list)) render(object_list))
return variation_category_item_list return variation_category_item_list
......
...@@ -57,6 +57,7 @@ class Transformation(XMLObject, Domain, Variated): ...@@ -57,6 +57,7 @@ class Transformation(XMLObject, Domain, Variated):
Matrixbox must be rewrite for a clean implementation of n base category Matrixbox must be rewrite for a clean implementation of n base category
""" """
isMovement = 1 # XXX very stupid, but for doing a test on catalog
meta_type = 'ERP5 Transformation' meta_type = 'ERP5 Transformation'
portal_type = 'Transformation' portal_type = 'Transformation'
...@@ -208,7 +209,8 @@ class Transformation(XMLObject, Domain, Variated): ...@@ -208,7 +209,8 @@ class Transformation(XMLObject, Domain, Variated):
security.declareProtected(Permissions.AccessContentsInformation, 'getVariationCategoryItemList') security.declareProtected(Permissions.AccessContentsInformation, 'getVariationCategoryItemList')
def getVariationCategoryItemList(self, base_category_list=(), base=1, def getVariationCategoryItemList(self, base_category_list=(), base=1,
display_id='title', display_id='title',
current_category=None): current_category=None,
**kw):
""" """
Returns the list of possible variations Returns the list of possible variations
XXX Copied and modified from Variated XXX Copied and modified from Variated
...@@ -228,20 +230,18 @@ class Transformation(XMLObject, Domain, Variated): ...@@ -228,20 +230,18 @@ class Transformation(XMLObject, Domain, Variated):
if x.getPortalType() == 'Category'] if x.getPortalType() == 'Category']
variation_category_item_list.extend(Renderer( variation_category_item_list.extend(Renderer(
is_right_display=0, is_right_display=0,
display_base_category=1,
display_none_category=0, base=base, display_none_category=0, base=base,
current_category=current_category, current_category=current_category,
display_id='logical_path').\ display_id='logical_path',**kw).\
render(category_list)) render(category_list))
object_list = [x for x in resource_list \ object_list = [x for x in resource_list \
if x.getPortalType() != 'Category'] if x.getPortalType() != 'Category']
variation_category_item_list.extend(Renderer( variation_category_item_list.extend(Renderer(
is_right_display=0, is_right_display=0,
display_base_category=1,
base_category=base_category, base_category=base_category,
display_none_category=0, base=base, display_none_category=0, base=base,
current_category=current_category, current_category=current_category,
display_id=display_id).\ display_id=display_id,**kw).\
render(object_list)) render(object_list))
return variation_category_item_list return variation_category_item_list
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment