From cf6dca4b7ca788111e1fd0cf36e25e7867b48c3f Mon Sep 17 00:00:00 2001
From: pawan-dot <71133473+pawan-dot@users.noreply.github.com>
Date: Fri, 27 Jan 2023 16:15:39 +0530
Subject: [PATCH] product complete
---
src/components/AppSidebar.js | 2 +-
src/index.js | 2 +-
src/views/configuration/cities/Cities.js | 4 ++--
src/views/configuration/states/States.js | 4 ++--
src/views/dashboard/Dashboard.js | 16 ++++++----------
5 files changed, 12 insertions(+), 16 deletions(-)
diff --git a/src/components/AppSidebar.js b/src/components/AppSidebar.js
index da51ca6..6f0481e 100644
--- a/src/components/AppSidebar.js
+++ b/src/components/AppSidebar.js
@@ -65,7 +65,7 @@ const AppSidebar = () => {
{/* */}
- {HeaderlogoUrl ?
ATP Dashboard}`} /> : ATP Dashboard
}
+ {HeaderlogoUrl ?
: ATP Dashboard
}
{/* */}
diff --git a/src/index.js b/src/index.js
index bc52aee..62a8094 100644
--- a/src/index.js
+++ b/src/index.js
@@ -12,7 +12,7 @@ import axios from 'axios'
const setupAxios = () => {
axios.defaults.baseURL = 'https://atpapi.checkapp.one'
- // axios.defaults.baseURL = 'http://localhost:5000'
+ //axios.defaults.baseURL = 'http://localhost:5000'
axios.defaults.headers = {
'Cache-Control': 'no-cache,no-store',
'Pragma': 'no-cache',
diff --git a/src/views/configuration/cities/Cities.js b/src/views/configuration/cities/Cities.js
index 2451325..0ca68b8 100644
--- a/src/views/configuration/cities/Cities.js
+++ b/src/views/configuration/cities/Cities.js
@@ -201,7 +201,7 @@ const Cities = () => {
btn btn-primary btn-sm
waves-effect waves-light
btn-table
- ml-2
+ me-1
"
>
Edit
@@ -220,7 +220,7 @@ const Cities = () => {
btn btn-danger btn-sm
waves-effect waves-light
btn-table
- ml-2
+ me-1
"
onClick={() => {
diff --git a/src/views/configuration/states/States.js b/src/views/configuration/states/States.js
index 77713eb..21380cc 100644
--- a/src/views/configuration/states/States.js
+++ b/src/views/configuration/states/States.js
@@ -201,7 +201,7 @@ const States = () => {
btn btn-primary btn-sm
waves-effect waves-light
btn-table
- ml-2
+ me-1
"
>
Edit
@@ -220,7 +220,7 @@ const States = () => {
btn btn-danger btn-sm
waves-effect waves-light
btn-table
- ml-2
+ me-1
"
onClick={() => {
diff --git a/src/views/dashboard/Dashboard.js b/src/views/dashboard/Dashboard.js
index aff2ff8..0d5c690 100644
--- a/src/views/dashboard/Dashboard.js
+++ b/src/views/dashboard/Dashboard.js
@@ -11,7 +11,7 @@ const Dashboard = () => {
const [users, setUsers] = useState([])
const token = isAutheticated();
- const getAllUsers = useCallback(async () => {
+ const getAllUsers = async () => {
let res = await axios.get(
`/api/v1/admin/users`,
{
@@ -24,7 +24,7 @@ const Dashboard = () => {
setUsers(res.data.users)
- }, [token]);
+ }
// //2nd
// const [category, setCategory] = useState([])
// const getAllCategory = useCallback(async () => {
@@ -106,14 +106,10 @@ const Dashboard = () => {
// }, [token]);
- // useEffect(() => {
- // getAllUsers();
- // getAllCategory()
- // getRequirement()
- // getNews()
- // getOffer()
- // getEvent()
- // }, [getAllUsers, getAllCategory, getRequirement, getNews, getOffer, getEvent]);
+ useEffect(() => {
+ getAllUsers();
+
+ }, [token]);
return (
<>