Commit 3efc33a5 authored by Mame Coumba Sall's avatar Mame Coumba Sall Committed by Julien Muchembled

Rename scripts used as listbox methods and import those changes where they're required

parent fac0ba5a
...@@ -122,7 +122,7 @@ return [Object(debit_price=debit, credit_price=credit)]\n ...@@ -122,7 +122,7 @@ return [Object(debit_price=debit, credit_price=credit)]\n
</item> </item>
<item> <item>
<key> <string>id</string> </key> <key> <string>id</string> </key>
<value> <string>AccountModule_getGeneralLedgerSummary</string> </value> <value> <string>AccountModule_getGeneralLedgerSummarySectionList</string> </value>
</item> </item>
</dictionary> </dictionary>
</pickle> </pickle>
......
...@@ -783,7 +783,7 @@ return new_line_list\n ...@@ -783,7 +783,7 @@ return new_line_list\n
</item> </item>
<item> <item>
<key> <string>id</string> </key> <key> <string>id</string> </key>
<value> <string>AccountModule_getAccountListForTrialBalance</string> </value> <value> <string>AccountModule_getTrialBalanceAccountList</string> </value>
</item> </item>
</dictionary> </dictionary>
</pickle> </pickle>
......
...@@ -323,6 +323,10 @@ ...@@ -323,6 +323,10 @@
<key> <string>alternate_name</string> </key> <key> <string>alternate_name</string> </key>
<value> <string></string> </value> <value> <string></string> </value>
</item> </item>
<item>
<key> <string>anchor</string> </key>
<value> <int>0</int> </value>
</item>
<item> <item>
<key> <string>columns</string> </key> <key> <string>columns</string> </key>
<value> <value>
...@@ -459,10 +463,18 @@ ...@@ -459,10 +463,18 @@
<list/> <list/>
</value> </value>
</item> </item>
<item>
<key> <string>global_search_column</string> </key>
<value> <string></string> </value>
</item>
<item> <item>
<key> <string>hidden</string> </key> <key> <string>hidden</string> </key>
<value> <int>0</int> </value> <value> <int>0</int> </value>
</item> </item>
<item>
<key> <string>hide_rows_on_no_search_criterion</string> </key>
<value> <int>0</int> </value>
</item>
<item> <item>
<key> <string>lines</string> </key> <key> <string>lines</string> </key>
<value> <int>25</int> </value> <value> <int>25</int> </value>
...@@ -483,6 +495,10 @@ ...@@ -483,6 +495,10 @@
<list/> <list/>
</value> </value>
</item> </item>
<item>
<key> <string>page_navigation_template</string> </key>
<value> <string>ListBox_viewSliderPageNavigationRenderer</string> </value>
</item>
<item> <item>
<key> <string>page_template</string> </key> <key> <string>page_template</string> </key>
<value> <string></string> </value> <value> <string></string> </value>
...@@ -503,6 +519,10 @@ ...@@ -503,6 +519,10 @@
<key> <string>report_tree</string> </key> <key> <string>report_tree</string> </key>
<value> <int>0</int> </value> <value> <int>0</int> </value>
</item> </item>
<item>
<key> <string>row_css_method</string> </key>
<value> <string></string> </value>
</item>
<item> <item>
<key> <string>search</string> </key> <key> <string>search</string> </key>
<value> <int>0</int> </value> <value> <int>0</int> </value>
...@@ -545,10 +565,22 @@ ...@@ -545,10 +565,22 @@
<persistent> <string encoding="base64">AAAAAAAAAAM=</string> </persistent> <persistent> <string encoding="base64">AAAAAAAAAAM=</string> </persistent>
</value> </value>
</item> </item>
<item>
<key> <string>style_columns</string> </key>
<value>
<list/>
</value>
</item>
<item> <item>
<key> <string>title</string> </key> <key> <string>title</string> </key>
<value> <string>Accounts</string> </value> <value> <string>Accounts</string> </value>
</item> </item>
<item>
<key> <string>untranslatable_columns</string> </key>
<value>
<list/>
</value>
</item>
<item> <item>
<key> <string>url_columns</string> </key> <key> <string>url_columns</string> </key>
<value> <value>
...@@ -569,7 +601,7 @@ ...@@ -569,7 +601,7 @@
<dictionary> <dictionary>
<item> <item>
<key> <string>method_name</string> </key> <key> <string>method_name</string> </key>
<value> <string>AccountModule_getAccountListForTrialBalance</string> </value> <value> <string>AccountModule_getTrialBalanceAccountList</string> </value>
</item> </item>
</dictionary> </dictionary>
</pickle> </pickle>
......
...@@ -417,6 +417,10 @@ ...@@ -417,6 +417,10 @@
<list/> <list/>
</value> </value>
</item> </item>
<item>
<key> <string>global_search_column</string> </key>
<value> <string></string> </value>
</item>
<item> <item>
<key> <string>hidden</string> </key> <key> <string>hidden</string> </key>
<value> <int>0</int> </value> <value> <int>0</int> </value>
...@@ -445,6 +449,10 @@ ...@@ -445,6 +449,10 @@
<list/> <list/>
</value> </value>
</item> </item>
<item>
<key> <string>page_navigation_template</string> </key>
<value> <string>ListBox_viewSliderPageNavigationRenderer</string> </value>
</item>
<item> <item>
<key> <string>page_template</string> </key> <key> <string>page_template</string> </key>
<value> <string></string> </value> <value> <string></string> </value>
...@@ -509,6 +517,12 @@ ...@@ -509,6 +517,12 @@
<key> <string>stat_method</string> </key> <key> <string>stat_method</string> </key>
<value> <string></string> </value> <value> <string></string> </value>
</item> </item>
<item>
<key> <string>style_columns</string> </key>
<value>
<list/>
</value>
</item>
<item> <item>
<key> <string>title</string> </key> <key> <string>title</string> </key>
<value> <string>General Ledger Summary</string> </value> <value> <string>General Ledger Summary</string> </value>
...@@ -539,7 +553,7 @@ ...@@ -539,7 +553,7 @@
<dictionary> <dictionary>
<item> <item>
<key> <string>method_name</string> </key> <key> <string>method_name</string> </key>
<value> <string>AccountModule_getGeneralLedgerSummary</string> </value> <value> <string>AccountModule_getGeneralLedgerSummarySectionList</string> </value>
</item> </item>
</dictionary> </dictionary>
</pickle> </pickle>
......
...@@ -628,7 +628,7 @@ ...@@ -628,7 +628,7 @@
<dictionary> <dictionary>
<item> <item>
<key> <string>method_name</string> </key> <key> <string>method_name</string> </key>
<value> <string>ListBox_listCashContainers</string> </value> <value> <string>Listbox_getCashContainerList</string> </value>
</item> </item>
</dictionary> </dictionary>
</pickle> </pickle>
......
...@@ -119,7 +119,7 @@ return context.ListBox_initializeFastInput()\n ...@@ -119,7 +119,7 @@ return context.ListBox_initializeFastInput()\n
</item> </item>
<item> <item>
<key> <string>id</string> </key> <key> <string>id</string> </key>
<value> <string>ListBox_listCashContainers</string> </value> <value> <string>Listbox_getCashContainerList</string> </value>
</item> </item>
</dictionary> </dictionary>
</pickle> </pickle>
......
...@@ -563,7 +563,7 @@ ...@@ -563,7 +563,7 @@
<dictionary> <dictionary>
<item> <item>
<key> <string>method_name</string> </key> <key> <string>method_name</string> </key>
<value> <string>ListBox_listCheckbook</string> </value> <value> <string>Listbox_listCheckbookList</string> </value>
</item> </item>
</dictionary> </dictionary>
</pickle> </pickle>
......
...@@ -129,7 +129,7 @@ return context.ListBox_initializeFastInput()\n ...@@ -129,7 +129,7 @@ return context.ListBox_initializeFastInput()\n
</item> </item>
<item> <item>
<key> <string>id</string> </key> <key> <string>id</string> </key>
<value> <string>ListBox_listCheckbook</string> </value> <value> <string>Listbox_listCheckbookList</string> </value>
</item> </item>
</dictionary> </dictionary>
</pickle> </pickle>
......
...@@ -525,7 +525,7 @@ ...@@ -525,7 +525,7 @@
<dictionary> <dictionary>
<item> <item>
<key> <string>method_name</string> </key> <key> <string>method_name</string> </key>
<value> <string>ListBox_initializeFastInput</string> </value> <value> <string>Listbox_initializeFastInputDocumentList</string> </value>
</item> </item>
</dictionary> </dictionary>
</pickle> </pickle>
......
...@@ -538,7 +538,7 @@ ...@@ -538,7 +538,7 @@
<dictionary> <dictionary>
<item> <item>
<key> <string>method_name</string> </key> <key> <string>method_name</string> </key>
<value> <unicode>ListBox_initializeFastInput</unicode> </value> <value> <string>Listbox_initializeFastInputDocumentList</string> </value>
</item> </item>
</dictionary> </dictionary>
</pickle> </pickle>
......
...@@ -570,7 +570,7 @@ ...@@ -570,7 +570,7 @@
<dictionary> <dictionary>
<item> <item>
<key> <string>method_name</string> </key> <key> <string>method_name</string> </key>
<value> <string>ListBox_initializeFastInput</string> </value> <value> <string>Listbox_initializeFastInputDocumentList</string> </value>
</item> </item>
</dictionary> </dictionary>
</pickle> </pickle>
......
...@@ -518,7 +518,7 @@ ...@@ -518,7 +518,7 @@
<dictionary> <dictionary>
<item> <item>
<key> <string>method_name</string> </key> <key> <string>method_name</string> </key>
<value> <string>FastInput_initialize</string> </value> <value> <string>FastInput_initializeDocumentList</string> </value>
</item> </item>
</dictionary> </dictionary>
</pickle> </pickle>
......
...@@ -518,7 +518,7 @@ ...@@ -518,7 +518,7 @@
<dictionary> <dictionary>
<item> <item>
<key> <string>method_name</string> </key> <key> <string>method_name</string> </key>
<value> <string>FastInput_initialize</string> </value> <value> <string>FastInput_initializeDocumentList</string> </value>
</item> </item>
</dictionary> </dictionary>
</pickle> </pickle>
......
...@@ -546,7 +546,7 @@ ...@@ -546,7 +546,7 @@
<dictionary> <dictionary>
<item> <item>
<key> <string>method_name</string> </key> <key> <string>method_name</string> </key>
<value> <string>FastInput_initialize</string> </value> <value> <string>FastInput_initializeDocumentList</string> </value>
</item> </item>
</dictionary> </dictionary>
</pickle> </pickle>
......
...@@ -586,7 +586,7 @@ ...@@ -586,7 +586,7 @@
<dictionary> <dictionary>
<item> <item>
<key> <string>method_name</string> </key> <key> <string>method_name</string> </key>
<value> <string>FastInput_initialize</string> </value> <value> <string>FastInput_initializeDocumentList</string> </value>
</item> </item>
</dictionary> </dictionary>
</pickle> </pickle>
......
...@@ -570,7 +570,7 @@ ...@@ -570,7 +570,7 @@
<dictionary> <dictionary>
<item> <item>
<key> <string>method_name</string> </key> <key> <string>method_name</string> </key>
<value> <string>FastInput_initialize</string> </value> <value> <string>FastInput_initializeDocumentList</string> </value>
</item> </item>
</dictionary> </dictionary>
</pickle> </pickle>
......
...@@ -594,7 +594,7 @@ ...@@ -594,7 +594,7 @@
<dictionary> <dictionary>
<item> <item>
<key> <string>method_name</string> </key> <key> <string>method_name</string> </key>
<value> <string>FastInput_initialize</string> </value> <value> <string>FastInput_initializeDocumentList</string> </value>
</item> </item>
</dictionary> </dictionary>
</pickle> </pickle>
......
...@@ -84,7 +84,7 @@ return l\n ...@@ -84,7 +84,7 @@ return l\n
</item> </item>
<item> <item>
<key> <string>id</string> </key> <key> <string>id</string> </key>
<value> <string>FastInput_initialize</string> </value> <value> <string>FastInput_initializeDocumentList</string> </value>
</item> </item>
</dictionary> </dictionary>
</pickle> </pickle>
......
...@@ -558,7 +558,7 @@ ...@@ -558,7 +558,7 @@
<dictionary> <dictionary>
<item> <item>
<key> <string>method_name</string> </key> <key> <string>method_name</string> </key>
<value> <string>FastInput_initialize</string> </value> <value> <string>FastInput_initializeDocumentList</string> </value>
</item> </item>
</dictionary> </dictionary>
</pickle> </pickle>
......
...@@ -546,7 +546,7 @@ ...@@ -546,7 +546,7 @@
<dictionary> <dictionary>
<item> <item>
<key> <string>method_name</string> </key> <key> <string>method_name</string> </key>
<value> <string>FastInput_initialize</string> </value> <value> <string>FastInput_initializeDocumentList</string> </value>
</item> </item>
</dictionary> </dictionary>
</pickle> </pickle>
......
...@@ -558,7 +558,7 @@ ...@@ -558,7 +558,7 @@
<dictionary> <dictionary>
<item> <item>
<key> <string>method_name</string> </key> <key> <string>method_name</string> </key>
<value> <string>FastInput_initialize</string> </value> <value> <string>FastInput_initializeDocumentList</string> </value>
</item> </item>
</dictionary> </dictionary>
</pickle> </pickle>
......
...@@ -524,6 +524,12 @@ ...@@ -524,6 +524,12 @@
<key> <string>title</string> </key> <key> <string>title</string> </key>
<value> <string>Scenarii with Steps</string> </value> <value> <string>Scenarii with Steps</string> </value>
</item> </item>
<item>
<key> <string>untranslatable_columns</string> </key>
<value>
<list/>
</value>
</item>
<item> <item>
<key> <string>url_columns</string> </key> <key> <string>url_columns</string> </key>
<value> <value>
...@@ -547,7 +553,7 @@ ...@@ -547,7 +553,7 @@
<dictionary> <dictionary>
<item> <item>
<key> <string>method_name</string> </key> <key> <string>method_name</string> </key>
<value> <string>FastInput_initialize</string> </value> <value> <string>FastInput_initializeDocumentList</string> </value>
</item> </item>
</dictionary> </dictionary>
</pickle> </pickle>
......
...@@ -86,7 +86,7 @@ for o in objects:\n ...@@ -86,7 +86,7 @@ for o in objects:\n
# orphan object\n # orphan object\n
orphans_list.append(object_path)\n orphans_list.append(object_path)\n
# Recursively check children\n # Recursively check children\n
orphans_list.extend([x.uid for x in context.Base_getOrphanObjects(object=o)])\n orphans_list.extend([x.uid for x in context.Base_getOrphanObjectList(object=o)])\n
\n \n
object_list = []\n object_list = []\n
for orphan in orphans_list:\n for orphan in orphans_list:\n
...@@ -107,7 +107,7 @@ return object_list\n ...@@ -107,7 +107,7 @@ return object_list\n
</item> </item>
<item> <item>
<key> <string>id</string> </key> <key> <string>id</string> </key>
<value> <string>Base_getOrphanObjects</string> </value> <value> <string>Base_getOrphanObjectList</string> </value>
</item> </item>
</dictionary> </dictionary>
</pickle> </pickle>
......
...@@ -509,7 +509,7 @@ ...@@ -509,7 +509,7 @@
<dictionary> <dictionary>
<item> <item>
<key> <string>method_name</string> </key> <key> <string>method_name</string> </key>
<value> <string>Base_getOrphanObjects</string> </value> <value> <string>Base_getOrphanObjectList</string> </value>
</item> </item>
</dictionary> </dictionary>
</pickle> </pickle>
......
...@@ -50,7 +50,7 @@ ...@@ -50,7 +50,7 @@
</item> </item>
<item> <item>
<key> <string>_body</string> </key> <key> <string>_body</string> </key>
<value> <string>return context.ListBox_initializeFastInput(\n <value> <string>return context.Listbox_initializeFastInputDocumentList(\n
empty_line_number=10, **kw)\n empty_line_number=10, **kw)\n
</string> </value> </string> </value>
</item> </item>
...@@ -60,7 +60,7 @@ ...@@ -60,7 +60,7 @@
</item> </item>
<item> <item>
<key> <string>id</string> </key> <key> <string>id</string> </key>
<value> <string>BusinessTemplate_initializeListBoxForRenameFastInput</string> </value> <value> <string>BusinessTemplate_initializeListBoxToGetProxyFieldToRenameList</string> </value>
</item> </item>
</dictionary> </dictionary>
</pickle> </pickle>
......
...@@ -50,7 +50,7 @@ ...@@ -50,7 +50,7 @@
</item> </item>
<item> <item>
<key> <string>_body</string> </key> <key> <string>_body</string> </key>
<value> <string>return context.ListBox_initializeFastInput(\n <value> <string>return context.Listbox_initializeFastInputDocumentList(\n
listbox_id=\'preview_listbox\', empty_line_number=0, **kw)\n listbox_id=\'preview_listbox\', empty_line_number=0, **kw)\n
</string> </value> </string> </value>
</item> </item>
...@@ -60,7 +60,7 @@ ...@@ -60,7 +60,7 @@
</item> </item>
<item> <item>
<key> <string>id</string> </key> <key> <string>id</string> </key>
<value> <string>BusinessTemplate_initializePreviewListBoxForRenameFastInput</string> </value> <value> <string>BusinessTemplate_initializePreviewListBoxToGetProxyFieldToRenameList</string> </value>
</item> </item>
</dictionary> </dictionary>
</pickle> </pickle>
......
...@@ -539,7 +539,7 @@ ...@@ -539,7 +539,7 @@
<dictionary> <dictionary>
<item> <item>
<key> <string>method_name</string> </key> <key> <string>method_name</string> </key>
<value> <string>BusinessTemplate_initializeListBoxForRenameFastInput</string> </value> <value> <string>BusinessTemplate_initializeListBoxToGetProxyFieldToRenameList</string> </value>
</item> </item>
</dictionary> </dictionary>
</pickle> </pickle>
......
...@@ -555,7 +555,7 @@ ...@@ -555,7 +555,7 @@
<dictionary> <dictionary>
<item> <item>
<key> <string>method_name</string> </key> <key> <string>method_name</string> </key>
<value> <string>BusinessTemplate_initializePreviewListBoxForRenameFastInput</string> </value> <value> <string>BusinessTemplate_initializePreviewListBoxToGetProxyFieldToRenameList</string> </value>
</item> </item>
</dictionary> </dictionary>
</pickle> </pickle>
......
...@@ -64,7 +64,7 @@ return context.portal_simulation.getInventoryList(transformed_resource=transform ...@@ -64,7 +64,7 @@ return context.portal_simulation.getInventoryList(transformed_resource=transform
</item> </item>
<item> <item>
<key> <string>id</string> </key> <key> <string>id</string> </key>
<value> <string>Resource_getTransformedResourceInventory</string> </value> <value> <string>Resource_getTransformedResourceInventoryList</string> </value>
</item> </item>
</dictionary> </dictionary>
</pickle> </pickle>
......
...@@ -597,7 +597,7 @@ ...@@ -597,7 +597,7 @@
<dictionary> <dictionary>
<item> <item>
<key> <string>method_name</string> </key> <key> <string>method_name</string> </key>
<value> <string>Resource_getTransformedResourceInventory</string> </value> <value> <string>Resource_getTransformedResourceInventoryList</string> </value>
</item> </item>
</dictionary> </dictionary>
</pickle> </pickle>
......
...@@ -635,7 +635,7 @@ ...@@ -635,7 +635,7 @@
<dictionary> <dictionary>
<item> <item>
<key> <string>method_name</string> </key> <key> <string>method_name</string> </key>
<value> <string>Project_initializeFastInput</string> </value> <value> <string>Project_initializeFastInputTaskList</string> </value>
</item> </item>
</dictionary> </dictionary>
</pickle> </pickle>
......
...@@ -89,7 +89,7 @@ return l\n ...@@ -89,7 +89,7 @@ return l\n
</item> </item>
<item> <item>
<key> <string>id</string> </key> <key> <string>id</string> </key>
<value> <string>Project_initializeFastInput</string> </value> <value> <string>Project_initializeFastInputTaskList</string> </value>
</item> </item>
</dictionary> </dictionary>
</pickle> </pickle>
......
...@@ -583,7 +583,7 @@ ...@@ -583,7 +583,7 @@
<dictionary> <dictionary>
<item> <item>
<key> <string>method_name</string> </key> <key> <string>method_name</string> </key>
<value> <string>Project_initializeFastInput</string> </value> <value> <string>Project_initializeFastInputTaskList</string> </value>
</item> </item>
</dictionary> </dictionary>
</pickle> </pickle>
......
...@@ -1398,7 +1398,7 @@ class TemplateTool (BaseTool): ...@@ -1398,7 +1398,7 @@ class TemplateTool (BaseTool):
pass pass
install_kw = {} install_kw = {}
for listbox_line in imported_bt5.BusinessTemplate_getModifiedObject(): for listbox_line in imported_bt5.BusinessTemplate_getModifiedObjectList():
item = listbox_line.object_id item = listbox_line.object_id
state = listbox_line.object_state state = listbox_line.object_state
if state.startswith('Removed'): if state.startswith('Removed'):
......
...@@ -130,7 +130,7 @@ return object_list\n ...@@ -130,7 +130,7 @@ return object_list\n
</item> </item>
<item> <item>
<key> <string>id</string> </key> <key> <string>id</string> </key>
<value> <string>BusinessTemplate_getModifiedObject</string> </value> <value> <string>BusinessTemplate_getModifiedObjectList</string> </value>
</item> </item>
</dictionary> </dictionary>
</pickle> </pickle>
......
...@@ -540,7 +540,7 @@ ...@@ -540,7 +540,7 @@
<dictionary> <dictionary>
<item> <item>
<key> <string>method_name</string> </key> <key> <string>method_name</string> </key>
<value> <string>BusinessTemplate_getModifiedObject</string> </value> <value> <string>BusinessTemplate_getModifiedObjectList</string> </value>
</item> </item>
</dictionary> </dictionary>
</pickle> </pickle>
......
...@@ -59,7 +59,7 @@ ...@@ -59,7 +59,7 @@
</item> </item>
<item> <item>
<key> <string>id</string> </key> <key> <string>id</string> </key>
<value> <string>CategoryTool_getImportReportFromRequest</string> </value> <value> <string>CategoryTool_getFromRequestImportReportFieldList</string> </value>
</item> </item>
</dictionary> </dictionary>
</pickle> </pickle>
......
...@@ -531,7 +531,7 @@ ...@@ -531,7 +531,7 @@
<dictionary> <dictionary>
<item> <item>
<key> <string>method_name</string> </key> <key> <string>method_name</string> </key>
<value> <string>CategoryTool_getImportReportFromRequest</string> </value> <value> <string>CategoryTool_getFromRequestImportReportFieldList</string> </value>
</item> </item>
</dictionary> </dictionary>
</pickle> </pickle>
......
...@@ -135,7 +135,6 @@ def checkField(folder, form, field):\n ...@@ -135,7 +135,6 @@ def checkField(folder, form, field):\n
if a not in (None, "portal_catalog", "searchFolder", "objectValues",\n if a not in (None, "portal_catalog", "searchFolder", "objectValues",\n
"contentValues", "ListBox_initializeFastInput"):\n "contentValues", "ListBox_initializeFastInput"):\n
if not a.endswith(\'List\'):\n if not a.endswith(\'List\'):\n
if 0:\n
error_message += "%s : %s : %r Bad Naming Convention\\n" % (path, id, a)\n error_message += "%s : %s : %r Bad Naming Convention\\n" % (path, id, a)\n
return error_message\n return error_message\n
\n \n
......
...@@ -2547,7 +2547,7 @@ class BusinessTemplateMixin(TestDeveloperMixin, ERP5TypeTestCase, LogInterceptor ...@@ -2547,7 +2547,7 @@ class BusinessTemplateMixin(TestDeveloperMixin, ERP5TypeTestCase, LogInterceptor
def stepReinstallBusinessTemplate(self, sequence=None, **kw): def stepReinstallBusinessTemplate(self, sequence=None, **kw):
import_bt = sequence.get('current_bt') import_bt = sequence.get('current_bt')
listbox_object_list = import_bt.BusinessTemplate_getModifiedObject() listbox_object_list = import_bt.BusinessTemplate_getModifiedObjectList()
install_kw = {} install_kw = {}
for listbox_line in listbox_object_list: for listbox_line in listbox_object_list:
install_kw[listbox_line.object_id] = listbox_line.choice_item_list[0][1] install_kw[listbox_line.object_id] = listbox_line.choice_item_list[0][1]
...@@ -2555,7 +2555,7 @@ class BusinessTemplateMixin(TestDeveloperMixin, ERP5TypeTestCase, LogInterceptor ...@@ -2555,7 +2555,7 @@ class BusinessTemplateMixin(TestDeveloperMixin, ERP5TypeTestCase, LogInterceptor
def stepCheckBeforeReinstall(self, sequence=None, **kw): def stepCheckBeforeReinstall(self, sequence=None, **kw):
import_bt = sequence.get('current_bt') import_bt = sequence.get('current_bt')
diff_list = import_bt.BusinessTemplate_getModifiedObject() diff_list = import_bt.BusinessTemplate_getModifiedObjectList()
self.assertTrue('portal_types/Geek Object/become_geek' self.assertTrue('portal_types/Geek Object/become_geek'
in [line.object_id for line in diff_list]) in [line.object_id for line in diff_list])
......
...@@ -920,8 +920,8 @@ class ERP5TypeCommandLineTestCase(ERP5TypeTestCaseMixin): ...@@ -920,8 +920,8 @@ class ERP5TypeCommandLineTestCase(ERP5TypeTestCaseMixin):
quiet=True): quiet=True):
template_tool = self.portal.portal_templates template_tool = self.portal.portal_templates
update_business_templates = os.environ.get('update_business_templates') is not None update_business_templates = os.environ.get('update_business_templates') is not None
BusinessTemplate_getModifiedObject = aq_base( BusinessTemplate_getModifiedObjectList = aq_base(
getattr(self.portal, 'BusinessTemplate_getModifiedObject', None)) getattr(self.portal, 'BusinessTemplate_getModifiedObjectList', None))
# Add some business templates # Add some business templates
for url, bt_title in business_template_list: for url, bt_title in business_template_list:
...@@ -931,7 +931,7 @@ class ERP5TypeCommandLineTestCase(ERP5TypeTestCaseMixin): ...@@ -931,7 +931,7 @@ class ERP5TypeCommandLineTestCase(ERP5TypeTestCaseMixin):
if update_business_templates: if update_business_templates:
if not quiet: if not quiet:
ZopeTestCase._print('Updating %s business template ... ' % bt_title) ZopeTestCase._print('Updating %s business template ... ' % bt_title)
if BusinessTemplate_getModifiedObject is not None: if BusinessTemplate_getModifiedObjectList is not None:
get_install_kw = True get_install_kw = True
else: else:
continue continue
...@@ -949,7 +949,7 @@ class ERP5TypeCommandLineTestCase(ERP5TypeTestCaseMixin): ...@@ -949,7 +949,7 @@ class ERP5TypeCommandLineTestCase(ERP5TypeTestCaseMixin):
install_kw = None install_kw = None
if get_install_kw: if get_install_kw:
install_kw = {} install_kw = {}
listbox_object_list = BusinessTemplate_getModifiedObject.__of__(bt)() listbox_object_list = BusinessTemplate_getModifiedObjectList.__of__(bt)()
for listbox_line in listbox_object_list: for listbox_line in listbox_object_list:
install_kw[listbox_line.object_id] = listbox_line.choice_item_list[0][1] install_kw[listbox_line.object_id] = listbox_line.choice_item_list[0][1]
bt.install(light_install=light_install, bt.install(light_install=light_install,
......
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