Commit 454e0fa4 authored by Jérome Perrin's avatar Jérome Perrin

don't fail if there are no print action defined

git-svn-id: https://svn.erp5.org/repos/public/erp5/trunk@18023 20353a03-c40f-0410-a6d1-a30d3c3de9de
parent 41063b6e
......@@ -73,7 +73,8 @@ new_print_action_list = context.Base_fixDialogActions(\n
context.Base_filterDuplicateActions(\n
context.portal_actions.listFilteredActionsFor(context)), \'object_print\')\n
\n
return context.ERP5Site_redirect(new_print_action_list[0][\'url\'],\n
if new_print_action_list:\n
return context.ERP5Site_redirect(new_print_action_list[0][\'url\'],\n
keep_items={\'form_id\': form_id,\n
\'cancel_url\': cancel_url,\n
\'dialog_category\': \'object_print\'}, **kw)\n
......
454
\ No newline at end of file
455
\ No newline at end of file
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