Log message for revision 115014: Simplify signatures of new methods and allow them to work without a REQUEST
Changed: U Zope/branches/andig-catalog-report/src/Products/ZCatalog/ZCatalog.py -=- Modified: Zope/branches/andig-catalog-report/src/Products/ZCatalog/ZCatalog.py =================================================================== --- Zope/branches/andig-catalog-report/src/Products/ZCatalog/ZCatalog.py 2010-07-24 15:06:10 UTC (rev 115013) +++ Zope/branches/andig-catalog-report/src/Products/ZCatalog/ZCatalog.py 2010-07-24 15:18:13 UTC (rev 115014) @@ -1023,26 +1023,26 @@ security.declareProtected(manage_zcatalog_entries, 'manage_resetCatalogReport') - def manage_resetCatalogReport(self, REQUEST=None, RESPONSE=None, URL1=None): + def manage_resetCatalogReport(self, REQUEST=None): """ resets the catalog reports """ self._catalog.getCatalogReport().reset() - if REQUEST and RESPONSE: - RESPONSE.redirect( - URL1 + - '/manage_catalogReport?manage_tabs_message=Report%20cleared') + if REQUEST is not None: + REQUEST.response.redirect(REQUEST.URL1 + + '/manage_catalogReport?manage_tabs_message=Report%20cleared') security.declareProtected(manage_zcatalog_entries, 'manage_editCatalogReport') - def manage_editCatalogReport(self, RESPONSE, URL1, long_query_time=0.1, REQUEST=None): + def manage_editCatalogReport(self, long_query_time=0.1, REQUEST=None): """ edit the long query time """ if not isinstance(long_query_time, float): long_query_time = float(long_query_time) - self.long_query_time = long_query_time - RESPONSE.redirect( - URL1 + '/manage_catalogReport?manage_tabs_message=Long%20query%20time%20changed') + if REQUEST is not None: + REQUEST.response.redirect(REQUEST.URL1 + + '/manage_catalogReport?manage_tabs_message=' + + 'Long%20query%20time%20changed') InitializeClass(ZCatalog) _______________________________________________ Zope-Checkins maillist - Zope-Checkins@zope.org https://mail.zope.org/mailman/listinfo/zope-checkins