diff --git a/public/assets/js/dashboards-analytics.js b/public/assets/js/dashboards-analytics.js
index 7d183a89..8e8b443e 100644
--- a/public/assets/js/dashboards-analytics.js
+++ b/public/assets/js/dashboards-analytics.js
@@ -7,7 +7,7 @@
function projectCardChart(project) {
// Order Statistics Chart
// --------------------------------------------------------------------
- console.log(project);
+
let cardColor, headingColor, axisColor, shadeColor, borderColor;
cardColor = config.colors.cardColor;
diff --git a/public/js/helpers.js b/public/js/helpers.js
index 4c76b499..1093b30c 100644
--- a/public/js/helpers.js
+++ b/public/js/helpers.js
@@ -523,7 +523,6 @@ var Helpers = {
// ---
// Toggle layout
toggleCollapsed(animate = true) {
- console.log('a');
this.setCollapsed(!this.isCollapsed(), animate)
},
diff --git a/src/components/Activities/ReportTaskComments.jsx b/src/components/Activities/ReportTaskComments.jsx
index cf30540e..bf651ccf 100644
--- a/src/components/Activities/ReportTaskComments.jsx
+++ b/src/components/Activities/ReportTaskComments.jsx
@@ -73,7 +73,6 @@ const ReportTaskComments = ({ commentsData, closeModal }) => {
// closeModal();
} catch (error) {
setloading(false);
- console.log(error);
showToast(error.response.data?.message || "Something wrong", "error");
}
};
diff --git a/src/components/Directory/ManageDirectory.jsx b/src/components/Directory/ManageDirectory.jsx
index 6c6b41e4..5eae91af 100644
--- a/src/components/Directory/ManageDirectory.jsx
+++ b/src/components/Directory/ManageDirectory.jsx
@@ -65,7 +65,7 @@ const ManageDirectory = () => {
}, [emailFields.length, phoneFields.length]);
const onSubmit = (data) => {
- console.log("Submitted:\n" + JSON.stringify(data, null, 2));
+ // console.log("Submitted:\n" + JSON.stringify(data, null, 2));
};
const handleAddEmail = async () => {
diff --git a/src/components/Employee/EmpProfile.jsx b/src/components/Employee/EmpProfile.jsx
index 63a47e43..2348aa82 100644
--- a/src/components/Employee/EmpProfile.jsx
+++ b/src/components/Employee/EmpProfile.jsx
@@ -74,7 +74,6 @@ function EmpProfile({ addOrEdit }) {
alert("Form submitted successfully!");
}
} catch (error) {
- console.error("Error submitting form:", error);
alert("Failed to submit form.");
}
};
diff --git a/src/components/Layout/Sidebar.jsx b/src/components/Layout/Sidebar.jsx
index cc497719..d17249f1 100644
--- a/src/components/Layout/Sidebar.jsx
+++ b/src/components/Layout/Sidebar.jsx
@@ -12,7 +12,6 @@ const Sidebar = () => {
// };
// const handleProfilePage = ()=>{
- // console.log(profile?.employeeInfo?.id)
// navigate(`/employee/${profile?.employeeInfo?.id}?for=account`)
// }
return (
diff --git a/src/components/Project/InfraCard.jsx b/src/components/Project/InfraCard.jsx
index 96bb09e1..fda54012 100644
--- a/src/components/Project/InfraCard.jsx
+++ b/src/components/Project/InfraCard.jsx
@@ -2,7 +2,6 @@ import React from "react";
import AccordionContainer from "../common/AccordionContainer";
const InfraCard = ({ project, building }) => {
- //console.log(building);
const handleViewProject = (e) => {
e.preventDefault(); // Prevent default anchor behavior (e.g., page reload)
window.location.href = "/projects/" + project.id;
diff --git a/src/components/Project/Infrastructure/FloorModel.jsx b/src/components/Project/Infrastructure/FloorModel.jsx
index 7e5a81b1..42e10123 100644
--- a/src/components/Project/Infrastructure/FloorModel.jsx
+++ b/src/components/Project/Infrastructure/FloorModel.jsx
@@ -56,7 +56,6 @@ const FloorModel = ({
// Handle building selection change
const handleBuildigChange = (e) => {
const buildingId = e.target.value;
- console.log(buildingId)
const building = buildings.find((b) => b.id === Number(buildingId));
if (building) {
setSelectedBuilding(building);
diff --git a/src/components/Project/ManageProject.jsx b/src/components/Project/ManageProject.jsx
index 728d1989..7bcef356 100644
--- a/src/components/Project/ManageProject.jsx
+++ b/src/components/Project/ManageProject.jsx
@@ -18,7 +18,6 @@ const ManageProject = () => {
// Handle form submission
const handleSubmit = (e) => {
e.preventDefault();
- console.log("Project Created:", projectData); // You can replace this with an API call
setIsProjectCreated(true);
};
diff --git a/src/components/Project/ProjectInfra copy.jsx b/src/components/Project/ProjectInfra copy.jsx
index efc7e923..49190972 100644
--- a/src/components/Project/ProjectInfra copy.jsx
+++ b/src/components/Project/ProjectInfra copy.jsx
@@ -4,9 +4,7 @@ import AccordionContainer from "../common/AccordionContainer";
const ProjectInfraCopy = ({ data }) => {
if (!data) {
return
No data available yet...
;
- } else {
- console.log(data, "inside infra");
- }
+ }
return (
{" "}
diff --git a/src/components/Project/ProjectInfra.jsx b/src/components/Project/ProjectInfra.jsx
index 652b3dc7..0c8eadac 100644
--- a/src/components/Project/ProjectInfra.jsx
+++ b/src/components/Project/ProjectInfra.jsx
@@ -294,7 +294,6 @@ const ProjectInfra = ({
console.error("Unsupported data type for submitData", entity);
}
} catch (Err) {
- console.log(Err);
showToast("Somthing wrong", "error");
}
handleClose();
diff --git a/src/components/common/DatePicker.jsx b/src/components/common/DatePicker.jsx
index d4a1b22f..7003ab78 100644
--- a/src/components/common/DatePicker.jsx
+++ b/src/components/common/DatePicker.jsx
@@ -8,7 +8,6 @@ const DatePicker = ({ onDateChange }) => {
dateFormat: "Y-m-d",
defaultDate: new Date(),
onChange: (selectedDates, dateStr) => {
- console.log("Selected date:", dateStr);
if (onDateChange) {
onDateChange(dateStr); // Pass selected date to parent
}
diff --git a/src/components/master/CreateActivity.jsx b/src/components/master/CreateActivity.jsx
index 2970d0c1..c55d87ce 100644
--- a/src/components/master/CreateActivity.jsx
+++ b/src/components/master/CreateActivity.jsx
@@ -56,7 +56,6 @@ const CreateActivity = ({ onClose }) => {
// Form submission handler
const onSubmit = (data) => {
- console.log(data);
setIsLoading(true);
MasterRespository.createActivity(data)
diff --git a/src/components/master/EditActivity.jsx b/src/components/master/EditActivity.jsx
index bccdbd2f..09a708be 100644
--- a/src/components/master/EditActivity.jsx
+++ b/src/components/master/EditActivity.jsx
@@ -93,7 +93,6 @@ const UpdateActivity = ({ activityData, onClose }) => {
setIsLoading( false )
showToast("error.message", "error");
- console.log(err)
}
};
diff --git a/src/hooks/usePositionTracker.js b/src/hooks/usePositionTracker.js
index 009b5e04..f5d122d0 100644
--- a/src/hooks/usePositionTracker.js
+++ b/src/hooks/usePositionTracker.js
@@ -10,7 +10,6 @@ export const usePositionTracker = () => {
},
(error) => {
alert(error.message);
- console.log(error);
},
{ enableHighAccuracy: true, timeout: 20000, maximumAge: 1000 }
);
diff --git a/src/hooks/useTasks.js b/src/hooks/useTasks.js
index 3051acea..c7ea9c37 100644
--- a/src/hooks/useTasks.js
+++ b/src/hooks/useTasks.js
@@ -23,7 +23,6 @@ export const useTaskList = (projectId, dateFrom, toDate) => {
setLoading(false);
} catch (err) {
setLoading(false);
- console.log(err);
setError(err);
}
// } else {
diff --git a/src/pages/Activities/TaskPlannng.jsx b/src/pages/Activities/TaskPlannng.jsx
index ae97d4e3..3072abb1 100644
--- a/src/pages/Activities/TaskPlannng.jsx
+++ b/src/pages/Activities/TaskPlannng.jsx
@@ -68,7 +68,6 @@ const TaskPlannng = () => {
setProjectDetails(project_cache);
}
} catch (err) {
- console.log(err)
setError("Failed to fetch data.");
} finally {
setLoading(false);
diff --git a/src/pages/authentication/LoginPage.jsx b/src/pages/authentication/LoginPage.jsx
index 92d03ba6..8ba33fca 100644
--- a/src/pages/authentication/LoginPage.jsx
+++ b/src/pages/authentication/LoginPage.jsx
@@ -45,7 +45,6 @@ const LoginPage = () => {
navigate("/dashboard");
} catch (err) {
showToast("Invalid username or password.","error")
- console.log("Unable to proceed. Please try again.");
setLoading(false);
}
};
diff --git a/src/pages/authentication/RegisterPage.jsx b/src/pages/authentication/RegisterPage.jsx
index 63bafa6b..16517816 100644
--- a/src/pages/authentication/RegisterPage.jsx
+++ b/src/pages/authentication/RegisterPage.jsx
@@ -51,7 +51,6 @@ const RegisterPage = () => {
showToast("Your Registration SuccessFully !");
setRegristered(true);
} catch (error) {
- // console.log(error);
showToast(error.message, "error");
}
};
diff --git a/src/pages/employee/EmployeeProfile.jsx b/src/pages/employee/EmployeeProfile.jsx
index e53eeeb2..9e5debc7 100644
--- a/src/pages/employee/EmployeeProfile.jsx
+++ b/src/pages/employee/EmployeeProfile.jsx
@@ -38,7 +38,6 @@ const EmployeeProfile = () => {
} catch ( err )
{
- console.log( "Faild to fetch employee data,", err )
setLoading(false)
}
diff --git a/src/pages/employee/ManageEmp.jsx b/src/pages/employee/ManageEmp.jsx
index b9511784..7b3ab1f0 100644
--- a/src/pages/employee/ManageEmp.jsx
+++ b/src/pages/employee/ManageEmp.jsx
@@ -6,7 +6,7 @@ import { getCachedData } from "../../slices/apiDataManager";
const ManageEmp = () => {
const onEmployeeSubmt = () => {
- console.log("employee submit clicked");
+ // console.log("employee submit clicked");
};
return (
diff --git a/src/utils/axiosClient.jsx b/src/utils/axiosClient.jsx
index 80d2d34e..faa97157 100644
--- a/src/utils/axiosClient.jsx
+++ b/src/utils/axiosClient.jsx
@@ -55,7 +55,6 @@ axiosClient.interceptors.response.use(
if (error.config.url.indexOf("refresh-token") != -1) {
//showToast("Server is unreachable. Try again later!", "error");
- console.log("1 - error fetching refresh token :", error);
} else {
showToast(
"Unable to connect to the server. Please try again later.",
@@ -66,7 +65,6 @@ axiosClient.interceptors.response.use(
console.error("Network error: Unable to reach the server.");
if (error.config.url.indexOf("refresh-token") != -1) {
//showToast("Server is unreachable. Try again later!", "error");
- console.log("2 - error fetching refresh token :", error);
}
redirectToLogin();
} else if (error.code === "ECONNABORTED") {
@@ -74,7 +72,6 @@ axiosClient.interceptors.response.use(
if (error.config.url.indexOf("refresh-token") != -1) {
//showToast("Server is unreachable. Try again later!", "error");
- console.log("3 - error fetching refresh token :", error);
} else {
showToast(
"The request took too long. Please try again later.",
@@ -84,7 +81,6 @@ axiosClient.interceptors.response.use(
} else if (error.response) {
if (error.config.url.indexOf("refresh-token") != -1) {
//showToast("Server is unreachable. Try again later!", "error");
- console.log("4 - error fetching refresh token :", error);
}
// else {
// // showToast(error.response.data.message, "error"); // repeted toast
@@ -107,7 +103,7 @@ axiosClient.interceptors.response.use(
refreshToken,
})
.catch((error) => {
- console.log("7 - error fetching refresh token :", error);
+ // console.log("7 - error fetching refresh token :", error);
});
const { token, refreshToken: newRefreshToken } = response.data.data;
@@ -120,10 +116,7 @@ axiosClient.interceptors.response.use(
// Retry the original request
return axiosClient(originalRequest);
} catch (err) {
- console.log(
- "5 - error fetching refresh token during refresh call :",
- error
- );
+
// Redirect to login if token refresh fails
redirectToLogin();
return Promise.reject(err);
@@ -131,7 +124,7 @@ axiosClient.interceptors.response.use(
} else {
if (error.config.url.indexOf("refresh-token") != -1) {
//showToast("Server is unreachable. Try again later!", "error");
- console.log("6 - error fetching refresh token :", error);
+ // console.log("6 - error fetching refresh token :", error);
}
// showToast(
// error.response.data?.message ||
diff --git a/src/utils/errorUtil.jsx b/src/utils/errorUtil.jsx
index 1056ca28..f404af75 100644
--- a/src/utils/errorUtil.jsx
+++ b/src/utils/errorUtil.jsx
@@ -1,6 +1,5 @@
// utils/dateUtils.js
export const logInfo = (message) => {
- console.log(message);
};
export const logError = (e, message) => {