added admin panel & fixed user registration

This commit is contained in:
2023-06-28 17:39:19 +05:00
parent 4538d122c5
commit 73630d4bb6
7 changed files with 81 additions and 44 deletions

View File

@ -30,7 +30,7 @@
left.innerHTML += `<div id="user_name">${res["login"]}</div>`;
if (res["admin"] == true){
right.innerHTML += "<button>admin panel</button>";
right.innerHTML += `<button onclick='goto("/admin")'>admin panel</button>`;
}
right.innerHTML += "<button onclick='logout();'>logout</button>";
});