当前位置: 首页>>代码示例>>PHP>>正文


PHP fn_order_placement_routines函数代码示例

本文整理汇总了PHP中fn_order_placement_routines函数的典型用法代码示例。如果您正苦于以下问题:PHP fn_order_placement_routines函数的具体用法?PHP fn_order_placement_routines怎么用?PHP fn_order_placement_routines使用的例子?那么恭喜您, 这里精选的函数代码示例或许可以为您提供帮助。


在下文中一共展示了fn_order_placement_routines函数的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。

示例1: fn_paypal_complete_checkout

function fn_paypal_complete_checkout($token, $processor_data, $order_info)
{
    $pp_response['order_status'] = 'F';
    $reason_text = '';
    $paypal_checkout_details = fn_paypal_get_express_checkout_details($processor_data, $token);
    if (fn_paypal_ack_success($paypal_checkout_details)) {
        $result = fn_paypal_do_express_checkout($processor_data, $paypal_checkout_details, $order_info);
        if (fn_paypal_ack_success($result)) {
            $status = $result['PAYMENTINFO_0_PAYMENTSTATUS'];
            $pp_response['transaction_id'] = $result['PAYMENTINFO_0_TRANSACTIONID'];
            if ($status == 'Completed' || $status == 'Processed') {
                $pp_response['order_status'] = 'O';
                $reason_text = 'Accepted, awaiting ipn for processing ';
            } elseif ($status == 'Pending') {
                $pp_response['order_status'] = 'O';
                $reason_text = 'Pending ';
            } else {
                $reason_text = 'Declined ';
            }
            $reason_text = fn_paypal_process_add_fields($result, $reason_text);
            if (!empty($result['L_ERRORCODE0'])) {
                $reason_text .= ', ' . fn_paypal_get_error($result);
            }
        } else {
            $reason_text = fn_paypal_get_error($result);
        }
    } else {
        $reason_text = fn_paypal_get_error($paypal_checkout_details);
    }
    $pp_response['reason_text'] = $reason_text;
    if (fn_check_payment_script($processor_data['processor_script'], $order_info['order_id'])) {
        unset($_SESSION['pp_express_details']);
        fn_finish_payment($order_info['order_id'], $pp_response);
        fn_order_placement_routines('route', $order_info['order_id'], false);
    }
}
开发者ID:askzap,项目名称:ultimate,代码行数:36,代码来源:paypal_express.functions.php

示例2: __

                $pp_response['reason_text'] = __('payments.realex.bank_error');
            } elseif (floor($realex_response_code / 100) == 3) {
                // Error with Realex Payments systems – generally you can tell the customer to try again later.
                // The resolution time depends on the issue.
                $pp_response['order_status'] = $realex_statuses['realex_error'];
                $pp_response['reason_text'] = __('payments.realex.realex_error');
            } elseif (floor($realex_response_code / 100) == 5) {
                // Incorrect XML message formation or content. These are either development errors,
                // configuration errors or customer errors
                $pp_response['order_status'] = $realex_statuses['incorrect_request'];
                $pp_response['reason_text'] = __('payments.realex.incorrect_request');
            } elseif (floor($realex_response_code / 100) == 6) {
                // Client deactivated – your Realex account has been suspended. Contact Realex support for further information.
                $pp_response['order_status'] = $realex_statuses['connector_error'];
                $pp_response['reason_text'] = __('payments.realex.connector_error');
            }
            fn_finish_payment($_REQUEST['order_id'], $pp_response);
            if ($realex_response_code == '00') {
                $result = "<strong>Your transaction was successful</strong><br>To complete your order you must follow the link below.<br> Click <a href='" . fn_url("payment_notification.notify&payment=realex_redirect&order_id={$_REQUEST['order_id']}", AREA, 'current') . "'>here</a> to complete checkout";
            } else {
                $result = "<strong>Your transaction was unsuccessful.</strong><br> There was a problem with your order, please return to the checkout and try again.<br>Click <a href='" . fn_url("payment_notification.cancel&payment=realex_redirect&order_id={$_REQUEST['order_id']}", AREA, 'current') . "'>here</a> to return";
            }
            echo $result;
            exit;
        }
    } elseif ($mode == 'notify') {
        fn_order_placement_routines('route', $_REQUEST['order_id'], false);
    } elseif ($mode == 'cancel') {
        fn_order_placement_routines('checkout_redirect', $_REQUEST['order_id'], false);
    }
}
开发者ID:askzap,项目名称:ultimate,代码行数:31,代码来源:realex_redirect.php

