From 33ed5cfc078aff54cbf4b0588aed24383b600066 Mon Sep 17 00:00:00 2001 From: chayoosang Date: Sun, 22 Oct 2023 13:07:25 +0900 Subject: [PATCH] =?UTF-8?q?[PDW-58]=20fix:=20=ED=9A=8C=EC=9D=98=EC=8B=A4?= =?UTF-8?q?=20=EB=B0=8F=20=EC=9E=90=EC=9B=90=20=EB=AA=A9=EB=A1=9D=20?= =?UTF-8?q?=EC=A1=B0=ED=9A=8C=20header=20=EA=B0=92=20=EC=B6=94=EA=B0=80?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/pages/booking/selectOffice/SelectOffice.js | 7 ++++++- src/pages/booking/selectResource/SelectResource.js | 7 ++++++- 2 files changed, 12 insertions(+), 2 deletions(-) diff --git a/src/pages/booking/selectOffice/SelectOffice.js b/src/pages/booking/selectOffice/SelectOffice.js index 01994d0..b350ff3 100644 --- a/src/pages/booking/selectOffice/SelectOffice.js +++ b/src/pages/booking/selectOffice/SelectOffice.js @@ -10,6 +10,7 @@ import SearchButtonImg from "../../../assets/images/button/searchButton.png"; import ImageButton from "../../../components/button/ImageButton"; import {SelectToggle} from "../../../components/capsule/SelectToggle"; import {TimeList} from "../../../constants/ToggleList"; +import {getToken} from "../../../utils/IsLoginUtil"; function SelectOffice(props) { @@ -22,7 +23,11 @@ function SelectOffice(props) { const [endTime, setEndTime] = useState(""); const getOfficeList = () => { - OfficesAxios.get("") + OfficesAxios.get("?size=200", { + headers: { + Authorization: getToken() + } + }) .then((Response) => { setOffices(Response.data.data.content) }) .catch((error) => {basicError(error)}) }; diff --git a/src/pages/booking/selectResource/SelectResource.js b/src/pages/booking/selectResource/SelectResource.js index 4ecbd43..97c1064 100644 --- a/src/pages/booking/selectResource/SelectResource.js +++ b/src/pages/booking/selectResource/SelectResource.js @@ -7,6 +7,7 @@ import ResourceInfo from "components/resourceInfo/ResourceInfo"; import { ResourcesAxios } from "api/AxiosApi"; import { useNavigate } from "react-router-dom"; import { basicError } from 'utils/ErrorHandlerUtil'; +import {getToken} from "../../../utils/IsLoginUtil"; export const SearchTitleContainer = styled.div` @@ -71,7 +72,11 @@ function SelectResource(props) { const [endDate, setEndDate] = useState(""); const getResourceList = () => { - ResourcesAxios.get() + ResourcesAxios.get("?size=200", { + headers: { + Authorization: getToken() + } + }) .then((Response) => { setResourceList(Response.data.data.content) }) .catch((error) => {basicError(error)}) };