Commit 0c987466 authored by Jérome Perrin's avatar Jérome Perrin

simplify scripts

git-svn-id: https://svn.erp5.org/repos/public/erp5/trunk@39047 20353a03-c40f-0410-a6d1-a30d3c3de9de
parent ff65fe8d
......@@ -50,16 +50,10 @@
</item>
<item>
<key> <string>_body</string> </key>
<value> <string>"""\n
Script used to get the exchange ratio used \n
in the conversion of the destination price\n
"""\n
\n
currency = context.getResourceValue()\n
exchange_ratio = currency.getPrice(context=context.asContext(categories=[\'resource/%s\' % context.getResource(), \n
\'price_currency/currency_module/%s\' % context.getDestinationSectionValue().getPriceCurrencyId()],\n
<value> <string>return context.getResourceValue().getPrice(\n
context=context.asContext(categories=[context.getResource(base=True),\n
context.getDestinationSectionValue().getPriceCurrency(base=True)],\n
start_date=context.getStopDate()))\n
return exchange_ratio\n
</string> </value>
</item>
<item>
......@@ -98,8 +92,7 @@ return exchange_ratio\n
<tuple>
<string>_getattr_</string>
<string>context</string>
<string>currency</string>
<string>exchange_ratio</string>
<string>True</string>
</tuple>
</value>
</item>
......
......@@ -50,11 +50,10 @@
</item>
<item>
<key> <string>_body</string> </key>
<value> <string>currency = context.getResourceValue()\n
exchange_ratio = currency.getPrice(context=context.asContext(categories=[\'resource/%s\' % context.getResource(), \n
\'price_currency/currency_module/%s\' % context.getSourceSectionValue().getPriceCurrencyId()],\n
<value> <string>return context.getResourceValue().getPrice(\n
context=context.asContext(categories=[context.getResource(base=True),\n
context.getSourceSectionValue().getPriceCurrency(base=True)],\n
start_date=context.getStartDate()))\n
return exchange_ratio\n
</string> </value>
</item>
<item>
......@@ -93,8 +92,7 @@ return exchange_ratio\n
<tuple>
<string>_getattr_</string>
<string>context</string>
<string>currency</string>
<string>exchange_ratio</string>
<string>True</string>
</tuple>
</value>
</item>
......
1368
\ No newline at end of file
1369
\ 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