Skip to content

Commit

Permalink
[PDW-37] fix: 자원 예약하기 이미지 변경
Browse files Browse the repository at this point in the history
  • Loading branch information
chayoosang committed Oct 16, 2023
1 parent be29a8d commit c8fbf3d
Show file tree
Hide file tree
Showing 3 changed files with 4 additions and 13 deletions.
4 changes: 2 additions & 2 deletions src/components/resourceInfo/ResourceInfo.js
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@ function ResourceInfo(props) {
return (
<ResourceCard onClick={props.detail===true ? moveToDetail : {}}>
<DetailContainer>
<ResourceCardImage src={Example} />
<ResourceCardImage src={props.imgUrl} />

<InfoContainer>
<ResourceTitleContainer isHidden={props.isTItleHidden}>
Expand All @@ -47,4 +47,4 @@ function ResourceInfo(props) {
);
}

export default ResourceInfo;
export default ResourceInfo;
2 changes: 1 addition & 1 deletion src/pages/booking/selectResource/SelectResource.js
Original file line number Diff line number Diff line change
Expand Up @@ -121,7 +121,7 @@ function SelectResource(props) {

<WhiteContainer>
<div className="cardList">
{resourceList.length === 0 ? <label>예약 가능한 자원이 없습니다.</label> : resourceList.map((resource, index) => <ResourceInfo key={resource.index} detail={true} resourceId={resource.resourceId} name={resource.name} image={resource.imgUrl} category={resource.category} description={resource.description} />)}
{resourceList.length === 0 ? <label>예약 가능한 자원이 없습니다.</label> : resourceList.map((resource, index) => <ResourceInfo key={resource.index} detail={true} resourceId={resource.resourceId} name={resource.name} imgUrl={resource.imgUrl} category={resource.category} description={resource.description} />)}
</div>
</WhiteContainer>
</RightContainer>
Expand Down
11 changes: 1 addition & 10 deletions src/pages/manager/resourceManage/ResourceManageAdd.js
Original file line number Diff line number Diff line change
Expand Up @@ -196,17 +196,8 @@ function ResourceManageAdd(props) {
};

const getImageUrl = () => {



if (imageFile !== null) {
const data = {
'ext' : String(imageFile.type.split("/", 2)[1]),
'dir' : "photo"
};
const config = {"Content-Type": 'application/json'};

ImageUrlAxios.post("", data)
ImageUrlAxios.get(`?ext=${imageFile.type.split("/", 2)[1]}&dir=photo`)
.then((Response) => {
alert(Response)
})
Expand Down

0 comments on commit c8fbf3d

Please sign in to comment.