From 117f1c0701fa4f0e7f4caf0ae486b1d6d9d3a043 Mon Sep 17 00:00:00 2001
From: Yoshinori Okuji <yo@nexedi.com>
Date: Wed, 21 May 2008 21:01:31 +0000
Subject: [PATCH] Clear all caches after installing everything.

git-svn-id: https://svn.erp5.org/repos/public/erp5/trunk@21075 20353a03-c40f-0410-a6d1-a30d3c3de9de
---
 product/ERP5Wizard/Tool/WizardTool.py | 6 +++++-
 1 file changed, 5 insertions(+), 1 deletion(-)

diff --git a/product/ERP5Wizard/Tool/WizardTool.py b/product/ERP5Wizard/Tool/WizardTool.py
index 1f7d6dbf8e..246fef965d 100644
--- a/product/ERP5Wizard/Tool/WizardTool.py
+++ b/product/ERP5Wizard/Tool/WizardTool.py
@@ -386,9 +386,11 @@ class WizardTool(BaseTool):
     if use_super_manager:
       # set current security manager to owner of site
       _setSuperSecurityManager(self.getPortalObject())
+
+    portal = self.getPortalObject()
     bt5_files = server_response.get("filedata", [])
     bt5_filenames = server_response["server_buffer"].get("filenames", [])
-    portal_templates = getToolByName(self.getPortalObject(), 'portal_templates')
+    portal_templates = getToolByName(portal, 'portal_templates')
     counter = 0
     LOG("Wizard", INFO, 
               "Starting installation for %s" %' '.join(bt5_filenames))
@@ -431,6 +433,8 @@ class WizardTool(BaseTool):
                                            1)
     self.setExpressConfigurationPreference('preferred_express_after_setup_script_id', 
                                            bt5_after_setup_script_id)
+    # Make sure that the site status is reloaded.
+    portal.portal_caches.clearAllCache()
     LOG("Wizard", INFO, 
               "Completed installation for %s" %' '.join(bt5_filenames))  
     if use_super_manager:
-- 
2.30.9