diff --git a/web/html/users.html b/web/html/users.html index 648d80b..5f4aa59 100644 --- a/web/html/users.html +++ b/web/html/users.html @@ -176,7 +176,7 @@ - + diff --git a/web/js/users.js b/web/js/users.js index 290b3f3..f53281c 100644 --- a/web/js/users.js +++ b/web/js/users.js @@ -120,9 +120,11 @@ instance.get("users", {withCredentials: true, params:param}).then(function(respo } td[5].querySelector(".activeStatus").classList.add("hidden"); td[5].querySelector(classTd).classList.remove("hidden"); + + td[6].querySelector("button").setAttribute("userid", listData[i].id) - trAll[i].addEventListener("click", function(e){ - var id = e.currentTarget.querySelectorAll("td")[1].textContent; + td[6].querySelector("button").addEventListener("click", function(e){ + var id = e.currentTarget.getAttribute("userid"); location.href="/html/user.html?id="+id; });