From ffafcf2c835d6b80c3e559214d1aef71ca47fee5 Mon Sep 17 00:00:00 2001 From: billz Date: Thu, 23 Nov 2023 11:43:38 +0000 Subject: [PATCH] Add successMsg, set btn state disabled until update complete --- app/js/custom.js | 11 +++++++++-- templates/about.php | 5 +++-- 2 files changed, 12 insertions(+), 4 deletions(-) diff --git a/app/js/custom.js b/app/js/custom.js index 81820997..b2dd65b3 100644 --- a/app/js/custom.js +++ b/app/js/custom.js @@ -337,15 +337,22 @@ function fetchUpdateResponse() { $(divId).removeClass('invisible'); } if (response.includes(complete)) { + var successMsg = $('#successMsg').data('message'); + $('#updateMsg').after('' + successMsg + ''); + $('#updateMsg').addClass('fa-check'); + $('#updateMsg').removeClass('invisible'); $('#updateStep6').removeClass('invisible'); $('#updateSync2').removeClass("fa-spin"); + $('#updateOk').removeAttr('disabled'); endPolling = true; break; } else if (response.includes(error)) { var errorMsg = $('#errorMsg').data('message'); - $('#updateErr').after('' + errorMsg + ''); - $('#updateErr').removeClass('invisible'); + $('#updateMsg').after('' + errorMsg + ''); + $('#updateMsg').addClass('fa-times'); + $('#updateMsg').removeClass('invisible'); $('#updateSync2').removeClass("fa-spin"); + $('#updateOk').removeAttr('disabled'); endPolling = true; break; } diff --git a/templates/about.php b/templates/about.php index b0c40d59..74a53c52 100755 --- a/templates/about.php +++ b/templates/about.php @@ -122,11 +122,12 @@ require_once 'app/lib/Parsedown.php';
-
+
/tmp/raspap_install.log"); ?>">
+
">