mirror of
https://github.com/phpbb/phpbb.git
synced 2025-07-28 12:30:42 +02:00
[ticket/14462] Further speed improvements
- Cache the secondary container - Only initialize tasks/modules that are being used - Add timeout error message in the AJAX UI PHPBB3-14462
This commit is contained in:
@@ -12,6 +12,7 @@
|
||||
var progressTimer = null;
|
||||
var currentProgress = 0;
|
||||
var refreshRequested = false;
|
||||
var transmissionOver = false;
|
||||
|
||||
// Template related variables
|
||||
var $contentWrapper = $('.install-body').find('.main');
|
||||
@@ -329,6 +330,12 @@
|
||||
if (responseObject.hasOwnProperty('redirect')) {
|
||||
redirect(responseObject.redirect.url, responseObject.redirect.use_ajax);
|
||||
}
|
||||
|
||||
if (responseObject.hasOwnProperty('over')) {
|
||||
if (responseObject.over) {
|
||||
transmissionOver = true;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
@@ -357,10 +364,21 @@
|
||||
$('#loading_indicator').css('display', 'none');
|
||||
resetPolling();
|
||||
|
||||
var timeoutDetected = !transmissionOver;
|
||||
|
||||
if (refreshRequested) {
|
||||
refreshRequested = false;
|
||||
doRefresh();
|
||||
}
|
||||
|
||||
if (timeoutDetected) {
|
||||
addMessage('error',
|
||||
[{
|
||||
title:'The installer detected a timeout.',
|
||||
description: 'The installer has detected a timeout, you may try to refresh the page, that may lead to data corruption. We suggest that you either increase your timeout settings or try to use the CLI.'
|
||||
}]
|
||||
);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -420,6 +438,7 @@
|
||||
*/
|
||||
function startPolling(xhReq) {
|
||||
resetPolling();
|
||||
transmissionOver = false;
|
||||
pollTimer = setInterval(function () {
|
||||
pollContent(xhReq);
|
||||
}, 250);
|
||||
|
Reference in New Issue
Block a user