diff --git a/src/commons/ApiUrl.js b/src/commons/ApiUrl.js index 4e425d4..a3dc57b 100644 --- a/src/commons/ApiUrl.js +++ b/src/commons/ApiUrl.js @@ -1,53 +1,53 @@ // const URL = process.env.NODE_ENV !== 'development' ? process.env.REACT_APP_API_URL : '' // console.log(process.env.NODE_ENV) -export const LOGIN_URL = '/api/v2/ctgy/account/login'; -export const GET_CMM_CODE_LIST = '/api/v2/biz/cmm/combo'; -export const GET_FILE_DOWNLOAD = '/api/v2/ctgy/file/download/'; +export const LOGIN_URL = '/api/v1/ctgy/account/login'; +export const GET_CMM_CODE_LIST = '/api/v1/biz/cmm/combo'; +export const GET_FILE_DOWNLOAD = '/api/v1/ctgy/file/download/'; -export const GET_DASHBOARD = '/api/v2/ctgy/dashboard'; +export const GET_DASHBOARD = '/api/v1/ctgy/dashboard'; // 공지사항 -export const GET_PUBLIC_BOARD_LIST = '/api/v2/ctgy/pboard'; -export const SAVE_PUBLIC_BOARD_HIT_CNT = '/api/v2/ctgy/pboard/hit/'; -export const SAVE_PUBLIC_BOARD = '/api/v2/ctgy/file/pboard'; -export const REMOVE_PUBLIC_BOARD = '/api/v2/ctgy/file/pboard/'; +export const GET_PUBLIC_BOARD_LIST = '/api/v1/ctgy/pboard'; +export const SAVE_PUBLIC_BOARD_HIT_CNT = '/api/v1/ctgy/pboard/hit/'; +export const SAVE_PUBLIC_BOARD = '/api/v1/ctgy/file/pboard'; +export const REMOVE_PUBLIC_BOARD = '/api/v1/ctgy/file/pboard/'; // 게시판 -export const GET_BOARD_LIST = '/api/v2/ctgy/board'; -export const SAVE_BOARD_HIT_CNT = '/api/v2/ctgy/board/hit/'; -export const SAVE_BOARD = '/api/v2/ctgy/board'; -export const REMOVE_BOARD = '/api/v2/ctgy/board/'; +export const GET_BOARD_LIST = '/api/v1/ctgy/board'; +export const SAVE_BOARD_HIT_CNT = '/api/v1/ctgy/board/hit/'; +export const SAVE_BOARD = '/api/v1/ctgy/board'; +export const REMOVE_BOARD = '/api/v1/ctgy/board/'; // 주정차 의견 진술 -export const GET_PARKING_LIST = '/api/v2/ctgy/parking'; -export const GET_PARKING_JUDGE_RESULT_LIST = '/api/v2/ctgy/parking/result'; -export const GET_PARKING_JUDGE_TARGET_LIST = '/api/v2/ctgy/parking/target'; -export const SAVE_PARKING_JUDGE_TARGET_LIST = '/api/v2/ctgy/parking/target'; -export const REMOVE_PARKING_JUDGE = '/api/v2/ctgy/parking/remove'; +export const GET_PARKING_LIST = '/api/v1/ctgy/parking'; +export const GET_PARKING_JUDGE_RESULT_LIST = '/api/v1/ctgy/parking/result'; +export const GET_PARKING_JUDGE_TARGET_LIST = '/api/v1/ctgy/parking/target'; +export const SAVE_PARKING_JUDGE_TARGET_LIST = '/api/v1/ctgy/parking/target'; +export const REMOVE_PARKING_JUDGE = '/api/v1/ctgy/parking/remove'; -export const GET_PARKING_JUDGE_LIST = '/api/v2/ctgy/parking/judge'; +export const GET_PARKING_JUDGE_LIST = '/api/v1/ctgy/parking/judge'; // 거주자/장애인 의견 진술 -export const GET_ADMIN_JUDGE_DATA_LIST = '/api/v2/ctgy/admin/data'; -export const SAVE_ADMIN_JUDGE_DATA = '/api/v2/ctgy/admin/data'; -export const GET_ADMIN_JUDGE_DATA = '/api/v2/ctgy/admin/data/'; -export const REMOVE_ADMIN_JUDGE_DATA = '/api/v2/ctgy/admin/data/remove'; +export const GET_ADMIN_JUDGE_DATA_LIST = '/api/v1/ctgy/admin/data'; +export const SAVE_ADMIN_JUDGE_DATA = '/api/v1/ctgy/admin/data'; +export const GET_ADMIN_JUDGE_DATA = '/api/v1/ctgy/admin/data/'; +export const REMOVE_ADMIN_JUDGE_DATA = '/api/v1/ctgy/admin/data/remove'; -export const GET_ADMIN_JUDGE_LIST = '/api/v2/ctgy/admin'; -export const GET_ADMIN_JUDGE_RESULT_LIST = '/api/v2/ctgy/admin/result'; +export const GET_ADMIN_JUDGE_LIST = '/api/v1/ctgy/admin'; +export const GET_ADMIN_JUDGE_RESULT_LIST = '/api/v1/ctgy/admin/result'; -export const GET_ADMIN_JUDGE_TARGET_LIST = '/api/v2/ctgy/admin/target'; -export const SAVE_ADMIN_JUDGE_TARGET_LIST = '/api/v2/ctgy/admin/target'; -export const REMOVE_ADMIN_JUDGE = '/api/v2/ctgy/admin/remove'; +export const GET_ADMIN_JUDGE_TARGET_LIST = '/api/v1/ctgy/admin/target'; +export const SAVE_ADMIN_JUDGE_TARGET_LIST = '/api/v1/ctgy/admin/target'; +export const REMOVE_ADMIN_JUDGE = '/api/v1/ctgy/admin/remove'; -export const SAVE_ADMIN_JUDGE_STDS = '/api/v2/ctgy/admin/judge'; +export const SAVE_ADMIN_JUDGE_STDS = '/api/v1/ctgy/admin/judge'; -export const GET_JUDGE_LIST = '/api/v2/ctgy/judge'; -export const SAVE_JUDGE_RESULT = '/api/v2/ctgy/judge'; +export const GET_JUDGE_LIST = '/api/v1/ctgy/judge'; +export const SAVE_JUDGE_RESULT = '/api/v1/ctgy/judge'; -export const GET_JUDGE_FILE_DOWNLOAD = '/api/v2/ctgy/cmm/download/judge'; +export const GET_JUDGE_FILE_DOWNLOAD = '/api/v1/ctgy/cmm/download/judge'; // 사용자 관리 -export const GET_USER_LIST = '/api/v2/ctgy/user'; -export const SAVE_USER = '/api/v2/ctgy/user'; -export const REMOVE_USER = '/api/v2/ctgy/user'; +export const GET_USER_LIST = '/api/v1/ctgy/user'; +export const SAVE_USER = '/api/v1/ctgy/user'; +export const REMOVE_USER = '/api/v1/ctgy/user'; diff --git a/src/contexts/JWTContext.js b/src/contexts/JWTContext.js index a7d3ad6..86880cc 100755 --- a/src/contexts/JWTContext.js +++ b/src/contexts/JWTContext.js @@ -62,7 +62,7 @@ export const JWTProvider = ({ children }) => { // TODO: verifyToken ?? if (accessToken && verifyToken(accessToken)) { setLocalStorage(ACCESS_TOKEN_NAME, accessToken); - const response = await axios.get('/api/v2/ctgy/user/info'); + const response = await axios.get('/api/v1/ctgy/user/info'); console.log(response); // TODO : 적용 필요 const { userid, email, name, accesstype } = response.data;