Commit fbf4581e authored by Jérome Perrin's avatar Jérome Perrin

portal_catalog.buildSQLQuery(allowedRolesAndUsers=portal_catalog.getAllowedRolesAndUsers())

is no longer working. Use portal_catalog.buildSQLQuery(query=portal_catalog.getSecurityQuery() instead.



git-svn-id: https://svn.erp5.org/repos/public/erp5/trunk@13304 20353a03-c40f-0410-a6d1-a30d3c3de9de
parent c57bbff1
...@@ -373,7 +373,9 @@ search_result_keys=\'\'</string> </value> ...@@ -373,7 +373,9 @@ search_result_keys=\'\'</string> </value>
</item> </item>
<item> <item>
<key> <string>connection_hook</string> </key> <key> <string>connection_hook</string> </key>
<value> <string></string> </value> <value>
<none/>
</value>
</item> </item>
<item> <item>
<key> <string>connection_id</string> </key> <key> <string>connection_id</string> </key>
...@@ -395,9 +397,8 @@ search_result_keys=\'\'</string> </value> ...@@ -395,9 +397,8 @@ search_result_keys=\'\'</string> </value>
<key> <string>src</string> </key> <key> <string>src</string> </key>
<value> <string encoding="cdata"><![CDATA[ <value> <string encoding="cdata"><![CDATA[
<dtml-let allowed_roles_and_users="portal_catalog.getAllowedRolesAndUsers(**selection_params)">\n <dtml-comment>global stat ignores security (which is not always good, eg when using worklists with local_roles</dtml-comment>\n
<dtml-comment>do something to have a query without RolesAndUsers security for global stats</dtml-comment>\n <dtml-let query="(stat) and portal_catalog.buildSQLQuery(**selection_params) or portal_catalog.buildSQLQuery(query=portal_catalog.getSecurityQuery(), **selection_params)">\n
<dtml-let query="(stat) and portal_catalog.buildSQLQuery(**selection_params) or portal_catalog.buildSQLQuery(allowedRolesAndUsers=allowed_roles_and_users, **selection_params)">\n
<dtml-let search_result_keys="search_result_keys or portal_catalog.getCatalogSearchResultKeys()">\n <dtml-let search_result_keys="search_result_keys or portal_catalog.getCatalogSearchResultKeys()">\n
<dtml-let use_movement_table="from_date or to_date or at_date or resource or stat or amount or amount_range_min or amount_range_max">\n <dtml-let use_movement_table="from_date or to_date or at_date or resource or stat or amount or amount_range_min or amount_range_max">\n
\n \n
...@@ -541,7 +542,7 @@ WHERE\n ...@@ -541,7 +542,7 @@ WHERE\n
<dtml-unless no_limit>LIMIT 1000</dtml-unless>\n <dtml-unless no_limit>LIMIT 1000</dtml-unless>\n
</dtml-if>\n </dtml-if>\n
</dtml-unless>\n </dtml-unless>\n
</dtml-let></dtml-let></dtml-let></dtml-let>\n </dtml-let></dtml-let></dtml-let>\n
<dtml-comment> vim: syntax=dtml\n <dtml-comment> vim: syntax=dtml\n
</dtml-comment>\n </dtml-comment>\n
...@@ -582,9 +583,8 @@ WHERE\n ...@@ -582,9 +583,8 @@ WHERE\n
<key> <string>raw</string> </key> <key> <string>raw</string> </key>
<value> <string encoding="cdata"><![CDATA[ <value> <string encoding="cdata"><![CDATA[
<dtml-let allowed_roles_and_users="portal_catalog.getAllowedRolesAndUsers(**selection_params)">\n <dtml-comment>global stat ignores security (which is not always good, eg when using worklists with local_roles</dtml-comment>\n
<dtml-comment>do something to have a query without RolesAndUsers security for global stats</dtml-comment>\n <dtml-let query="(stat) and portal_catalog.buildSQLQuery(**selection_params) or portal_catalog.buildSQLQuery(query=portal_catalog.getSecurityQuery(), **selection_params)">\n
<dtml-let query="(stat) and portal_catalog.buildSQLQuery(**selection_params) or portal_catalog.buildSQLQuery(allowedRolesAndUsers=allowed_roles_and_users, **selection_params)">\n
<dtml-let search_result_keys="search_result_keys or portal_catalog.getCatalogSearchResultKeys()">\n <dtml-let search_result_keys="search_result_keys or portal_catalog.getCatalogSearchResultKeys()">\n
<dtml-let use_movement_table="from_date or to_date or at_date or resource or stat or amount or amount_range_min or amount_range_max">\n <dtml-let use_movement_table="from_date or to_date or at_date or resource or stat or amount or amount_range_min or amount_range_max">\n
\n \n
...@@ -728,7 +728,7 @@ WHERE\n ...@@ -728,7 +728,7 @@ WHERE\n
<dtml-unless no_limit>LIMIT 1000</dtml-unless>\n <dtml-unless no_limit>LIMIT 1000</dtml-unless>\n
</dtml-if>\n </dtml-if>\n
</dtml-unless>\n </dtml-unless>\n
</dtml-let></dtml-let></dtml-let></dtml-let>\n </dtml-let></dtml-let></dtml-let>\n
<dtml-comment> vim: syntax=dtml\n <dtml-comment> vim: syntax=dtml\n
</dtml-comment>\n </dtml-comment>\n
......
203 205
\ 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