Commit ec33464b authored by Vincent Pelletier's avatar Vincent Pelletier

Set a manager proxy role.

Allows using this script in multi-site reports.

git-svn-id: https://svn.erp5.org/repos/public/erp5/trunk@45570 20353a03-c40f-0410-a6d1-a30d3c3de9de
parent 40d99195
...@@ -50,19 +50,24 @@ ...@@ -50,19 +50,24 @@
</item> </item>
<item> <item>
<key> <string>_body</string> </key> <key> <string>_body</string> </key>
<value> <string>if isinstance(site, str):\n <value> <string>portal = context.getPortalObject()\n
site = context.portal_categories.site.restrictedTraverse(site)\n if isinstance(site, str):\n
\n site = portal.portal_categories.site.restrictedTraverse(site)\n
orga_id = "site_%3s" %(site.getCodification())\n return portal.organisation_module["site_%3s" % (site.getCodification(), )]\n
org = context.organisation_module[orga_id]\n
\n
return org\n
</string> </value> </string> </value>
</item> </item>
<item> <item>
<key> <string>_params</string> </key> <key> <string>_params</string> </key>
<value> <string>site</string> </value> <value> <string>site</string> </value>
</item> </item>
<item>
<key> <string>_proxy_roles</string> </key>
<value>
<tuple>
<string>Manager</string>
</tuple>
</value>
</item>
<item> <item>
<key> <string>id</string> </key> <key> <string>id</string> </key>
<value> <string>Baobab_getAgencyForSite</string> </value> <value> <string>Baobab_getAgencyForSite</string> </value>
......
571 574
\ 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