示例3: die

            die('Access denied');
        }
        fn_set_notification('W', __('important'), __('text_transaction_cancelled'));
        fn_order_placement_routines('route', Tygh::$app['session']['order_id'], false);
    } elseif ($mode == 'decline') {
        if (!isset(Tygh::$app['session']['order_id'])) {
            die('Access denied');
        }
        fn_set_notification('E', '', __('text_order_placed_error'));
        fn_order_placement_routines('route', Tygh::$app['session']['order_id'], false);
    } elseif ($mode == 'refer') {
        if (!isset(Tygh::$app['session']['order_id'])) {
            die('Access denied');
        }
        fn_set_notification('W', __('important'), $processor_response['REFER']);
        fn_order_placement_routines('route', Tygh::$app['session']['order_id'], false);
    }
} else {
    $post_url = $processor_data['processor_params']['mode'] == 'test' ? 'https://test.pay4later.com/credit_app/' : 'https://secure.pay4later.com/credit_app/';
    $_order_id = $order_info['repaid'] ? $order_id . '_' . $order_info['repaid'] : $order_id;
    $order_description = __('order') . " #{$order_id}";
    Tygh::$app['session']['order_id'] = $order_id;
    $post_data = array('Identification[api_key]' => $processor_data['processor_params']['merchant_key'], 'Identification[RetailerUniqueRef]' => $_order_id, 'Identification[InstallationID]' => $processor_data['processor_params']['installation_id'], 'Goods[0][Description]' => $order_description, 'Goods[0][Quantity]' => '1', 'Goods[0][Price]' => $order_info['total'], 'Finance[Code]' => $processor_data['processor_params']['finance_product_code'], 'Finance[Deposit]' => $processor_data['processor_params']['deposit_amount']);
    fn_create_payment_form($post_url, $post_data, 'Pay4Later');
}
exit;
function fn_pay4later_order_placement_routines()
{
    Tygh::$app['session']['cart'] = array('user_data' => !empty(Tygh::$app['session']['cart']['user_data']) ? Tygh::$app['session']['cart']['user_data'] : array(), 'profile_id' => !empty(Tygh::$app['session']['cart']['profile_id']) ? Tygh::$app['session']['cart']['profile_id'] : 0, 'user_id' => !empty(Tygh::$app['session']['cart']['user_id']) ? Tygh::$app['session']['cart']['user_id'] : 0);
    Tygh::$app['session']['shipping_rates'] = array();
    unset(Tygh::$app['session']['shipping_hash']);
开发者ID:ambient-lounge,项目名称:site,代码行数:31,代码来源:pay4later.php

示例4: die

*                                                                          *
* This  is  commercial  software,  only  users  who have purchased a valid *
* license  and  accept  to the terms of the  License Agreement can install *
* and use this program.                                                    *
*                                                                          *
****************************************************************************
* PLEASE READ THE FULL TEXT  OF THE SOFTWARE  LICENSE   AGREEMENT  IN  THE *
* "copyright.txt" FILE PROVIDED WITH THIS DISTRIBUTION PACKAGE.            *
****************************************************************************/
use Tygh\Registry;
if (!defined('BOOTSTRAP')) {
    die('Access denied');
}
if (defined('PAYMENT_NOTIFICATION')) {
    if ($mode == 'notify') {
        fn_order_placement_routines('route', $_REQUEST['order_id']);
    } elseif ($mode == 'process') {
        $pp_response = array('order_status' => 'F', 'pp_response' => '', 'reason_text' => '');
        $order_id = $_REQUEST['order_id'];
        if (!empty($_REQUEST['payment_number'])) {
            $pp_response['transaction_id'] = $_REQUEST['payment_number'];
            $conf_key = db_get_field("SELECT data FROM ?:order_data WHERE type = 'E' AND order_id = ?i", $order_id);
            if (empty($conf_key) || $conf_key != $_REQUEST['conf_key']) {
                $pp_response['reason_text'] .= 'Confirmation key does not match; ';
            } else {
                db_query("DELETE FROM ?:order_data WHERE type = 'E' AND order_id = ?i", $order_id);
                $pp_response['order_status'] = 'P';
            }
        } else {
            $pp_response['reason_text'] .= 'Payment number is empty; ';
        }
开发者ID:ambient-lounge,项目名称:site,代码行数:31,代码来源:direct_one.php

示例5: elseif

        exit;
    }
} elseif (defined('PAYMENT_NOTIFICATION')) {
    if (!defined('BOOTSTRAP')) {
        die('Access denied');
    }
    if ($mode == 'process') {
        $order_id = intval($_REQUEST['ref']);
        fn_order_placement_routines('route', $order_id, false);
    } elseif ($mode == 'cancel') {
        $params = array();
        parse_str(base64_decode($_REQUEST['divers']), $params);
        $pp_response['order_status'] = 'N';
        $pp_response['reason_text'] = __('text_transaction_cancelled');
        fn_finish_payment($params['order_id'], $pp_response, false);
        fn_order_placement_routines('route', $params['order_id'], false);
    }
} else {
    if (!defined('BOOTSTRAP')) {
        die('Access denied');
    }
    // Params
    $url = array('psc' => 'https://billing.paysite-cash.biz', 'ep' => 'https://secure.easy-pay.net');
    $site_id = $processor_data['processor_params']['site_id'];
    $currency = $processor_data['processor_params']['currency'];
    $processor = $processor_data['processor_params']['processor'];
    $test = $processor_data['processor_params']['mode'];
    $debug = $processor_data['processor_params']['debug'];
    $nocurrencies = $processor_data['processor_params']['nocurrencies'];
    $order_id = $order_info['order_id'];
    $email = $order_info['email'];
开发者ID:askzap,项目名称:ultimate,代码行数:31,代码来源:paysitecash.php

示例6: elseif

        exit;
    } elseif ($mode == 'auth' && !empty(Tygh::$app['session']['cmpi']['order_id'])) {
        $view = Tygh::$app['view'];
        $view->assign('order_action', __('placing_order'));
        $view->display('views/orders/components/placing_order.tpl');
        fn_flush();
        fn_cmpi_authenticate();
        if (Tygh::$app['session']['cmpi']['signature'] == 'Y' && in_array(Tygh::$app['session']['cmpi']['pares'], array('Y', 'A', 'U'))) {
            define('DO_DIRECT_PAYMENT', true);
        } else {
            Tygh::$app['session']['cmpi']['auth_error'] = true;
            fn_set_notification('E', __('authentication_failed'), __('text_authentication_failed_message'));
        }
        define('CMPI_PROCESSED', true);
        fn_start_payment(Tygh::$app['session']['cmpi']['order_id']);
        fn_order_placement_routines('route', Tygh::$app['session']['cmpi']['order_id']);
        exit;
    }
}
/**
 * Make cmpi_lookup request to 3-D Secure sevice provider
 *
 * @param array $processor_data Payment processor data
 * @param array $order_info Order information
 * @return boolean true
 */
