mirror of
https://github.com/lucaspalomodevelop/core.git
synced 2026-03-13 08:09:41 +00:00
firmware: disable autoscroll if client position differs; closes #4545
This excludes the "reset", i.e. when the action was done or the page loads initially with the previous log file.
This commit is contained in:
parent
93be19f402
commit
09659ff25b
@ -313,8 +313,13 @@
|
||||
function trackStatus() {
|
||||
ajaxGet('/api/core/firmware/upgradestatus', {}, function(data, status) {
|
||||
if (data['log'] != undefined) {
|
||||
var autoscroll = $('#update_status')[0].scrollTop +
|
||||
$('#update_status')[0].clientHeight ===
|
||||
$('#update_status')[0].scrollHeight;
|
||||
$('#update_status').html(data['log']);
|
||||
$('#update_status').scrollTop($('#update_status')[0].scrollHeight);
|
||||
if (autoscroll) {
|
||||
$('#update_status').scrollTop($('#update_status')[0].scrollHeight);
|
||||
}
|
||||
}
|
||||
if (data['status'] == 'done') {
|
||||
$("#upgrade_progress_maj").removeClass("fa fa-spinner fa-pulse");
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user