Commit 72dac873 authored by Jonathan Loriette's avatar Jonathan Loriette

test if selection is Null for zoom creation


git-svn-id: https://svn.erp5.org/repos/public/erp5/trunk@3356 20353a03-c40f-0410-a6d1-a30d3c3de9de
parent 4051fded
......@@ -800,7 +800,10 @@ class PlanningBoxWidget(Widget.Widget):
selection.edit(sort_on = sort)
here.portal_selections.setSelectionFor(selection_name, selection, REQUEST=REQUEST)
# we check what is the current zoom in order to redefine height & width
current_zoom = selection.getZoom()
if selection is None:
current_zoom = 1
else:
current_zoom = selection.getZoom()
current_zoom= float(current_zoom)
if current_zoom<=1:
height_global_div = round(height_global_div * current_zoom)
......
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