Commit 216e1da3 authored by Rafael Monnerat's avatar Rafael Monnerat

ERP5Configurator: Install bt5 by force and without activities

  If the user wants actitivites, it should create multiples StandardBT5ConfiguratorItems,
  This should accellerate Tests based on ERP5Configurator.

  This should be recoded, but it should speed up bootstrap of a site,
  as get modified objects are not called.
parent 259dc91f
......@@ -81,7 +81,8 @@ class StandardBT5ConfiguratorItem(ConfiguratorItemMixin, XMLObject):
template_tool.installBusinessTemplateListFromRepository([bt5_id],
update_catalog=self.getUpdateCatalog(0),
install_dependency=self.getInstallDependency(1),
activate=True)
force_all=True,
activate=False)
return [self._createConstraintMessage('%s should be installed' % bt5_id),]
......
......@@ -1224,7 +1224,7 @@ class TemplateTool (BaseTool):
'installBusinessTemplateListFromRepository')
def installBusinessTemplateListFromRepository(self, template_list,
only_different=True, update_catalog=False, activate=False,
install_dependency=False):
install_dependency=False, force_all=False):
"""Installs template_list from configured repositories by default only newest"""
# XXX-Luke: This method could replace
# TemplateTool_installRepositoryBusinessTemplateList while still being
......@@ -1254,7 +1254,9 @@ class TemplateTool (BaseTool):
if bt is not None and bt['revision'] == installed_bt5_dict.get(bt_id):
continue
bt_url = '%s/%s' % (repository, bt_id)
param_dict = dict(download_url=bt_url, only_different=only_different)
param_dict = dict(download_url=bt_url,
only_different=only_different,
reinstall=force_all)
param_dict["update_catalog"] = update_catalog
if activate:
......
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