From 2bfd995e49561a489429b23ddf31403a22c4f73d Mon Sep 17 00:00:00 2001 From: thisgun Date: Mon, 1 Apr 2024 17:53:32 +0900 Subject: [PATCH] =?UTF-8?q?=EC=87=BC=ED=95=91=EB=AA=B0=20=EA=B2=B0?= =?UTF-8?q?=EC=A0=9C=EC=8B=9C=20=EA=B2=B0=EC=84=B8=EC=88=98=EB=8B=A8=20?= =?UTF-8?q?=EC=B2=B4=ED=81=AC=20=EA=B3=BC=EC=A0=95=20=EC=B6=94=EA=B0=80?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- lib/shop.lib.php | 33 +++++++++++++++++++++++++++++++++ mobile/shop/orderformupdate.php | 5 +++++ shop/orderformupdate.php | 5 +++++ 3 files changed, 43 insertions(+) diff --git a/lib/shop.lib.php b/lib/shop.lib.php index 4cc597663..5f7377682 100644 --- a/lib/shop.lib.php +++ b/lib/shop.lib.php @@ -2752,6 +2752,39 @@ function get_item_images_info($it, $size=array(), $image_width, $image_height){ return $images; } +function check_payment_method($od_settle_case) { + global $default; + + $is_block = 0; + + if ($od_settle_case === '무통장') { + if (! $default['de_bank_use']) { + $is_block = 1; + } + } else if ($od_settle_case === '계좌이체') { + if (! $default['de_iche_use']) { + $is_block = 1; + } + } else if ($od_settle_case === '가상계좌') { + if (! $default['de_vbank_use']) { + $is_block = 1; + } + } else if ($od_settle_case === '휴대폰') { + if (! $default['de_hp_use']) { + $is_block = 1; + } + } else if ($od_settle_case === '신용카드') { + if (! $default['de_card_use']) { + $is_block = 1; + } + } + + if ($is_block) { + alert($od_settle_case.' 은 결제수단에서 사용이 금지되어 있습니다.', G5_SHOP_URL); + die(''); + } +} + //결제방식 이름을 체크하여 치환 대상인 문자열은 따로 리턴합니다. function check_pay_name_replace($payname, $od=array(), $is_client=0){ diff --git a/mobile/shop/orderformupdate.php b/mobile/shop/orderformupdate.php index afca88cda..a68f76f4d 100644 --- a/mobile/shop/orderformupdate.php +++ b/mobile/shop/orderformupdate.php @@ -335,6 +335,11 @@ $order_price = $tot_od_price + $send_cost + $send_cost2 - $tot_sc_cp_price - $od $od_status = '주문'; $od_tno = ''; + +if (function_exists('check_payment_method')) { + check_payment_method($od_settle_case); +} + if ($od_settle_case == "무통장") { $od_receipt_point = $i_temp_point; diff --git a/shop/orderformupdate.php b/shop/orderformupdate.php index d0059fe10..349294285 100644 --- a/shop/orderformupdate.php +++ b/shop/orderformupdate.php @@ -308,6 +308,11 @@ $order_price = $tot_od_price + $send_cost + $send_cost2 - $tot_sc_cp_price - $od $od_status = '주문'; $od_tno = ''; + +if (function_exists('check_payment_method')) { + check_payment_method($od_settle_case); +} + if ($od_settle_case == "무통장") { $od_receipt_point = $i_temp_point;