Commit 30a418f0 authored by Jiwon Yoon's avatar Jiwon Yoon
Browse files

timeTableId

parent 49fc2a67
...@@ -74,7 +74,6 @@ const Payment = ({ location }) => { ...@@ -74,7 +74,6 @@ const Payment = ({ location }) => {
userType: "member", userType: "member",
user: userInfo.id, user: userInfo.id,
...ticketInfo, ...ticketInfo,
timetableId: 1
}) })
const responsekakao = await kakaopayApi.approveReq({ const responsekakao = await kakaopayApi.approveReq({
cid: 'TC0ONETIME', cid: 'TC0ONETIME',
...@@ -100,7 +99,6 @@ const Payment = ({ location }) => { ...@@ -100,7 +99,6 @@ const Payment = ({ location }) => {
userType: "guest", userType: "guest",
user: guestID, user: guestID,
...ticketInfo, ...ticketInfo,
timetableId: 1
}) })
const responsekakao = await kakaopayApi.approveReq({ const responsekakao = await kakaopayApi.approveReq({
cid: 'TC0ONETIME', cid: 'TC0ONETIME',
......
...@@ -32,7 +32,7 @@ const TicketingSeatPage = ({ location }) => { ...@@ -32,7 +32,7 @@ const TicketingSeatPage = ({ location }) => {
useEffect(() => { useEffect(() => {
getInfo() getInfo()
}, []) }, [ticketInfo.timetableId])
useEffect(() => { useEffect(() => {
getTicketFee() getTicketFee()
...@@ -45,7 +45,7 @@ const TicketingSeatPage = ({ location }) => { ...@@ -45,7 +45,7 @@ const TicketingSeatPage = ({ location }) => {
theaterId: ticketInfo.selectedTheater theaterId: ticketInfo.selectedTheater
}) })
setTheaterInfo(response.data) setTheaterInfo(response.data)
const response2 = await reservationApi.findReservedSeats(1); const response2 = await reservationApi.findReservedSeats(ticketInfo.timetableId);
const reserve = response2.map((el) => const reserve = response2.map((el) =>
el.row + '-' + el.col el.row + '-' + el.col
); );
...@@ -181,7 +181,7 @@ const TicketingSeatPage = ({ location }) => { ...@@ -181,7 +181,7 @@ const TicketingSeatPage = ({ location }) => {
? <ul> ? <ul>
<li>영화: {ticketInfo.title}</li> <li>영화: {ticketInfo.title}</li>
<li>극장: {ticketInfo.cinema}</li> <li>극장: {ticketInfo.cinema}</li>
<li>일시: 2021/07/21 10:00 </li> <li>일시: {ticketInfo.time} </li>
<li>상영관: {ticketInfo.selectedTheater}</li> <li>상영관: {ticketInfo.selectedTheater}</li>
<li>좌석: {selectedSeats.map(el => String.fromCharCode(parseInt(el.split('-')[0]) + 64) + el.split('-')[1]) + ' '}</li> <li>좌석: {selectedSeats.map(el => String.fromCharCode(parseInt(el.split('-')[0]) + 64) + el.split('-')[1]) + ' '}</li>
</ul> </ul>
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment