가상계좌 입금 통보 때 상태가 주문인 것만 반영되도록 수정

This commit is contained in:
chicpro
2014-06-26 09:37:48 +09:00
parent 58fb563c79
commit 9d4c1bfcbe
2 changed files with 49 additions and 27 deletions

View File

@ -144,6 +144,8 @@ if(!$default['de_card_test']) {
$sql = " select pp_id, od_id from {$g5['g5_shop_personalpay_table']} where pp_id = '$order_no' and pp_tno = '$tno' "; $sql = " select pp_id, od_id from {$g5['g5_shop_personalpay_table']} where pp_id = '$order_no' and pp_tno = '$tno' ";
$row = sql_fetch($sql); $row = sql_fetch($sql);
$result = false;
if($row['pp_id']) { if($row['pp_id']) {
// 개인결제 UPDATE // 개인결제 UPDATE
$sql = " update {$g5['g5_shop_personalpay_table']} $sql = " update {$g5['g5_shop_personalpay_table']}
@ -180,6 +182,14 @@ if(!$default['de_card_test']) {
else else
$od_id = $order_no; $od_id = $order_no;
// 주문정보 체크
$sql = " select count(od_id) as cnt
from {$g5['g5_shop_order_table']}
where od_id = '$od_id'
and od_status = '주문' ";
$row = sql_fetch($sql);
if($row['cnt'] == 1) {
// 미수금 정보 업데이트 // 미수금 정보 업데이트
$info = get_order_info($od_id); $info = get_order_info($od_id);
@ -198,6 +208,7 @@ if(!$default['de_card_test']) {
sql_query($sql, FALSE); sql_query($sql, FALSE);
} }
} }
}
/* = -------------------------------------------------------------------------- = */ /* = -------------------------------------------------------------------------- = */
/* = 03-2. 가상계좌 환불 통보 데이터 DB 처리 작업 부분 = */ /* = 03-2. 가상계좌 환불 통보 데이터 DB 처리 작업 부분 = */

View File

@ -78,6 +78,8 @@ if ( $LGD_HASHDATA2 == $LGD_HASHDATA ) { //해쉬값 검증이 성공이면
$sql = " select pp_id, od_id from {$g5['g5_shop_personalpay_table']} where pp_id = '$LGD_OID' and pp_tno = '$LGD_TID' "; $sql = " select pp_id, od_id from {$g5['g5_shop_personalpay_table']} where pp_id = '$LGD_OID' and pp_tno = '$LGD_TID' ";
$row = sql_fetch($sql); $row = sql_fetch($sql);
$result = false;
if($row['pp_id']) { if($row['pp_id']) {
// 개인결제 UPDATE // 개인결제 UPDATE
$sql = " update {$g5['g5_shop_personalpay_table']} $sql = " update {$g5['g5_shop_personalpay_table']}
@ -115,6 +117,14 @@ if ( $LGD_HASHDATA2 == $LGD_HASHDATA ) { //해쉬값 검증이 성공이면
else else
$od_id = $LGD_OID; $od_id = $LGD_OID;
// 주문정보 체크
$sql = " select count(od_id) as cnt
from {$g5['g5_shop_order_table']}
where od_id = '$od_id'
and od_status = '주문' ";
$row = sql_fetch($sql);
if($row['cnt'] == 1) {
// 미수금 정보 업데이트 // 미수금 정보 업데이트
$info = get_order_info($od_id); $info = get_order_info($od_id);
@ -133,6 +143,7 @@ if ( $LGD_HASHDATA2 == $LGD_HASHDATA ) { //해쉬값 검증이 성공이면
sql_query($sql, FALSE); sql_query($sql, FALSE);
} }
} }
}
//if( 무통장 입금 성공 상점처리결과 성공 ) //if( 무통장 입금 성공 상점처리결과 성공 )
if ($result) if ($result)