diff --git a/src/pages/Porjects/components/listProjects.jsx b/src/pages/Porjects/components/listProjects.jsx index 03d0567..76c50e9 100644 --- a/src/pages/Porjects/components/listProjects.jsx +++ b/src/pages/Porjects/components/listProjects.jsx @@ -10,7 +10,7 @@ import axios from "axios"; const token = localStorage.getItem("authToken"); -// console.log("token: " + token) +// console.log() const { headers } = [ { @@ -30,9 +30,9 @@ try { 'Content-Type': 'application/json; charset=utf-8', } }) - console.log(response) - console.log('user id:', response.data.data.result[0]._id); - userID = response.data.data.result[0]._id;} + // console.log(response) + // console.log('user id:', response.data.result[0]._id); + userID = response.data.result[0]._id;} catch(error) { console.error('error: ', error.message); }; @@ -56,6 +56,7 @@ export default function ListProject() { axios.get(UrlDataBoard, { headers }) .then(response => { setProjectsList(response.data) + // console.log("Mendy", response.data) }) .catch(error => { diff --git a/src/pages/create-project/components/createProject.jsx b/src/pages/create-project/components/createProject.jsx index 9b1c369..caae65a 100644 --- a/src/pages/create-project/components/createProject.jsx +++ b/src/pages/create-project/components/createProject.jsx @@ -9,12 +9,13 @@ import { Project } from "../../Porjects/components/Project"; import axios from "axios"; const UrlDataBoard = `${api}/board/create`; + const headers = { 'Authorization': 'Happy', 'Content-Type': 'application/json; charset=utf-8' }; const token = localStorage.getItem("authToken"); -console.log("token: " + token) +// console.log("token: " + token) let userID = ''; @@ -27,7 +28,7 @@ try { } }) // console.log('user id:', response.data.result[0]._id); - userID = response.data.data.result[0]._id;} + userID = response.data.result[0]._id;} catch(error) { console.error('error: ', error.message); }; @@ -35,7 +36,7 @@ try { export default function CreateProject() { const { id } = useParams(); - console.log(id); + // console.log(id); const [isSaved, setSaved] = useState(false)