function fn_cmpi_lookup($processor_data, $order_info, $mode = '')
{
    unset(Tygh::$app['session']['cmpi']);
    $amount = preg_replace('/\\D/', '', $order_info['total']);
    // array with ISO codes of currencies. //TODO: move to database.
开发者ID:ambient-lounge,项目名称:site,代码行数:31,代码来源:cmpi.php

示例7: fn_finish_payment

                }
            } else {
                $pp_response['order_status'] = 'P';
            }
            fn_finish_payment($order_id, $pp_response);
            exit;
        } elseif ($mode == 'finish') {
            $order_info = fn_get_order_info($order_id);
            if ($order_info['status'] == 'O') {
                $pp_response = array();
                $pp_response['order_status'] = 'F';
                $pp_response['reason_text'] = fn_get_lang_var('merchant_response_was_not_received');
                $pp_response['transaction_id'] = '';
                fn_finish_payment($order_id, $pp_response);
            }
            fn_order_placement_routines($order_id, false);
        }
    }
} else {
    $current_location = Registry::get('config.current_location');
    $lang_code = CART_LANGUAGE == 'TH' ? 'TH' : 'EN';
    $sess = '&' . SESS_NAME . '=' . Session::get_id();
    $_SESSION['thaiepay_refno'] = $order_id;
    echo <<<EOT
<html>
<body onLoad="document.process.submit();">
<form method="post" action="https://www.thaiepay.com/epaylink/payment.aspx" name="process">
\t<input type="hidden" name="refno" value="{$order_id}">
\t<input type="hidden" name="merchantid" value="{$processor_data['params']['merchantid']}">
\t<input type="hidden" name="customeremail" value="{$order_info['email']}">
\t<input type="hidden" name="productdetail" value="{$processor_data['params']['details']}">
开发者ID:diedsmiling,项目名称:busenika,代码行数:31,代码来源:thaiepay.php

示例8: elseif

        exit;
    } elseif ($mode == 'auth' && !empty($_SESSION['cmpi']['order_id'])) {
        $view = Tygh::$app['view'];
        $view->assign('order_action', __('placing_order'));
        $view->display('views/orders/components/placing_order.tpl');
        fn_flush();
        fn_cmpi_authenticate();
        if ($_SESSION['cmpi']['signature'] == 'Y' && in_array($_SESSION['cmpi']['pares'], array('Y', 'A', 'U'))) {
            define('DO_DIRECT_PAYMENT', true);
        } else {
            $_SESSION['cmpi']['auth_error'] = true;
            fn_set_notification('E', __('authentication_failed'), __('text_authentication_failed_message'));
        }
        define('CMPI_PROCESSED', true);
        fn_start_payment($_SESSION['cmpi']['order_id']);
        fn_order_placement_routines('route', $_SESSION['cmpi']['order_id']);
        exit;
    }
}
/**
 * Make cmpi_lookup request to 3-D Secure sevice provider
 *
 * @param array $processor_data Payment processor data
 * @param array $order_info Order information
 * @return boolean true
 */
