Commit bfbf3dd3 authored by Yusei Tahara's avatar Yusei Tahara

2010-03-31 yusei

* Use "Access contents information" instead of "View" to check if currency can be displayed or not.

git-svn-id: https://svn.erp5.org/repos/public/erp5/trunk@34219 20353a03-c40f-0410-a6d1-a30d3c3de9de
parent c2a483ab
......@@ -53,8 +53,11 @@
</item>
<item>
<key> <string>_body</string> </key>
<value> <string>portal = context.getPortalObject()\n
from ZTUtils import LazyFilter\n
<value> <string>from ZTUtils import LazyFilter\n
from Products.CMFCore.permissions import AccessContentsInformation\n
\n
\n
portal = context.getPortalObject()\n
\n
def getCurrencyItemList(include_empty=1, portal_path=""):\n
result = []\n
......@@ -65,7 +68,7 @@ def getCurrencyItemList(include_empty=1, portal_path=""):\n
portal.restrictedTraverse(\'currency\', None))\n
\n
if currency_module is not None:\n
for currency in LazyFilter(currency_module.contentValues(), skip=\'View\'):\n
for currency in LazyFilter(currency_module.contentValues(), skip=AccessContentsInformation):\n
if not skip_invalidated or \\\n
currency.getProperty(\'validation_state\', \'default\') != \'invalidated\':\n
# for currency, we intentionaly use reference (EUR) not title (Euros).\n
......@@ -121,11 +124,13 @@ return getCurrencyItemList( include_empty=include_empty,\n
<tuple>
<string>include_empty</string>
<string>skip_invalidated</string>
<string>ZTUtils</string>
<string>LazyFilter</string>
<string>Products.CMFCore.permissions</string>
<string>AccessContentsInformation</string>
<string>_getattr_</string>
<string>context</string>
<string>portal</string>
<string>ZTUtils</string>
<string>LazyFilter</string>
<string>getCurrencyItemList</string>
<string>Products.ERP5Type.Cache</string>
<string>CachingMethod</string>
......
2010-03-31 yusei
* Use "Access contents information" instead of "View" to check if currency can be displayed or not.
2010-03-11 yusuke
* Reference generating script comes from erp5_trade.
......
709
\ No newline at end of file
710
\ 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