mirror of
https://github.com/Sebclem/hassio-nextcloud-backup.git
synced 2024-11-22 09:12:58 +01:00
🔨 Disable "Backup Now" button if a task is already running
This commit is contained in:
parent
c74a069ba1
commit
a2c93646a6
@ -396,18 +396,23 @@
|
||||
switch (data.status) {
|
||||
case "error":
|
||||
printStatus('Error', data.message);
|
||||
$('#btn-backup-now').removeClass("disabled");
|
||||
break;
|
||||
case "idle":
|
||||
printStatus('Idle', "Waiting for next backup.");
|
||||
$('#btn-backup-now').removeClass("disabled");
|
||||
break;
|
||||
case "download":
|
||||
printStatusWithBar('Downloading Snapshot', data.progress);
|
||||
$('#btn-backup-now').addClass("disabled");
|
||||
break;
|
||||
case "upload":
|
||||
printStatusWithBar('Uploading Snapshot', data.progress);
|
||||
$('#btn-backup-now').addClass("disabled");
|
||||
break;
|
||||
case "creating":
|
||||
printStatusWithBar('Creating Snapshot', data.progress);
|
||||
$('#btn-backup-now').addClass("disabled");
|
||||
break;
|
||||
}
|
||||
if (data.last_backup != null) {
|
||||
|
Loading…
Reference in New Issue
Block a user