function fn_cmpi_lookup($processor_data, $order_info, $mode = '')
{
    unset($_SESSION['cmpi']);
    $amount = preg_replace('/\\D/', '', $order_info['total']);
    // array with ISO codes of currencies. //TODO: move to database.
开发者ID:askzap,项目名称:ultimate,代码行数:31,代码来源:cmpi.php

示例9: fn_set_notification

                                        break;
                                    }
                                }
                            } else {
                                $error = true;
                            }
                        } else {
                            $error = true;
                        }
                        if ($error) {
                            fn_set_notification('E', __('error'), __('error_status_not_changed'));
                        }
                    }
                }
            }
            fn_order_placement_routines($action, $order_id, $notification_rules, true);
        } else {
            return array(CONTROLLER_STATUS_REDIRECT, "order_management.{$_suffix}");
        }
    }
    return array(CONTROLLER_STATUS_OK, "order_management.{$_suffix}");
}
if ($mode == 'customer_info') {
    if (!empty($_REQUEST['profile_id'])) {
        $user_data = fn_get_user_info($customer_auth['user_id'], true, $_REQUEST['profile_id']);
        Registry::get('view')->assign('user_data', $user_data);
    }
    return array(CONTROLLER_STATUS_OK, "order_management.{$_suffix}");
}
// Delete discount coupon
if ($mode == 'delete_coupon') {
开发者ID:OneataBogdan,项目名称:lead_coriolan,代码行数:31,代码来源:order_management.php

示例10: __

                        $pp_response['order_status'] = 'P';
                        $pp_response['transaction_id'] = $process->getPaymentId();
                        $pp_response['reason_text'] = __("rus_payments.yandex_money_payer") . ": " . $process->getPayer() . "; " . __("rus_payments.yandex_money_payee") . ": " . $process->getPayee();
                    } else {
                        $pp_response['reason_text'] = __("rus_payments.yandex_money_" . $process->getError());
                    }
                } else {
                    if ($request->getError() == 'ext_action_required') {
                        $pp_response['reason_text'] = __("rus_payments.yandex_money_" . $request->getError(), array("[ext_action_uri]" => $request->getExtActionUri()));
                    } else {
                        $pp_response['reason_text'] = __("rus_payments.yandex_money_" . $request->getError());
                    }
                }
            } else {
                $pp_response['reason_text'] = __("rus_payments.yandex_money_" . $receiveTokenResp->getError());
            }
            fn_finish_payment($order_info['order_id'], $pp_response);
        }
        fn_order_placement_routines('route', $order_info['order_id'], false);
    }
} else {
    $scope = "payment.to-account(\"" . $processor_data['processor_params']['payee_id'] . "\",\"account\").limit(," . $order_info['total'] . ")";
    $redirect_url = fn_url("payment_notification.process?payment=yandex_p2p&order_id=" . $order_info['order_id']);
    $authUri = Client::authorizeUri($processor_data['processor_params']['client_id'], $redirect_url, $scope);
    fn_create_payment_form($authUri, array(), 'Yandex.P2P', false);
}
function fn_yandex_money_is_test_mode($processor_data)
{
    return !empty($processor_data['processor_params']['test_mode']) && $processor_data['processor_params']['test_mode'] == 'Y';
}
exit;
开发者ID:ambient-lounge,项目名称:site,代码行数:31,代码来源:yandex_p2p.php

