remove log + fix service tab

This commit is contained in:
BlasenhauerJ 2023-02-06 14:00:02 +01:00
parent facb597ee6
commit 8b0d8a9d3d
7 changed files with 3 additions and 19 deletions

View File

@ -37,9 +37,7 @@ class News {
}
);
return await this.render(res);
} catch (err) {
console.log(err);
}
} catch (err) {}
});
}

View File

@ -256,7 +256,6 @@ class FetchLogs {
this.fromDate = Date.parse(this.fromDateInp.value)
? Date.parse(this.fromDateInp.value)
: Date.now() - 86400000;
console.log(Date.parse(this.fromDateInp.value));
this.toDate = Date.parse(this.toDateInp.value)
? Date.parse(this.toDateInp.value)
: false;

View File

@ -414,10 +414,8 @@ class Modal {
}
init() {
console.log("init modal");
this.container.addEventListener("click", (e) => {
//DELETE HANDLER
console.log("click");
try {
if (
e.target.closest("button").getAttribute(`${this.prefix}-action`) ===

View File

@ -46,7 +46,6 @@ class ServiceModal {
//actions
try {
if (e.target.closest("button").hasAttribute("services-action")) {
console.log("click");
//do nothing if same btn and service as before
const isLastSame = this.isLastServAndAct(e.target);
if (isLastSame) return;
@ -57,13 +56,10 @@ class ServiceModal {
const serviceName = e.target
.closest("button")
.getAttribute("services-name");
console.log(action);
console.log(serviceName);
if (action === "edit" || action === "new") {
this.setForm(action, serviceName, this.formNewEdit);
this.setDefaultValue();
console.log("set default");
}
if (action === "delete")
@ -75,10 +71,7 @@ class ServiceModal {
.closest("[services-service]")
.querySelector("[services-settings]")
.getAttribute("value");
console.log(servicesSettings);
const obj = JSON.parse(servicesSettings);
console.log(obj);
console.log("start update");
this.updateModalData(obj);
}
//open modal when all done
@ -133,8 +126,6 @@ class ServiceModal {
}
});
console.log("input default");
this.selects.forEach((select) => {
let defaultVal = "";
try {
@ -170,7 +161,6 @@ class ServiceModal {
.click();
});
console.log("default select");
//server name always enabled for default
this.setNameSetting("ui", "");
}

View File

@ -50,7 +50,6 @@ class Tabs {
e.target.closest("button").hasAttribute("tab-handler") ||
e.target.closest("button").hasAttribute("tab-handler-mobile")
) {
console.log("tab clicked");
//get needed data
const tab = e.target.closest("button");
const tabAtt =

View File

@ -29,7 +29,7 @@
<div
plugin-item="{{plugin['id']}}"
id="{{plugin['id']}}"
class="hidden w-full"
class="{% if current_endpoint == "global-config" or current_endpoint != "global-config" and loop.index != 1 %}hidden{%endif%} w-full"
>
<!-- title and desc -->
<div class="col-span-12" setting-header>

View File

@ -68,7 +68,7 @@
<button
tab-handler="{{ plugin['id'] }}"
type="button"
class="z-1000 {% if current_endpoint == 'service' and loop.first %} brightness-90 {% endif %} border-primary dark:hover:bg-slate-800 dark:border-slate-600 dark:bg-slate-700 border my-1 relative inline-block px-3 py-3 font-bold text-center uppercase align-middle transition-all rounded-none cursor-pointer bg-white hover:bg-gray-100 leading-normal text-sm ease-in tracking-tight-rem shadow-xs hover:shadow-md"
class="z-1000 {% if current_endpoint != 'global-config' and loop.first %} brightness-90 {% endif %} border-primary dark:hover:bg-slate-800 dark:border-slate-600 dark:bg-slate-700 border my-1 relative inline-block px-3 py-3 font-bold text-center uppercase align-middle transition-all rounded-none cursor-pointer bg-white hover:bg-gray-100 leading-normal text-sm ease-in tracking-tight-rem shadow-xs hover:shadow-md"
>
<div class="w-full flex justify-between items-center">
<!-- text and icon -->