Commit 3b4d8fd0 authored by Gabriel Monnerat's avatar Gabriel Monnerat

use local_roles to get object only with Owner permission because with manager...

use local_roles to get object only with Owner permission because with manager user he can get a wrong knowledge pad

git-svn-id: https://svn.erp5.org/repos/public/erp5/trunk@45447 20353a03-c40f-0410-a6d1-a30d3c3de9de
parent b6ecd3e6
...@@ -59,7 +59,8 @@ if not gadget_id_list:\n ...@@ -59,7 +59,8 @@ if not gadget_id_list:\n
gadget_id_list = gadget_id_list.split(",")\n gadget_id_list = gadget_id_list.split(",")\n
knowledge_pad = portal_catalog.getResultValue(portal_type="Knowledge Pad",\n knowledge_pad = portal_catalog.getResultValue(portal_type="Knowledge Pad",\n
publication_section_uid=context.getUid(),\n publication_section_uid=context.getUid(),\n
validation_state=["visible", "public"])\n validation_state=["visible", "public"],\n
local_roles="Owner")\n
\n \n
for gadget_id in gadget_id_list:\n for gadget_id in gadget_id_list:\n
knowledge_box = knowledge_pad.newContent(portal_type="Knowledge Box")\n knowledge_box = knowledge_pad.newContent(portal_type="Knowledge Box")\n
......
354 355
\ No newline at end of file \ 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