import React from 'react'; import { Row, Col, Card } from 'react-bootstrap'; function ListCard(props) { if (props.status === 'list') { return ( {props.name} {props.price} 원 ) } else if (props.status === 'recommend') { return ( {props.name} {props.price} 원 ) } else if (props.status === 'order') { return ( 주문 현황 { props.ordered.map((e) => ( {e.products.length > 1 ? {e.products[0].productId.pro_name} 외 {e.products.length - 1}개 : ( {e.products[0].productId.pro_name} )} <>
  • 주문번호 :
  • {e._id}
  • 결제금액 :
  • {e.total}원
  • 배송지 :
  • {e.receiverInfo.address}
    ( {e.receiverInfo.address2} )
  • 주문날짜 :
  • {e.createdAt.substring(0, 10)}
  • 결제정보 :
  • {e.paymentWay}{e.paymentWay == 'Remittance' ? ( <>
    {e.paymentInfo.bank} / ~ {e.paymentInfo.deadline} ) : ''}
    ) ) }
    ) } else if (props.status === 'cart') { return ( <> {props.cart.map((e) => ( {e.productId.pro_name} 가격: {e.productId.price}원 옵션: {e.size}/{e.color} 수량
    )) } ) } else if (props.status === 'payment') { return ( <> {props.cart.map((e) => ( {e.productId.pro_name} 가격: {e.productId.price}원 옵션: {e.size}/{e.color} 수량: {e.count} )) } ) } } export default ListCard