주문하기
<main>
<section class="content">
<th:block th:include="/product/side.html"/>
<div class="order">
<h1>주문하기</h1>
<form action="/order/submit" method="post" id="orderForm">
<div id="tables-container">
<table class="order_content" th:each="cart : ${cartDTOList}">
<th:block th:if="${cart.cartNo != null and cart.cartNo != 0}">
<input type="hidden" name="cartNo" th:value="${cart.cartNo}">
</th:block>
<tr>
<th></th>
<th>상품명</th>
<th>옵션</th>
<th>수량</th>
<th>판매가</th>
<th>할인</th>
<th>포인트</th>
<th>배송비</th>
<th>총합</th>
</tr>
<tr>
<td>
<img th:src="@{${cart.product.productImage.sNameThumb3}}" alt="상품 이미지">
</td>
<td>
<p class="vendor-name" th:text="${cart.product.seller.company}">판매처</p><br>
<span th:text="${cart.product.prodBrand}">브랜드명</span><br>
<span th:text="${cart.product.prodName}">상품명</span>
</td>
<td class="options">
<ul>
<li th:if="${cart.opt1 != null and cart.opt1 != ''}" th:text="${cart.opt1 + ' : ' + cart.opt1Cont}"></li>
<li th:if="${cart.opt2 != null and cart.opt2 != ''}" th:text="${cart.opt2 + ' : ' + cart.opt2Cont}"></li>
<li th:if="${cart.opt3 != null and cart.opt3 != ''}" th:text="${cart.opt3 + ' : ' + cart.opt3Cont}"></li>
<li th:if="${cart.opt4 != null and cart.opt4 != ''}" th:text="${cart.opt4 + ' : ' + cart.opt4Cont}"></li>
<li th:if="${cart.opt5 != null and cart.opt5 != ''}" th:text="${cart.opt5 + ' : ' + cart.opt5Cont}"></li>
<li th:if="${cart.opt6 != null and cart.opt6 != ''}" th:text="${cart.opt6 + ' : ' + cart.opt6Cont}"></li>
</ul>
</td>
<td class="quantity" th:text="${cart.cartProdCount}">1</td>
<td class="cart_price">
<p class="price_original" th:data-unit="${cart.product.prodPrice}" th:text="${#numbers.formatInteger(cart.product.prodPrice, 3, 'COMMA')}">0</p>
<p class="price_total" th:with="discountedPrice=${cart.product.prodPrice * (100 - cart.product.prodDiscount) / 100}" th:data-unit="${discountedPrice}" th:text="${#numbers.formatInteger(discountedPrice, 3, 'COMMA')}">0</p>
</td>
<td class="discount-rate" th:text="${cart.product.prodDiscount + '%'}">0%</td>
<td><input type="text" class="point" name="itemPoint" th:data-rank="${userDetailsDTO.rank}"/></td>
<td class="shipping" th:text="${cart.product.prodDeliveryFee == 0 ? '무료배송' : #numbers.formatInteger(cart.product.prodDeliveryFee, 3, 'COMMA')}">0</td>
<td class="total" th:with="itemTotal=${(cart.product.prodPrice * (100 - cart.product.prodDiscount) / 100) * cart.cartProdCount