ShoppingCart.js 4.83 KB
Newer Older
Kim, Subin's avatar
Kim, Subin committed
1
import React, { useState, useEffect, useRef } from 'react';
Kim, Subin's avatar
Kim, Subin committed
2
3
4
import { Redirect } from 'react-router-dom';
import MainNav from '../Components/MainNav';
import SubNav from '../Components/SubNav';
5
import { Card, Button, Container, Row, Col } from 'react-bootstrap';
Kim, Subin's avatar
Kim, Subin committed
6
7
8
9
10

function ShoppingCart() {

    return (
        <div>
Kim, Subin's avatar
Kim, Subin committed
11
12
            <MainNav />
            <SubNav />
13
            <Container className="justify-content-center">
Jiwon Yoon's avatar
Jiwon Yoon committed
14
                <h3 className="my-5 font-weight-bold text-center">장바구니</h3>
15
                <div>
Jiwon Yoon's avatar
Jiwon Yoon committed
16
                    <h4 className="font-weight-bold py-3 border-top border-bottom text-center" style={{ background: '#F7F3F3' }}>주문상품정보</h4>
17
18
19
20
21
22
23
24
                    <Card >
                        <Row>
                            <Col>
                                <input className="mx-5" type="checkbox" id="exampleCheck1"></input>
                                <Card.Img className="img-fluid" variant="top" src="img/asd.jpg" style={{ width: '20rem' }} />
                            </Col>
                            <Col md={6}>
                                <Card.Body>
Jiwon Yoon's avatar
Jiwon Yoon committed
25
                                    <input type="image" src="https://img.icons8.com/fluent-systems-regular/24/000000/close-window.png" className="float-right" />
26
27
28
29
30
                                    <Card.Title className="font-weight-bold mt-3">제품명</Card.Title>
                                    <Card.Text>가격</Card.Text>
                                    <Card.Text>옵션</Card.Text>
                                    <Card.Text>수량</Card.Text>
                                    <div>
Jiwon Yoon's avatar
Jiwon Yoon committed
31
32
33
                                        <input type="image" src="https://img.icons8.com/ios-glyphs/20/000000/minus-math.png" />
                                        <input type="text" placeholder="1" style={{ width: '30px' }} className="text-center align-middle mx-1" readOnly></input>
                                        <input type="image" src="https://img.icons8.com/ios-glyphs/20/000000/plus-math.png" />
34
35
36
37
38
39
40
41
42
43
44
45
46
                                    </div>
                                </Card.Body>
                            </Col>
                        </Row>
                    </Card>
                    <Card>
                        <Row>
                            <Col>
                                <input className="mx-5" type="checkbox" id="exampleCheck1"></input>
                                <Card.Img className="img-fluid" variant="top" src="img/asd.jpg" style={{ width: '20rem' }} />
                            </Col>
                            <Col>
                                <Card.Body>
Jiwon Yoon's avatar
Jiwon Yoon committed
47
                                    <input type="image" src="https://img.icons8.com/fluent-systems-regular/24/000000/close-window.png" className="float-right" />
48
49
50
51
                                    <Card.Title className="font-weight-bold mt-3">제품명</Card.Title>
                                    <Card.Text>가격</Card.Text>
                                    <Card.Text>옵션</Card.Text>
                                    <Card.Text>수량</Card.Text>
Jiwon Yoon's avatar
Jiwon Yoon committed
52
53
54
55
                                    <div className="align-items-center" >
                                        <input type="image" src="https://img.icons8.com/ios-glyphs/20/000000/minus-math.png" />
                                        <input type="text"  placeholder="1"  style={{ width: '30px' }} className="text-center align-middle mx-1" readOnly></input>
                                        <input type="image" src="https://img.icons8.com/ios-glyphs/20/000000/plus-math.png" />
56
57
58
59
60
61
                                    </div>
                                </Card.Body>
                            </Col>
                        </Row>
                    </Card>
                </div>
Jiwon Yoon's avatar
Jiwon Yoon committed
62
                <div className="p-5 m-5"  style={{background:'#F7F3F3'}}>
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
                    <ul className="pl-0" style={{ listStyle: 'none' }}>
                        <li>
                            <span className="text-secondary"> 상품금액</span>
                            <span className="text-secondary float-right">12,000</span>
                        </li>
                        <li>
                            <span className="text-secondary">배송비</span>
                            <span className="text-secondary float-right">2,500</span>
                        </li>
                    </ul>
                    <div className="my-1 pt-2 border-top font-weight-bold">
                        결제금액<span className="float-right">14,500</span>
                    </div>
                </div>
                <div className="text-center">
Jiwon Yoon's avatar
Jiwon Yoon committed
78
                    <Button className="px-5" style={{ background: "#91877F", borderColor: '#91877F' }} href="/payment">결제하기</Button>
79
80
81
                </div>
            </Container>

Kim, Subin's avatar
Kim, Subin committed
82
83
84
85
86
        </div>
    )
}

export default ShoppingCart