fw_log.volt: get filters from url

This commit is contained in:
kulikov-a 2021-03-25 22:42:57 +03:00 committed by GitHub
parent a3f4d71940
commit fa44c69b86
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -393,6 +393,17 @@
});
});
// get and apply url params. ie11 compat
let urlvars = window.location.search.substring(1).split("&");
if (urlvars.length >= 1 && urlvars[0] !== "") {
urlvars.forEach(function(value) {
$("#filter_tag").val(value.split("=")[0]);
$("#filter_condition").val("=");
$("#filter_value").val(value.split("=")[1]);
$("#add_filter_condition").click();
});
}
// startup poller
poller();
});