#284 card_history 테이블 제거

This commit is contained in:
chicpro
2013-09-02 09:56:14 +09:00
parent c0a0344e28
commit a1773206fc
12 changed files with 13 additions and 423 deletions

View File

@ -1,113 +0,0 @@
<?php
if (!defined("_GNUBOARD_")) exit; // 개별 페이지 접근 불가
/* ============================================================================== */
/* = 06. 승인 및 실패 결과 DB처리 = */
/* = -------------------------------------------------------------------------- = */
/* = 결과를 업체 자체적으로 DB처리 작업하시는 부분입니다. = */
/* = -------------------------------------------------------------------------- = */
if ( $req_tx == "pay" )
{
if( $res_cd == "0000" )
{
// 06-1-1. 신용카드
if ( $use_pay_method == "100000000000" )
{
$trade_ymd = substr($app_time,0,4)."-".substr($app_time,4,2)."-".substr($app_time,6,2);
$trade_hms = substr($app_time,8,2).":".substr($app_time,10,2).":".substr($app_time,12,2);
// 카드내역 INSERT
$sql = "insert {$g4['shop_card_history_table']}
set od_id = '$ordr_idxx',
cd_mall_id = '$g_conf_site_cd',
cd_amount = '$good_mny',
cd_app_no = '$app_no',
cd_app_rt = '$res_cd',
cd_trade_ymd = '$trade_ymd',
cd_trade_hms = '$trade_hms',
cd_opt01 = '$buyr_name',
cd_time = NOW(),
cd_ip = '$cust_ip' ";
$result = sql_query($sql, TRUE);
}
// 06-1-2. 계좌이체
if ( $use_pay_method == "010000000000" )
{
$trade_ymd = date("Y-m-d", time());
$trade_hms = date("H:i:s", time());
// 계좌이체내역 INSERT
$sql = "insert {$g4['shop_card_history_table']}
set od_id = '$ordr_idxx',
cd_mall_id = '$g_conf_site_cd',
cd_amount = '$good_mny',
cd_app_no = '$tno',
cd_app_rt = '$res_cd',
cd_trade_ymd = '$trade_ymd',
cd_trade_hms = '$trade_hms',
cd_opt01 = '$buyr_name',
cd_time = NOW(),
cd_ip = '$cust_ip' ";
$result = sql_query($sql, TRUE);
}
// 06-1-3. 가상계좌
if ( $use_pay_method == "001000000000" )
{
$bankname = iconv("cp949", "utf8", $bankname);
$trade_ymd = date("Y-m-d", time());
$trade_hms = date("H:i:s", time());
// 가상계좌내역 INSERT
$sql = "insert {$g4['shop_card_history_table']}
set od_id = '$ordr_idxx',
cd_mall_id = '$g_conf_site_cd',
cd_amount = '0',
cd_app_no = '$tno',
cd_app_rt = '$res_cd',
cd_trade_ymd = '$trade_ymd',
cd_trade_hms = '$trade_hms',
cd_opt01 = '$buyr_name',
cd_time = NOW(),
cd_ip = '$cust_ip' ";
$result = sql_query($sql, TRUE);
}
// 06-1-4. 포인트
if ( $use_pay_method == "000100000000" )
{
}
// 06-1-5. 휴대폰
if ( $use_pay_method == "000010000000" )
{
$trade_ymd = substr($app_time,0,8);
$trade_hms = substr($app_time,8,6);
// 휴대폰결제내역 INSERT
$sql = "insert {$g4['shop_card_history_table']}
set od_id = '$ordr_idxx',
cd_mall_id = '$g_conf_site_cd',
cd_amount = '$good_mny',
cd_app_no = '$tno',
cd_app_rt = '$res_cd',
cd_trade_ymd = '$trade_ymd',
cd_trade_hms = '$trade_hms',
cd_opt01 = '$buyr_name',
cd_opt02 = '$mobile_no $commid',
cd_time = NOW(),
cd_ip = '$cust_ip' ";
$result = sql_query($sql, TRUE);
}
// 06-1-6. 상품권
if ( $use_pay_method == "000000001000" )
{
}
}
/* = -------------------------------------------------------------------------- = */
/* = 06. 승인 및 실패 결과 DB처리 = */
/* ============================================================================== */
else if ( $req_cd != "0000" )
{
}
}
?>

View File

@ -355,6 +355,7 @@ else if ($od_settle_case == "신용카드")
$od_temp_amount = $i_amount;
$od_tno = $tno;
$od_app_no = $app_no;
$od_receipt_amount = $amount;
$od_receipt_point = $i_temp_point;
$od_receipt_time = preg_replace("/([0-9]{4})([0-9]{2})([0-9]{2})([0-9]{2})([0-9]{2})([0-9]{2})/", "\\1-\\2-\\3 \\4:\\5:\\6", $app_time);
@ -431,6 +432,7 @@ $sql = " insert {$g4['shop_order_table']}
od_bank_account = '$od_bank_account',
od_receipt_time = '$od_receipt_time',
od_tno = '$od_tno',
od_app_no = '$od_app_no',
od_escrow = '$od_escrow',
od_tax_flag = '{$default['de_tax_flag_use']}',
od_tax_mny = '$od_tax_mny',
@ -487,9 +489,6 @@ if(!$result) {
if ($is_member && $od_receipt_point)
insert_point($member['mb_id'], (-1) * $od_receipt_point, "주문번호 $od_id 결제");
// PG 결제내역기록
include_once(G4_MSHOP_PATH.'/kcp/pp_ax_hub_result.php');
$od_memo = nl2br(htmlspecialchars2(stripslashes($od_memo))) . "&nbsp;";
// 쿠폰사용내역기록

View File

@ -359,11 +359,8 @@ include_once(G4_MSHOP_PATH.'/_head.php');
$disp_bank = true;
$disp_receipt = false;
if($od['od_settle_case'] == '신용카드') {
$sql = " select * from {$g4['shop_card_history_table']} where od_id = '{$od['od_id']}' ";
$cd = sql_fetch($sql);
$app_no_subj = '승인번호';
$app_no = $cd['cd_app_no'];
$app_no = $od['od_app_no'];
$disp_bank = false;
$disp_receipt = true;
} else if($od['od_settle_case'] == '휴대폰') {