Commit 998623bd authored by Jean-Paul Smets's avatar Jean-Paul Smets

Use checked_permission to take into account security and access rights.

git-svn-id: https://svn.erp5.org/repos/public/erp5/trunk@16553 20353a03-c40f-0410-a6d1-a30d3c3de9de
parent f2b0c49a
......@@ -73,7 +73,7 @@
This script is used to generate the memus.\n
"""\n
site = context.getWebSiteValue()\n
section_list = site.objectValues(portal_type = \'Web Section\', sort_on=\'int_index\')\n
section_list = site.contentValues(portal_type=\'Web Section\', sort_on=\'int_index\', checked_permission=\'View\')\n
return filter(lambda x: x.isVisible(), section_list)\n
</string> </value>
</item>
......
......@@ -101,7 +101,8 @@ Description:\n
</div>\n
\n
<div class="tabbertab"\n
tal:define="section_list python:here.contentValues(portal_type=\'Web Section\', sort_on=\'int_index\');\n
tal:define="section_list python:here.contentValues(portal_type=\'Web Section\',\n
checked_permission=\'View\',sort_on=\'int_index\');\n
section_list python:filter(lambda x:x.isVisible(), section_list);\n
half_count python:len(section_list) / 2">\n
<h2 value="" i18n:translate="" i18n:domain="ui">Browse</h2>\n
......@@ -112,7 +113,7 @@ Description:\n
<li value="" i18n:translate=""\n
i18n:domain="ui" tal:content="section/getTitle">Departments and Divisions:</li>\n
<ul>\n
<li tal:repeat="root_section section/contentValues">\n
<li tal:repeat="root_section python:section.contentValues(checked_permission=\'View\')">\n
<a tal:content="root_section/getTitle"\n
tal:condition="python:not len(root_section.contentValues())"\n
tal:attributes="href root_section/absolute_url"/>\n
......
590
\ No newline at end of file
591
\ 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