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

getAccountReference now receives the account directly


git-svn-id: https://svn.erp5.org/repos/public/erp5/trunk@35064 20353a03-c40f-0410-a6d1-a30d3c3de9de
parent 3ffe39eb
......@@ -77,17 +77,17 @@ else:\n
delivery_list = \\\n
portal_selections.callSelectionFor(selection_name, context=context)\n
\n
\n
account_reference_cache = dict()\n
def getAccountReference(relative_url):\n
def getAccountReference(node):\n
try:\n
return account_reference_cache[relative_url]\n
return account_reference_cache[node]\n
except KeyError:\n
if relative_url:\n
reference = \\\n
portal.restrictedTraverse(relative_url).Account_getGapId()\n
if node is not None:\n
reference = node.Account_getGapId()\n
else:\n
reference = \'\'\n
account_reference_cache[relative_url] = reference\n
account_reference_cache[node] = reference\n
return reference\n
\n
def getTitle(document):\n
......
1209
\ No newline at end of file
1210
\ 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