From fe0157437e649ea093e98371d0e2e2203accdda2 Mon Sep 17 00:00:00 2001 From: minuk926 Date: Thu, 7 Apr 2022 17:01:28 +0900 Subject: [PATCH] fix : router fix --- src/apis/user.js | 2 +- src/routes/MainRoutes.js | 16 +++++++++++++--- src/views/biz/user/UserManager.jsx | 4 ++-- 3 files changed, 16 insertions(+), 6 deletions(-) diff --git a/src/apis/user.js b/src/apis/user.js index 0186cbd..22e650d 100644 --- a/src/apis/user.js +++ b/src/apis/user.js @@ -3,7 +3,7 @@ //---------------------- import axios from 'utils/axios'; -import { GET_USER_BOARD_LIST, SAVE_USER_BOARD, DELETE_USER_BOARD } from 'commons/ApiUrl'; +import { GET_USER_BOARD_LIST } from 'commons/ApiUrl'; import { setRowId } from './common'; // eslint-disable-next-line import/prefer-default-export diff --git a/src/routes/MainRoutes.js b/src/routes/MainRoutes.js index d38c34a..a7f477a 100755 --- a/src/routes/MainRoutes.js +++ b/src/routes/MainRoutes.js @@ -4,7 +4,6 @@ import { lazy } from 'react'; import MainLayout from 'layout/MainLayout'; import Loadable from 'ui-component/Loadable'; import AuthGuard from 'utils/route-guard/AuthGuard'; -import ResidentDataReview from '../views/biz/resident/Review'; // sample page routing const SamplePage = Loadable(lazy(() => import('views/sample-page'))); @@ -14,9 +13,20 @@ const DashboardAnalytics = Loadable(lazy(() => import('views/dashboard/Analytics // opst page routing const PublicBoard = Loadable(lazy(() => import('views/biz/board/PublicBoard'))); const Board = Loadable(lazy(() => import('views/biz/board/Board'))); -const ParkingReview = Loadable(lazy(() => import('views/biz/parking/Review'))); + +// parking +const ParkingReview = Loadable(lazy(() => import('views/biz/parking/ParkingReview'))); const ParkingDetails = Loadable(lazy(() => import('views/biz/parking/ModalDetails'))); -const ParkingRegister = Loadable(lazy(() => import('views/biz/parking/Regist'))); +const ParkingRegister = Loadable(lazy(() => import('views/biz/parking/ParkingRegister'))); + +// resident +const ResidentDataReview = Loadable(lazy(() => import('views/biz/resident/ResidentDataReview'))); +const ResidentRegister = Loadable(lazy(() => import('views/biz/resident/ResidentRegist'))); +const ResidentReview = Loadable(lazy(() => import('views/biz/resident/ResidentReview'))); + +// user +const UserManager = Loadable(lazy(() => import('views/biz/user/UserManager'))); +const Juror = Loadable(lazy(() => import('views/biz/user/Juror'))); // component const ModalForm = Loadable(lazy(() => import('views/form/Modal'))); diff --git a/src/views/biz/user/UserManager.jsx b/src/views/biz/user/UserManager.jsx index 307d3c3..62f4e9d 100644 --- a/src/views/biz/user/UserManager.jsx +++ b/src/views/biz/user/UserManager.jsx @@ -14,7 +14,7 @@ import MuiDataGrid from 'views/form/MuiDataGrid'; import { getBoardList } from '../../../apis/user'; import CmmModal from '../../form/Modal/CmmModal'; import UserManagerForm from './UserManagerForm'; -import { deletePublicBoard, getPublicBoardList, modifyPublicBoardHitCount, savePublicBoard } from '../../../apis/public'; +import { deletePublicBoard, findPublicBoards, modifyPublicBoardHitCount, savePublicBoard } from 'apis/public'; const UserManager = () => { const [category, setCategory] = useState('ciTitle'); @@ -66,7 +66,7 @@ const UserManager = () => { size: rowsState.pageSize }; - getPublicBoardList(params).then((response) => { + findPublicBoards(params).then((response) => { // console.log(response); if (response && response.data) { setTotalCount(response.count);