commit a4fe264: [Minor] Wait until "auth" Ajax request finishes
moisseev
moiseev at mezonplus.ru
Wed Jun 16 15:35:04 UTC 2021
Author: moisseev
Date: 2021-06-15 20:47:16 +0300
URL: https://github.com/rspamd/rspamd/commit/a4fe264d7f4124ac7ee5fcb3ddf47791e9ef2c03
[Minor] Wait until "auth" Ajax request finishes
---
interface/js/app/rspamd.js | 25 +++++++++++++------------
1 file changed, 13 insertions(+), 12 deletions(-)
diff --git a/interface/js/app/rspamd.js b/interface/js/app/rspamd.js
index 7e571602a..2f1b88aa0 100644
--- a/interface/js/app/rspamd.js
+++ b/interface/js/app/rspamd.js
@@ -298,21 +298,22 @@ function ($, D3pie, visibility, NProgress, stickyTabs, tab_stat, tab_graph, tab_
});
if (!ui.read_only) tab_selectors.displayUI(ui);
},
+ complete: function () {
+ if (ui.read_only) {
+ $(".ro-disable").attr("disabled", true);
+ $(".ro-hide").hide();
+ } else {
+ $(".ro-disable").removeAttr("disabled", true);
+ $(".ro-hide").show();
+ }
+
+ $("#preloader").addClass("d-none");
+ $("#navBar, #mainUI").removeClass("d-none");
+ $(".nav-tabs-sticky").stickyTabs({initialTab:"#status_nav"});
+ },
errorMessage: "Cannot get server status",
server: "All SERVERS"
});
-
- if (ui.read_only) {
- $(".ro-disable").attr("disabled", true);
- $(".ro-hide").hide();
- } else {
- $(".ro-disable").removeAttr("disabled", true);
- $(".ro-hide").show();
- }
-
- $("#preloader").addClass("d-none");
- $("#navBar, #mainUI").removeClass("d-none");
- $(".nav-tabs-sticky").stickyTabs({initialTab:"#status_nav"});
}
function alertMessage(alertClass, alertText) {
More information about the Commits
mailing list