Commit 09b2f9a5 authored by Kazuhiko Shiozaki's avatar Kazuhiko Shiozaki

we no longer use TemplateTool_reinstallBT5 external method.

git-svn-id: https://svn.erp5.org/repos/public/erp5/trunk@43253 20353a03-c40f-0410-a6d1-a30d3c3de9de
parent 9ba13012
...@@ -119,24 +119,6 @@ def ERP5Site_runVerificationScript(self, method_id): ...@@ -119,24 +119,6 @@ def ERP5Site_runVerificationScript(self, method_id):
if len(integrity_result) > 0: if len(integrity_result) > 0:
return '%s : \n - %s ' % (method_id, '\n - '.join(integrity_result)) return '%s : \n - %s ' % (method_id, '\n - '.join(integrity_result))
def TemplateTool_reinstallBT5(self, bt5_title, update_catalog=0):
"""This method get the installed Business Template,
then reinstall it to overwrite all local changes.
"""
portal = self.getPortalObject()
portal_templates = portal.portal_templates
installed_bt5 = portal_templates.getInstalledBusinessTemplate(bt5_title)
BusinessTemplate_getModifiedObject = \
aq_base(getattr(portal, 'BusinessTemplate_getModifiedObject', None))
if BusinessTemplate_getModifiedObject is None:
portal.changeSkin('View')
BusinessTemplate_getModifiedObject = \
aq_base(portal.BusinessTemplate_getModifiedObject)
# Call reinstall
installed_bt5.reinstall(update_catalog=update_catalog)
log("Reinstalled %s" % (bt5_title,))
def ERP5Site_changeAuthoredDocumentListOwnership(self, old_owner, new_owner): def ERP5Site_changeAuthoredDocumentListOwnership(self, old_owner, new_owner):
""" """
Change owneship for all documents in the system belonging to Change owneship for all documents in the system belonging to
......
...@@ -111,7 +111,6 @@ def launchUpgraderAlarm(alarm_id, after_method_id=[]):\n ...@@ -111,7 +111,6 @@ def launchUpgraderAlarm(alarm_id, after_method_id=[]):\n
previous_method_id = launchUpgraderAlarm(\'bt5_upgrader\')\n previous_method_id = launchUpgraderAlarm(\'bt5_upgrader\')\n
\n \n
previous_method_id.extend([\'updateBusinessTemplateFromUrl\',\n previous_method_id.extend([\'updateBusinessTemplateFromUrl\',\n
\'TemplateTool_reinstallBT5\',\n
\'immediateReindexObject\'])\n \'immediateReindexObject\'])\n
\n \n
previous_method_id = launchUpgraderAlarm(\'finalize_upgrader\',\n previous_method_id = launchUpgraderAlarm(\'finalize_upgrader\',\n
......
<?xml version="1.0"?>
<ZopeData>
<record id="1" aka="AAAAAAAAAAE=">
<pickle>
<global name="ExternalMethod" module="Products.ExternalMethod.ExternalMethod"/>
</pickle>
<pickle>
<dictionary>
<item>
<key> <string>_function</string> </key>
<value> <string>TemplateTool_reinstallBT5</string> </value>
</item>
<item>
<key> <string>_module</string> </key>
<value> <string>ERP5UpgraderUtils</string> </value>
</item>
<item>
<key> <string>id</string> </key>
<value> <string>TemplateTool_reinstallBT5</string> </value>
</item>
<item>
<key> <string>title</string> </key>
<value> <string></string> </value>
</item>
</dictionary>
</pickle>
</record>
</ZopeData>
573 574
\ 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