Commit ab79fac6 authored by Vincent Pelletier's avatar Vincent Pelletier

Add tile and target amount on fast input form.

git-svn-id: https://svn.erp5.org/repos/public/erp5/trunk@16144 20353a03-c40f-0410-a6d1-a30d3c3de9de
parent 14a3997b
...@@ -88,6 +88,12 @@ if listbox is None:\n ...@@ -88,6 +88,12 @@ if listbox is None:\n
read_only = cash_detail_dict[\'read_only\']\n read_only = cash_detail_dict[\'read_only\']\n
currency_cash_portal_type = cash_detail_dict[\'currency_cash_portal_type\']\n currency_cash_portal_type = cash_detail_dict[\'currency_cash_portal_type\']\n
\n \n
if fast_input_title is None:\n
fast_input_title = \'%s - %s\' % (context.getParentValue().getTranslatedTitle(), context.getSourceReference())\n
if \'target_total_price\' not in kw:\n
target_total_price = context.getSourceTotalAssetPrice()\n
else:\n
target_total_price = kw.pop(\'target_total_price\')\n
\n \n
# If use_inventory is passed, use that value. Otherwise, assume False.\n # If use_inventory is passed, use that value. Otherwise, assume False.\n
# use_inventory = cash_detail_dict.get(\'use_inventory\', False)\n # use_inventory = cash_detail_dict.get(\'use_inventory\', False)\n
...@@ -333,7 +339,7 @@ if listbox is None:\n ...@@ -333,7 +339,7 @@ if listbox is None:\n
currency_dict[\'column%d\' % (counter + 1)] = 0\n currency_dict[\'column%d\' % (counter + 1)] = 0\n
listbox.append(currency_dict)\n listbox.append(currency_dict)\n
\n \n
other_parameter_list = (operation_currency, line_portal_type, read_only, column_base_category, use_inventory)\n other_parameter_list = (operation_currency, line_portal_type, read_only, column_base_category, use_inventory, fast_input_title, target_total_price)\n
context.Base_updateDialogForm(listbox=listbox\n context.Base_updateDialogForm(listbox=listbox\n
, calculated_price=total_price\n , calculated_price=total_price\n
, empty_line_number=0\n , empty_line_number=0\n
...@@ -341,6 +347,8 @@ if listbox is None:\n ...@@ -341,6 +347,8 @@ if listbox is None:\n
, emission_letter_list = emission_letter_list\n , emission_letter_list = emission_letter_list\n
, variation_list = variation_list\n , variation_list = variation_list\n
, other_parameter = other_parameter_list\n , other_parameter = other_parameter_list\n
, fast_input_title=fast_input_title\n
, target_total_price=target_total_price\n
, )\n , )\n
\n \n
return context.asContext( context=None\n return context.asContext( context=None\n
...@@ -350,6 +358,8 @@ if listbox is None:\n ...@@ -350,6 +358,8 @@ if listbox is None:\n
, emission_letter_list = emission_letter_list\n , emission_letter_list = emission_letter_list\n
, variation_list = variation_list\n , variation_list = variation_list\n
, other_parameter = other_parameter_list\n , other_parameter = other_parameter_list\n
, fast_input_title=fast_input_title\n
, target_total_price=target_total_price\n
).CashDetail_viewLineFastInputForm(**kw)\n ).CashDetail_viewLineFastInputForm(**kw)\n
\n \n
\n \n
...@@ -365,6 +375,8 @@ else :\n ...@@ -365,6 +375,8 @@ else :\n
read_only = other_parameter[2]\n read_only = other_parameter[2]\n
column_base_category = other_parameter[3]\n column_base_category = other_parameter[3]\n
use_inventory = other_parameter[4]\n use_inventory = other_parameter[4]\n
fast_input_title = other_parameter[5]\n
target_total_price = other_parameter[6]\n
\n \n
# we don\'t update anything in read only mode\n # we don\'t update anything in read only mode\n
if read_only == "True":\n if read_only == "True":\n
...@@ -439,11 +451,15 @@ else :\n ...@@ -439,11 +451,15 @@ else :\n
listbox = new_line_list\n listbox = new_line_list\n
context.Base_updateDialogForm( listbox=listbox\n context.Base_updateDialogForm( listbox=listbox\n
, calculated_price=total_price\n , calculated_price=total_price\n
, empty_line_number=0)\n , empty_line_number=0\n
, fast_input_title=fast_input_title\n
, target_total_price=target_total_price)\n
\n \n
return context.asContext( context=None\n return context.asContext( context=None\n
, portal_type=context.getPortalType()\n , portal_type=context.getPortalType()\n
, calculated_price=total_price\n , calculated_price=total_price\n
, fast_input_title=fast_input_title\n
, target_total_price=target_total_price\n
,**kw\n ,**kw\n
).CashDetail_viewLineFastInputForm(**kw)\n ).CashDetail_viewLineFastInputForm(**kw)\n
...@@ -470,7 +486,7 @@ else :\n ...@@ -470,7 +486,7 @@ else :\n
</item> </item>
<item> <item>
<key> <string>_params</string> </key> <key> <string>_params</string> </key>
<value> <string>listbox=None,cash_detail_dict=None, rendering_vault=None, **kw</string> </value> <value> <string>listbox=None,cash_detail_dict=None, rendering_vault=None, fast_input_title=None, **kw</string> </value>
</item> </item>
<item> <item>
<key> <string>errors</string> </key> <key> <string>errors</string> </key>
...@@ -490,7 +506,7 @@ else :\n ...@@ -490,7 +506,7 @@ else :\n
<dictionary> <dictionary>
<item> <item>
<key> <string>co_argcount</string> </key> <key> <string>co_argcount</string> </key>
<value> <int>3</int> </value> <value> <int>4</int> </value>
</item> </item>
<item> <item>
<key> <string>co_varnames</string> </key> <key> <string>co_varnames</string> </key>
...@@ -499,6 +515,7 @@ else :\n ...@@ -499,6 +515,7 @@ else :\n
<string>listbox</string> <string>listbox</string>
<string>cash_detail_dict</string> <string>cash_detail_dict</string>
<string>rendering_vault</string> <string>rendering_vault</string>
<string>fast_input_title</string>
<string>kw</string> <string>kw</string>
<string>Products.ERP5Type.Cache</string> <string>Products.ERP5Type.Cache</string>
<string>CachingMethod</string> <string>CachingMethod</string>
...@@ -515,6 +532,7 @@ else :\n ...@@ -515,6 +532,7 @@ else :\n
<string>column_base_category</string> <string>column_base_category</string>
<string>read_only</string> <string>read_only</string>
<string>currency_cash_portal_type</string> <string>currency_cash_portal_type</string>
<string>target_total_price</string>
<string>False</string> <string>False</string>
<string>use_inventory</string> <string>use_inventory</string>
<string>list</string> <string>list</string>
...@@ -607,6 +625,7 @@ else :\n ...@@ -607,6 +625,7 @@ else :\n
<none/> <none/>
<none/> <none/>
<none/> <none/>
<none/>
</tuple> </tuple>
</value> </value>
</item> </item>
......
...@@ -52,6 +52,10 @@ ...@@ -52,6 +52,10 @@
<key> <string>action</string> </key> <key> <string>action</string> </key>
<value> <string>CashDetail_saveFastInputLine</string> </value> <value> <string>CashDetail_saveFastInputLine</string> </value>
</item> </item>
<item>
<key> <string>description</string> </key>
<value> <string>None</string> </value>
</item>
<item> <item>
<key> <string>encoding</string> </key> <key> <string>encoding</string> </key>
<value> <string>UTF-8</string> </value> <value> <string>UTF-8</string> </value>
...@@ -131,6 +135,8 @@ ...@@ -131,6 +135,8 @@
<string>my_line_portal_type</string> <string>my_line_portal_type</string>
<string>my_other_parameter</string> <string>my_other_parameter</string>
<string>my_calculated_price</string> <string>my_calculated_price</string>
<string>my_target_total_price</string>
<string>my_fast_input_title</string>
</list> </list>
</value> </value>
</item> </item>
...@@ -161,7 +167,7 @@ ...@@ -161,7 +167,7 @@
</item> </item>
<item> <item>
<key> <string>row_length</string> </key> <key> <string>row_length</string> </key>
<value> <int>4</int> </value> <value> <int>5</int> </value>
</item> </item>
<item> <item>
<key> <string>stored_encoding</string> </key> <key> <string>stored_encoding</string> </key>
......
352 353
\ 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