Skip to content

Commit

Permalink
Merge pull request #69 from URECA-PODONG/feat/#6
Browse files Browse the repository at this point in the history
Feat(#6):결제6차수정
  • Loading branch information
Suh-code authored Nov 5, 2024
2 parents 762df63 + a17d59e commit 372dc0c
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 9 deletions.
2 changes: 1 addition & 1 deletion src/data/recommendRoutes.js
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ export const RecommendRoutes = [
id: 1,
name: "한강공원 코스",
distance: "3.5km",
time: "45분",
time: "45분",
routeData: {
center: { lat: 37.5665, lng: 126.978 },
start: { lat: 37.566, lng: 126.977 },
Expand Down
15 changes: 7 additions & 8 deletions src/pages/PaymentPage/PaymentEnd.jsx
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
import React, { useEffect, useState } from 'react';
import React, { useEffect, useState, useLocation } from 'react';
import styled from 'styled-components';
import Lottie from 'lottie-react';
import PaymentAnimation from '../PaymentPage/PaymentAnimation.json';
Expand Down Expand Up @@ -201,13 +201,15 @@ DeliveryInfoRow.propTypes = {
value: PropTypes.string.isRequired,
};

const userId = 1;


const PaymentEnd = () => {
const [buyer, setBuyer] = useState('');
const [phone, setPhone] = useState('');
const [address, setAddress] = useState('');

// const location = useLocation();
// const userId = location.state?.userId || localStorage.getItem('userId');
const userId = localStorage.getItem('userId');
useEffect(() => {
const getInfo = async () => {
try {
Expand All @@ -230,7 +232,7 @@ const PaymentEnd = () => {
<PaymentEndHeader>주문 완료</PaymentEndHeader>

<ImageContainer>
<Lottie animationData={PaymentAnimation} style={{ width: '230px', height: '230px' }} />
<Lottie animationData={PaymentAnimation} style={{ width: '250px', height: '250px' }} />
</ImageContainer>
<Header>
우리응애가 좋아할 선물 <br />
Expand Down Expand Up @@ -262,10 +264,7 @@ const PaymentEnd = () => {
<DeliveryInfoRow label="수령인" value={buyer} />
<DeliveryInfoRow label="휴대폰" value={phone} />
<DeliveryInfoRow label="배송지" value={address} />
<AddressInputWrapper>
<AddressInput type="text" placeholder="배송지 출입 방법" />
<EditButton>수정</EditButton>
</AddressInputWrapper>

</Section>

<OrderDetailButton primary>주문상세보기</OrderDetailButton>
Expand Down

0 comments on commit 372dc0c

Please sign in to comment.