add user management features: implement user creation, editing, and deletion; enhance dashboard with user selection prompt; improve token verification and alert handling

This commit is contained in:
2025-08-31 20:02:51 +02:00
parent 217803ba8f
commit c77bef5cf3
10 changed files with 527 additions and 9 deletions

View File

@@ -0,0 +1,11 @@
import Cookies from "js-cookie";
export const fetchUserData = async () => {
const response = await fetch("http://localhost:8002/api/allUsers", {
headers: {
Authorization: `Bearer ${Cookies.get("token")}`,
},
});
const data = await response.json();
return data;
};