示例11: elseif

        exit;
    } elseif ($mode == 'result') {
        if (fn_check_payment_script('ogone_web.php', $_REQUEST['order_id'])) {
            $order_info = fn_get_order_info($_REQUEST['order_id'], true);
            if ($order_info['status'] == 'N') {
                fn_change_order_status($_REQUEST['order_id'], 'O', '', false);
            }
        }
        fn_order_placement_routines($_REQUEST['order_id'], false);
    } elseif ($mode == 'cancel') {
        if (fn_check_payment_script('ogone_web.php', $_REQUEST['order_id'])) {
            $pp_response = array();
            $pp_response['order_status'] = 'N';
            $pp_response['reason_text'] = fn_get_lang_var('text_transaction_cancelled');
            fn_finish_payment($_REQUEST['order_id'], $pp_response);
            fn_order_placement_routines($_REQUEST['order_id'], false);
        }
    }
} else {
    $pp_merch = $processor_data['params']['pspid'];
    $pp_secret = $processor_data['params']['sha_sign'];
    $pp_curr = $processor_data['params']['currency'];
    $pp_test = $processor_data['params']['mode'] == 'test' ? "https://secure.ogone.com:443/ncol/test/orderstandard.asp" : "https://secure.ogone.com:443/ncol/prod/orderstandard.asp";
    $ordr = $order_id . '_' . fn_date_format(time(), '%H:%M:%S');
    $ordr = $order_info['repaid'] ? $ordr . '_' . $order_info['repaid'] : $ordr;
    $langs = array("EN" => "en_US", "FR" => "fr_FR", "NL" => "nl_NL", "IT" => "it_IT", "DE" => "de_DE", "ES" => "es_ES", "NO" => "no_NO");
    $post = array();
    $post["amount"] = 100 * $order_info["total"];
    $post["email"] = trim(substr($order_info['email'], 0, 50));
    $post["owneraddress"] = trim(substr(trim($order_info['b_address'] . (!empty($order_info['b_address_2']) ? " ; " . $order_info['b_address_2'] : '')), 0, 35));
    $post["ownertown"] = trim(substr($order_info['b_city'], 0, 25));
开发者ID:diedsmiling,项目名称:busenika,代码行数:31,代码来源:ogone_web.php

示例12: die

* and use this program.                                                    *
*                                                                          *
****************************************************************************
* PLEASE READ THE FULL TEXT  OF THE SOFTWARE  LICENSE   AGREEMENT  IN  THE *
* "copyright.txt" FILE PROVIDED WITH THIS DISTRIBUTION PACKAGE.            *
****************************************************************************/
//
// $Id: google_checkout.php 10329 2010-08-03 14:46:04Z klerik $
//
if (!defined('AREA')) {
    die('Access denied');
}
$index_script = Registry::get('customer_index');
if (defined('PAYMENT_NOTIFICATION')) {
    if (!empty($_SESSION['order_id'])) {
        fn_order_placement_routines($_SESSION['order_id']);
    } else {
        fn_set_notification('E', fn_get_lang_var('error'), fn_get_lang_var('order_was_not_placed'));
        fn_redirect(Registry::get('config.http_location') . "/{$index_script}?dispatch=checkout.cart");
    }
} elseif (!empty($_payment_id) && !fn_cart_is_empty($cart) && $processor_data['params']['policy_agreement'] == 'Y') {
    $return_url = Registry::get('config.current_location') . "/{$index_script}?dispatch=payment_notification.notify&amp;payment=google_checkout&amp;" . SESS_NAME . '=' . Session::get_id();
    $edit_cart_url = Registry::get('config.current_location') . "/{$index_script}?dispatch=checkout.cart";
    $calculation_url = ($processor_data["params"]["test"] == 'N' ? Registry::get('config.https_location') : Registry::get('config.current_location')) . "/payments/google_calculations.php";
    $_currency = $processor_data['params']['currency'];
    $base_domain = 'https://' . ($processor_data['params']['test'] == 'N' ? 'checkout.google.com' : 'sandbox.google.com/checkout');
    $base_url = $base_domain . '/cws/v2/Merchant/' . $processor_data['params']['merchant_id'];
    $checkout_url = $base_url . '/checkout';
    $request_url = $base_url . '/request';
    // Form XML array with cart items
    $_items = '';
开发者ID:diedsmiling,项目名称:busenika,代码行数:31,代码来源:google_checkout.php

示例13: fn_payway_decrypt_parameters

        $params = fn_payway_decrypt_parameters($processor_data['params']['encryption_key'], $_REQUEST['EncryptedParameters'], $_REQUEST['Signature']);
        if (!empty($params)) {
            $status = db_get_field("SELECT status FROM ?:orders WHERE order_id = ?i", $params['payment_reference']);
            if ($status == 'O') {
                if (!empty($params['bank_reference'])) {
                    $pp_response["order_status"] = 'P';
                    $pp_response["reason_text"] = "Authorization code: " . $params['bank_reference'];
                } else {
                    $pp_response["order_status"] = 'F';
                }
                $pp_response['transaction_id'] = $params['payment_number'];
                if (fn_check_payment_script('westpac.php', $params['payment_reference'])) {
                    fn_finish_payment($params['payment_reference'], $pp_response, false);
                }
            }
            fn_order_placement_routines($params['payment_reference']);
        }
    }
    exit;
} else {
    $merchant_id = $processor_data['params']['mode'] == 'test' ? 'TEST' : $processor_data['params']['merchant_id'];
    $biller_code = $processor_data['params']['biller_code'];
    echo <<<EOT
<html>
<body onLoad="javascript: document.process.submit();">
<form method="post" action="https://www.payway.com.au/MakePayment" name="process">
\t<input type="hidden" name="merchant_id" value="{$merchant_id}">
\t<input type="hidden" name="biller_code" value="{$biller_code}">

EOT;
    // Products
开发者ID:diedsmiling,项目名称:busenika,代码行数:31,代码来源:westpac.php

示例14: fn_manageState

function fn_manageState($state, $idstate, $mode, $orderId, $payNLTransactionID, $processor_data)
{
    switch ($state) {
        case 'PENDING':
            if ($mode == 'exchange') {
                echo 'TRUE| state:PENDING, orderId:' . $orderId . ', transactionId:' . $payNLTransactionID . ',idState:' . $idstate . ', service_id:' . $processor_data['processor_params']['service_id'] . ',token_api:' . $processor_data['processor_params']['token_api'] . ',statuses:' . print_r($processor_data['processor_params']['statuses'], true);
            } else {
                fn_order_placement_routines('route', $orderId);
            }
            die;
            break;
        case 'PAID':
            $payData = fn_paynl_getInfo($payNLTransactionID, $processor_data);
            $pp_response = array('order_status' => $idstate, 'naam' => $payData['paymentDetails']['identifierName'], 'rekening' => $payData['paymentDetails']['identifierPublic']);
            if ($mode == 'exchange') {
                echo 'TRUE| orderId=' . $orderId . ', transactionId=' . $payNLTransactionID . ',idState:' . $idstate . ', service_id:' . $processor_data['processor_params']['service_id'] . ',token_api:' . $processor_data['processor_params']['token_api'] . ',statuses:' . print_r($processor_data['processor_params']['statuses'], true);
                fn_finish_payment($orderId, $pp_response, true);
                fn_updatePayTransaction($payNLTransactionID, 'PAID');
                die;
            } else {
                fn_order_placement_routines('route', $orderId);
            }
            break;
        case 'CANCEL':
            if ($mode == 'exchange') {
                echo 'TRUE| CANCEL orderId=' . $orderId . ', transactionId=' . $payNLTransactionID . ',idState:' . $idstate . ', service_id:' . $processor_data['processor_params']['service_id'] . ',token_api:' . $processor_data['processor_params']['token_api'] . ',statuses:' . print_r($processor_data['processor_params']['statuses'], true);
                fn_updatePayTransaction($payNLTransactionID, 'CANCEL');
                die;
            } else {
                fn_updatePayTransaction($payNLTransactionID, 'CANCEL');
                fn_change_order_status($orderId, $idstate, '', false);
                fn_order_placement_routines('route', $orderId);
            }
            break;
        case 'CHECKAMOUNT':
            if ($mode == 'exchange') {
                echo 'TRUE| CHECKAMOUNT orderId=' . $orderId . ', transactionId=' . $payNLTransactionID . ',idState:' . $idstate . ', service_id:' . $processor_data['processor_params']['service_id'] . ',token_api:' . $processor_data['processor_params']['token_api'] . ',statuses:' . print_r($processor_data['processor_params']['statuses'], true);
                fn_updatePayTransaction($payNLTransactionID, 'CHECKAMOUNT');
                die;
            } else {
                fn_updatePayTransaction($payNLTransactionID, 'CHECKAMOUNT');
                fn_change_order_status($orderId, $idstate, '', false);
                fn_order_placement_routines('route', $orderId, false);
            }
            break;
        default:
            $pp_response['order_status'] = $processor_data['processor_params']['statuses'][$state];
            fn_updatePayTransaction($payNLTransactionID, 'PENDING');
            fn_change_order_status($orderId, $pp_response['order_status'], '', false);
            break;
    }
}
开发者ID:paynl,项目名称:cscart-plugin,代码行数:52,代码来源:paynl.php

示例15: end3DSecureTransaction

 /**
  * Ends 3DSecure transaction.
  * This method is called after bank ACS redirects user back to merchant site.
  *
  * @return array Payment processor response
  */
 protected function end3DSecureTransaction()
 {
     $verifysig_response = simplexml_load_string($this->send3DSecureVerifySignatureRequest($_REQUEST['PaRes']));
     $verifysig_result = (string) $verifysig_response->result;
     $verifysig_3dsecure_status = (string) $verifysig_response->threedsecure->status;
     $success_payment = false;
     $mpi_data = array('cavv' => (string) $verifysig_response->threedsecure->cavv, 'xid' => (string) $verifysig_response->threedsecure->xid, 'eci' => (string) $verifysig_response->threedsecure->eci);
     // Successful authentication
     if ($verifysig_result == '00' && $verifysig_3dsecure_status == 'Y') {
         $this->response['payments.realex.3d_secure_message'] = '3DS Verifysig request: Authentication successful';
         $success_payment = $this->authorizeTransaction(self::TRANSACTION_FULL_3DSECURE, $mpi_data);
     } elseif ($verifysig_result == '00' && $verifysig_3dsecure_status == 'A') {
         $this->response['payments.realex.3d_secure_message'] = '3DS Verifysig request: Cardholder not Enrolled or Authentication Attempt Acknowledged';
         $success_payment = $this->authorizeTransaction(self::TRANSACTION_MERCHANT_3DSECURE, $mpi_data);
     } elseif ($verifysig_result == '00' && $verifysig_3dsecure_status == 'U' && ($this->response['payments.realex.3d_secure_message'] = '3DS Verifysig request: Authentication Unavailable') || $verifysig_result == '00' && $verifysig_3dsecure_status == 'N' && ($this->response['payments.realex.3d_secure_message'] = '3DS Verifysig request: Incorrect Password') || $verifysig_result >= 500 && $verifysig_result < 600 && ($this->response['payments.realex.3d_secure_message'] = '3DS Verifysig request: Invalid response from ACS')) {
         if (!$this->getIsLiabilityShiftRequired()) {
             $success_payment = $this->authorizeTransaction(self::TRANSACTION_NON_3DSECURE, $mpi_data);
         }
     } elseif ($verifysig_result == '110') {
         $this->response['payments.realex.3d_secure_message'] = '3DS Verifysig request: Enrolled but Invalid Response from ACS';
     }
     fn_finish_payment($this->order_info['order_id'], $this->response);
     if ($success_payment) {
         fn_order_placement_routines('route', $this->order_info['order_id'], false);
     } else {
         fn_set_notification('E', false, "Your transaction was unsuccessful. There was a problem with your order, please try again or contact the store administrator.");
         fn_order_placement_routines('checkout_redirect', $this->order_info['order_id'], false);
     }
 }
开发者ID:ambient-lounge,项目名称:site,代码行数:35,代码来源:realex_remote.php


注:本文中的fn_order_placement_routines函数示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。