Commit b7477df4 authored by Kazuhiko Shiozaki's avatar Kazuhiko Shiozaki

use selection_name instead of selection.


git-svn-id: https://svn.erp5.org/repos/public/erp5/trunk@13744 20353a03-c40f-0410-a6d1-a30d3c3de9de
parent f0e7b7dc
...@@ -73,7 +73,8 @@ ...@@ -73,7 +73,8 @@
from DateTime import DateTime\n from DateTime import DateTime\n
from Products.ERP5Type.Document import newTempBase\n from Products.ERP5Type.Document import newTempBase\n
\n \n
selection_params = selection.getParams()\n portal = context.getPortalObject()\n
selection_params = portal.portal_selections.getSelectionParamsFor(selection_name)\n
get_inventory_kw = {\n get_inventory_kw = {\n
\'section_category\': selection_params.get(\'section_category\')\n \'section_category\': selection_params.get(\'section_category\')\n
, \'simulation_state\': selection_params.get(\'simulation_state\')\n , \'simulation_state\': selection_params.get(\'simulation_state\')\n
...@@ -85,7 +86,6 @@ get_inventory_kw = {\n ...@@ -85,7 +86,6 @@ get_inventory_kw = {\n
at_date = selection_params.get(\'at_date\', None)\n at_date = selection_params.get(\'at_date\', None)\n
from_date = selection_params.get(\'from_date\', None)\n from_date = selection_params.get(\'from_date\', None)\n
\n \n
portal = context.getPortalObject()\n
getInventory = portal.portal_simulation.getInventoryAssetPrice\n getInventory = portal.portal_simulation.getInventoryAssetPrice\n
\n \n
# FIXME: Here we do not want to sum all movement < 0, but sum the balances\n # FIXME: Here we do not want to sum all movement < 0, but sum the balances\n
...@@ -140,7 +140,7 @@ return [list_item]\n ...@@ -140,7 +140,7 @@ return [list_item]\n
</item> </item>
<item> <item>
<key> <string>_params</string> </key> <key> <string>_params</string> </key>
<value> <string>selection, **kw</string> </value> <value> <string>selection, selection_name, **kw</string> </value>
</item> </item>
<item> <item>
<key> <string>errors</string> </key> <key> <string>errors</string> </key>
...@@ -160,26 +160,27 @@ return [list_item]\n ...@@ -160,26 +160,27 @@ return [list_item]\n
<dictionary> <dictionary>
<item> <item>
<key> <string>co_argcount</string> </key> <key> <string>co_argcount</string> </key>
<value> <int>1</int> </value> <value> <int>2</int> </value>
</item> </item>
<item> <item>
<key> <string>co_varnames</string> </key> <key> <string>co_varnames</string> </key>
<value> <value>
<tuple> <tuple>
<string>selection</string> <string>selection</string>
<string>selection_name</string>
<string>kw</string> <string>kw</string>
<string>DateTime</string> <string>DateTime</string>
<string>Products.ERP5Type.Document</string> <string>Products.ERP5Type.Document</string>
<string>newTempBase</string> <string>newTempBase</string>
<string>_getattr_</string> <string>_getattr_</string>
<string>context</string>
<string>portal</string>
<string>selection_params</string> <string>selection_params</string>
<string>True</string> <string>True</string>
<string>get_inventory_kw</string> <string>get_inventory_kw</string>
<string>None</string> <string>None</string>
<string>at_date</string> <string>at_date</string>
<string>from_date</string> <string>from_date</string>
<string>context</string>
<string>portal</string>
<string>getInventory</string> <string>getInventory</string>
<string>opening_debit_balance</string> <string>opening_debit_balance</string>
<string>opening_credit_balance</string> <string>opening_credit_balance</string>
......
...@@ -68,7 +68,7 @@ ...@@ -68,7 +68,7 @@
</item> </item>
<item> <item>
<key> <string>_body</string> </key> <key> <string>_body</string> </key>
<value> <string>return - context.AccountModule_statBalance(brain, selection, omit_input=1, **kw) or 0\n <value> <string>return - context.AccountModule_statBalance(brain=brain, selection_name=selection_name, omit_input=1, **kw) or 0\n
</string> </value> </string> </value>
</item> </item>
<item> <item>
...@@ -85,7 +85,7 @@ ...@@ -85,7 +85,7 @@
</item> </item>
<item> <item>
<key> <string>_params</string> </key> <key> <string>_params</string> </key>
<value> <string>selection, brain=None, **kw</string> </value> <value> <string>selection, brain=None, selection_name=None, **kw</string> </value>
</item> </item>
<item> <item>
<key> <string>errors</string> </key> <key> <string>errors</string> </key>
...@@ -105,7 +105,7 @@ ...@@ -105,7 +105,7 @@
<dictionary> <dictionary>
<item> <item>
<key> <string>co_argcount</string> </key> <key> <string>co_argcount</string> </key>
<value> <int>2</int> </value> <value> <int>3</int> </value>
</item> </item>
<item> <item>
<key> <string>co_varnames</string> </key> <key> <string>co_varnames</string> </key>
...@@ -113,6 +113,7 @@ ...@@ -113,6 +113,7 @@
<tuple> <tuple>
<string>selection</string> <string>selection</string>
<string>brain</string> <string>brain</string>
<string>selection_name</string>
<string>kw</string> <string>kw</string>
<string>_apply_</string> <string>_apply_</string>
<string>_getattr_</string> <string>_getattr_</string>
......
...@@ -68,7 +68,7 @@ ...@@ -68,7 +68,7 @@
</item> </item>
<item> <item>
<key> <string>_body</string> </key> <key> <string>_body</string> </key>
<value> <string>return context.AccountModule_statBalance(brain, selection, omit_output=1, float_value=1, **kw)\n <value> <string>return context.AccountModule_statBalance(brain=brain, selection_name=selection_name, omit_output=1, float_value=1, **kw)\n
</string> </value> </string> </value>
</item> </item>
<item> <item>
...@@ -85,7 +85,7 @@ ...@@ -85,7 +85,7 @@
</item> </item>
<item> <item>
<key> <string>_params</string> </key> <key> <string>_params</string> </key>
<value> <string>selection, brain=None, **kw</string> </value> <value> <string>selection, brain=None, selection_name=None, **kw</string> </value>
</item> </item>
<item> <item>
<key> <string>errors</string> </key> <key> <string>errors</string> </key>
...@@ -105,7 +105,7 @@ ...@@ -105,7 +105,7 @@
<dictionary> <dictionary>
<item> <item>
<key> <string>co_argcount</string> </key> <key> <string>co_argcount</string> </key>
<value> <int>2</int> </value> <value> <int>3</int> </value>
</item> </item>
<item> <item>
<key> <string>co_varnames</string> </key> <key> <string>co_varnames</string> </key>
...@@ -113,6 +113,7 @@ ...@@ -113,6 +113,7 @@
<tuple> <tuple>
<string>selection</string> <string>selection</string>
<string>brain</string> <string>brain</string>
<string>selection_name</string>
<string>kw</string> <string>kw</string>
<string>_apply_</string> <string>_apply_</string>
<string>_getattr_</string> <string>_getattr_</string>
......
229 230
\ 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