고객취소 요청 가능 상태 체크 코드 수정

This commit is contained in:
chicpro
2013-09-17 10:11:50 +09:00
parent fc77557842
commit c5ac4cbd85
2 changed files with 28 additions and 8 deletions

View File

@ -41,6 +41,9 @@ include_once(G5_MSHOP_PATH.'/_head.php');
<dd>상품 배송이 완료되었습니다.</dd>
</dl>
<?php
$st_count1 = $st_count2 = 0;
$custom_cancel = false;
$sql = " select it_id, it_name, cp_price
from {$g5['g5_shop_cart_table']}
where od_id = '$od_id'
@ -101,6 +104,10 @@ include_once(G5_MSHOP_PATH.'/_head.php');
</tr>
<?php
$tot_point += $point;
$st_count1++;
if($opt['ct_status'] == '주문')
$st_count2++;
}
?>
</tbody>
@ -108,6 +115,10 @@ include_once(G5_MSHOP_PATH.'/_head.php');
</li>
<?php
}
// 주문 상품의 상태가 모두 주문이면 고객 취소 가능
if($st_count1 > 0 && $st_count1 == $st_count2)
$custom_cancel = true;
?>
</ul>
@ -162,8 +173,9 @@ include_once(G5_MSHOP_PATH.'/_head.php');
$cancel_price = $od['od_cancel_price'];
$misu = true;
$misu_price = $tot_price - $receipt_price - $cancel_price;
if ($tot_price - $cancel_price == $receipt_price) {
if ($misu_price == 0 && ($od['od_cart_price'] > $od['od_cancel_price'])) {
$wanbul = " (완불)";
$misu = false; // 미수금 없음
}
@ -172,8 +184,6 @@ include_once(G5_MSHOP_PATH.'/_head.php');
$wanbul = display_price($receipt_price);
}
$misu_price = $tot_price - $receipt_price - $cancel_price;
// 결제정보처리
if($od['od_receipt_price'] > 0)
$od_receipt_price = display_price($od['od_receipt_price']);
@ -497,7 +507,7 @@ include_once(G5_MSHOP_PATH.'/_head.php');
<?php
// 취소한 내역이 없다면
if ($cancel_price == 0) {
if ($od['od_settle_case'] != '가상계좌' || $od['od_receipt_price'] == 0) {
if ($custom_cancel) {
?>
<button type="button" onclick="document.getElementById('sod_fin_cancelfrm').style.display='block';">주문 취소하기</button>

View File

@ -54,6 +54,9 @@ if(openwin != null) {
<dd>상품 배송이 완료되었습니다.</dd>
</dl>
<?php
$st_count1 = $st_count2 = 0;
$custom_cancel = false;
$sql = " select it_id, it_name
from {$g5['g5_shop_cart_table']}
where od_id = '$od_id'
@ -114,6 +117,10 @@ if(openwin != null) {
</tr>
<?php
$tot_point += $point;
$st_count1++;
if($opt['ct_status'] == '주문')
$st_count2++;
}
?>
</tbody>
@ -121,6 +128,10 @@ if(openwin != null) {
</li>
<?php
}
// 주문 상품의 상태가 모두 주문이면 고객 취소 가능
if($st_count1 > 0 && $st_count1 == $st_count2)
$custom_cancel = true;
?>
</ul>
@ -174,8 +185,9 @@ if(openwin != null) {
$cancel_price = $od['od_cancel_price'];
$misu = true;
$misu_price = $tot_price - $receipt_price - $cancel_price;
if ($tot_price - $cancel_price == $receipt_price) {
if ($misu_price == 0 && ($od['od_cart_price'] > $od['od_cancel_price'])) {
$wanbul = " (완불)";
$misu = false; // 미수금 없음
}
@ -184,8 +196,6 @@ if(openwin != null) {
$wanbul = display_price($receipt_price);
}
$misu_price = $tot_price - $receipt_price - $cancel_price;
// 결제정보처리
if($od['od_receipt_price'] > 0)
$od_receipt_price = display_price($od['od_receipt_price']);
@ -508,7 +518,7 @@ if(openwin != null) {
<?php
// 취소한 내역이 없다면
if ($cancel_price == 0) {
if ($od['od_status'] == G5_OD_STATUS_ORDER || $od['od_status'] == G5_OD_STATUS_SETTLE) {
if ($custom_cancel) {
?>
<button type="button" onclick="document.getElementById('sod_fin_cancelfrm').style.display='block';">주문 취소하기</button>