diff --git a/web/html/user.html b/web/html/user.html
index 4d3b390..2519a17 100644
--- a/web/html/user.html
+++ b/web/html/user.html
@@ -150,7 +150,7 @@
-
- Pseudo
-
+ Pseudo
+
diff --git a/web/js/user.js b/web/js/user.js
index 842268e..3a63a0b 100644
--- a/web/js/user.js
+++ b/web/js/user.js
@@ -6,7 +6,7 @@ var id = getQuery("id");
if(id.length > 0){
instance.get("users/"+id, {withCredentials: true})
.then(function(response){
- var listValue = [ "id", "pseudo", "name", "firstName", "email", "birth"];
+ var listValue = [ "id", "username", "name", "firstName", "email", "birth"];
var listTime = ["connected_at", "created_at", "updated_at", "deleted_at"];
for (var i=0; i 0){
switch(e.currentTarget.id){
case "disableUserButton":
httpMethod = "delete";
- httpUrl = "users/disable/"+idInput;
+ httpUrl = "users/"+idInput;
break;
case "removeUserButton":
httpMethod = "delete";
@@ -101,7 +101,7 @@ if(id.length > 0){
document.getElementById("updateUserButton").addEventListener("click", function(){
- var updateProfil = ["id", "pseudo", "email", "firstName", "birth"];
+ var updateProfil = ["id", "username", "email", "firstName", "birth"];
var updateOk = true;
for (var i=0; i 0){
dataPut = {
"id": id,
- "pseudo": document.getElementById("pseudoUpdateInput").value,
+ "username": document.getElementById("usernameUpdateInput").value,
"email": document.getElementById("emailUpdateInput").value,
"name": document.getElementById("nameUpdateInput").value,
"firstName": document.getElementById("firstNameUpdateInput").value,
@@ -139,8 +139,8 @@ if(id.length > 0){
}
instance({
- method : "patch",
- url:"users/"+id,
+ method : "put",
+ url:"users",
withCredentials: true,
data: dataPut
}).then(function(response){
diff --git a/web/js/users.js b/web/js/users.js
index 1f697ca..ebe955f 100644
--- a/web/js/users.js
+++ b/web/js/users.js
@@ -97,7 +97,7 @@ instance.get("users", {withCredentials: true, params :param}).then(function(resp
var trAll = document.querySelectorAll("#users tbody tr")
td = trAll[i].querySelectorAll("td");
td[0].textContent = listData[i].id;
- td[1].textContent = listData[i].pseudo;
+ td[1].textContent = listData[i].username;
td[2].textContent = listData[i].email;
td[3].textContent = listData[i].roles;
var classTd = "";