public function __construct() { $this->name = 'paypal'; $this->tab = 'payments_gateways'; $this->version = '2.4'; $this->currencies = true; $this->currencies_mode = 'radio'; parent::__construct(); $this->_errors = array(); $this->page = basename(__FILE__, '.php'); $this->displayName = $this->l('PayPal'); $this->description = $this->l('Accepts payments by credit cards (CB, Visa, MasterCard, Amex, Aurore, Cofinoga, 4 stars) with PayPal.'); $this->confirmUninstall = $this->l('Are you sure you want to delete your details?'); if (Configuration::get('PAYPAL_BUSINESS') == '*****@*****.**') { $this->warning = $this->l('You are currently using the default PayPal e-mail address, please enter your own e-mail address.'); } $this->_checkAndUpdateFromOldVersion(); if (file_exists(_PS_ROOT_DIR_ . '/modules/paypalapi/paypalapi.php') and $this->active) { $this->warning = $this->l('All features of Paypal API module are be include in the new Paypal module. In order to don\'t have any conflict, please don\'t use and remove PayPalAPI module.'); } global $cookie; /*$context = stream_context_create(array('http' => array('method'=>"GET", 'timeout' => 5))); $content = @file_get_contents('https://www.prestashop.com/partner/preactivation/preactivation-warnings.php?version=1.0&partner=paypal&iso_country='.Tools::strtolower(Country::getIsoById(Configuration::get('PS_COUNTRY_DEFAULT'))).'&iso_lang='.Tools::strtolower(Language::getIsoById(intval($cookie->id_lang))).'&id_lang='.(int)$cookie->id_lang.'&email='.urlencode(Configuration::get('PS_SHOP_EMAIL')).'&security='.md5(Configuration::get('PS_SHOP_EMAIL')._COOKIE_IV_), false, $context); $content = explode('|', $content); if ($content[0] == 'OK') { if (!empty($this->warning)) $this->warning .= ', '; $this->warning .= $content[1]; }*/ }
public function __construct() { $this->name = 'authorizeaim'; $this->tab = 'payments_gateways'; $this->version = '1.4.3'; $this->author = 'PrestaShop'; $this->need_instance = 0; parent::__construct(); $this->displayName = 'Authorize.net AIM (Advanced Integration Method)'; $this->description = $this->l('Receive payment with Authorize.net'); /* For 1.4.3 and less compatibility */ $updateConfig = array('PS_OS_CHEQUE' => 1, 'PS_OS_PAYMENT' => 2, 'PS_OS_PREPARATION' => 3, 'PS_OS_SHIPPING' => 4, 'PS_OS_DELIVERED' => 5, 'PS_OS_CANCELED' => 6, 'PS_OS_REFUND' => 7, 'PS_OS_ERROR' => 8, 'PS_OS_OUTOFSTOCK' => 9, 'PS_OS_BANKWIRE' => 10, 'PS_OS_PAYPAL' => 11, 'PS_OS_WS_PAYMENT' => 12); foreach ($updateConfig as $u => $v) { if (!Configuration::get($u) || (int) Configuration::get($u) < 1) { if (defined('_' . $u . '_') && (int) constant('_' . $u . '_') > 0) { Configuration::updateValue($u, constant('_' . $u . '_')); } else { Configuration::updateValue($u, $v); } } } /* Check if cURL is enabled */ if (!is_callable('curl_exec')) { $this->warning = $this->l('cURL extension must be enabled on your server to use this module.'); } /* Backward compatibility */ require _PS_MODULE_DIR_ . $this->name . '/backward_compatibility/backward.php'; }
public function __construct() { $this->name = 'cheque'; $this->tab = 'payments_gateways'; $this->version = '2.3'; $this->author = 'PrestaShop'; $this->currencies = true; $this->currencies_mode = 'checkbox'; $config = Configuration::getMultiple(array('CHEQUE_NAME', 'CHEQUE_ADDRESS')); if (isset($config['CHEQUE_NAME'])) { $this->chequeName = $config['CHEQUE_NAME']; } if (isset($config['CHEQUE_ADDRESS'])) { $this->address = $config['CHEQUE_ADDRESS']; } parent::__construct(); $this->displayName = $this->l('Check'); $this->description = $this->l('Module for accepting payments by check.'); $this->confirmUninstall = $this->l('Are you sure you want to delete your details ?'); if ($this->active && (!isset($this->chequeName) || !isset($this->address) || empty($this->chequeName) || empty($this->address))) { $this->warning = $this->l('\'To the order of\' and address must be configured in order to use this module correctly.'); } if ($this->active && !count(Currency::checkPaymentCurrencies($this->id))) { $this->warning = $this->l('No currency set for this module'); } $this->extra_mail_vars = array('{cheque_name}' => Configuration::get('CHEQUE_NAME'), '{cheque_address}' => Configuration::get('CHEQUE_ADDRESS'), '{cheque_address_html}' => str_replace("\n", '<br />', Configuration::get('CHEQUE_ADDRESS'))); }
public function __construct() { $this->name = 'bankwire'; $this->tab = 'payments_gateways'; $this->version = '0.5'; $this->author = 'PrestaShop'; $this->currencies = true; $this->currencies_mode = 'checkbox'; $config = Configuration::getMultiple(array('BANK_WIRE_DETAILS', 'BANK_WIRE_OWNER', 'BANK_WIRE_ADDRESS')); if (isset($config['BANK_WIRE_OWNER'])) { $this->owner = $config['BANK_WIRE_OWNER']; } if (isset($config['BANK_WIRE_DETAILS'])) { $this->details = $config['BANK_WIRE_DETAILS']; } if (isset($config['BANK_WIRE_ADDRESS'])) { $this->address = $config['BANK_WIRE_ADDRESS']; } parent::__construct(); $this->displayName = $this->l('Bank Wire'); $this->description = $this->l('Accept payments by bank wire.'); $this->confirmUninstall = $this->l('Are you sure you want to delete your details?'); if (!isset($this->owner) || !isset($this->details) || !isset($this->address)) { $this->warning = $this->l('Account owner and details must be configured in order to use this module correctly.'); } if (!count(Currency::checkPaymentCurrencies($this->id))) { $this->warning = $this->l('No currency set for this module'); } $this->extra_mail_vars = array('{bankwire_owner}' => Configuration::get('BANK_WIRE_OWNER'), '{bankwire_details}' => nl2br(Configuration::get('BANK_WIRE_DETAILS')), '{bankwire_address}' => nl2br(Configuration::get('BANK_WIRE_ADDRESS'))); }
public function __construct() { $this->name = 'gcheckout'; $this->tab = 'payments_gateways'; $this->version = '1.2'; $this->author = 'PrestaShop'; $this->currencies = true; $this->currencies_mode = 'radio'; parent::__construct(); $this->displayName = $this->l('Google Checkout'); $this->description = $this->l('Google Checkout API implementation'); if (!sizeof(Currency::checkPaymentCurrencies($this->id))) { $this->warning = $this->l('No currency set for this module'); } /* For 1.4.3 and less compatibility */ $updateConfig = array('PS_OS_CHEQUE', 'PS_OS_PAYMENT', 'PS_OS_PREPARATION', 'PS_OS_SHIPPING', 'PS_OS_CANCELED', 'PS_OS_REFUND', 'PS_OS_ERROR', 'PS_OS_OUTOFSTOCK', 'PS_OS_BANKWIRE', 'PS_OS_PAYPAL', 'PS_OS_WS_PAYMENT'); if (!Configuration::get('PS_OS_PAYMENT')) { foreach ($updateConfig as $u) { if (!Configuration::get($u) && defined('_' . $u . '_')) { Configuration::updateValue($u, constant('_' . $u . '_')); } } } /** Backward compatibility */ require _PS_MODULE_DIR_ . $this->name . '/backward_compatibility/backward.php'; }
public function __construct() { $this->name = 'cheque'; $this->tab = 'payments_gateways'; $this->version = '2.3'; $this->author = 'PrestaShop'; $this->controllers = array('payment', 'validation'); $this->currencies = true; $this->currencies_mode = 'checkbox'; $config = Configuration::getMultiple(array('CHEQUE_NAME', 'CHEQUE_ADDRESS')); if (isset($config['CHEQUE_NAME'])) { $this->chequeName = $config['CHEQUE_NAME']; } if (isset($config['CHEQUE_ADDRESS'])) { $this->address = $config['CHEQUE_ADDRESS']; } $this->bootstrap = true; parent::__construct(); $this->displayName = $this->l('Payments by check'); $this->description = $this->l('This module allows you to accept payments by check.'); $this->confirmUninstall = $this->l('Are you sure you want to delete these details?'); if (!isset($this->chequeName) || !isset($this->address) || empty($this->chequeName) || empty($this->address)) { $this->warning = $this->l('The "Pay to the order of" and "Address" fields must be configured before using this module.'); } if (!count(Currency::checkPaymentCurrencies($this->id))) { $this->warning = $this->l('No currency has been set for this module.'); } $this->extra_mail_vars = array('{cheque_name}' => Configuration::get('CHEQUE_NAME'), '{cheque_address}' => Configuration::get('CHEQUE_ADDRESS'), '{cheque_address_html}' => str_replace("\n", '<br />', Configuration::get('CHEQUE_ADDRESS'))); }
public function __construct() { $this->name = 'twocheckoutpp'; $this->displayName = '2Checkout PayPal Direct'; $this->tab = 'payments_gateways'; $this->version = 0.1; $config = Configuration::getMultiple(array('TWOCHECKOUTPP_SID', 'TWOCHECKOUTPP_SECRET', 'TWOCHECKOUTPP_CURRENCY', 'TWOCHECKOUTPP_CURRENCIES')); if (isset($config['TWOCHECKOUTPP_SID'])) { $this->SID = $config['TWOCHECKOUTPP_SID']; } if (isset($config['TWOCHECKOUTPP_SECRET'])) { $this->SECRET = $config['TWOCHECKOUTPP_SECRET']; } if (isset($config['TWOCHECKOUTPP_CURRENCY'])) { $this->CURRENCY = $config['TWOCHECKOUTPP_CURRENCY']; } if (isset($config['TWOCHECKOUTPP_CURRENCIES'])) { $this->currencies = $config['TWOCHECKOUTPP_CURRENCIES']; } parent::__construct(); /* The parent construct is required for translations */ $this->page = basename(__FILE__, '.php'); $this->description = $this->l('Accept payments with 2Checkout'); if (!isset($this->SID) or !isset($this->currencies)) { $this->warning = $this->l('your 2Checkout Seller ID must be configured in order to use this module correctly'); } if (!Configuration::get('TWOCHECKOUTPP_CURRENCIES')) { $currencies = Currency::getCurrencies(); $authorized_currencies = array(); foreach ($currencies as $currency) { $authorized_currencies[] = $currency['id_currency']; } Configuration::updateValue('TWOCHECKOUTPP_CURRENCIES', implode(',', $authorized_currencies)); } }
public function __construct() { $this->name = 'hipay'; $this->tab = 'payments_gateways'; $this->version = '1.5'; $this->module_key = 'e25bc8f4f9296ef084abf448bca4808a'; $this->currencies = true; $this->currencies_mode = 'radio'; $this->author = 'PrestaShop'; parent::__construct(); $this->displayName = $this->l('Hipay'); $this->description = $this->l('Secure payement with Visa, Mastercard and European solutions.'); $request = ' SELECT iso_code FROM ' . _DB_PREFIX_ . 'country as c LEFT JOIN ' . _DB_PREFIX_ . 'zone as z ON z.id_zone = c.id_zone WHERE '; $result = Db::getInstance()->ExecuteS($request . $this->getRequestZones()); foreach ($result as $num => $iso) { $this->limited_countries[] = $iso['iso_code']; } if ($this->id) { // Define extracted from mapi/mapi_defs.php if (!defined('HIPAY_GATEWAY_URL')) { define('HIPAY_GATEWAY_URL', 'https://' . ($this->env ? '' : 'test.') . 'payment.hipay.com/order/'); } } /** Backward compatibility */ require _PS_MODULE_DIR_ . 'hipay/backward_compatibility/backward.php'; }
public function __construct() { $this->helper = new InvipaypaygateHelper(); $this->controllers = array('payment', 'statuslistener', 'statuscheck', 'validation', 'error'); $this->name = 'invipaypaygate'; $this->tab = 'payments_gateways'; $this->version = '1.0.0'; $this->author = 'inviPay.com'; $this->need_instance = 0; $this->is_eu_compatible = true; $this->currencies = false; $this->bootstrap = true; $this->module_key = '3b5a58e798efb11fa97cee72b09051d2'; parent::__construct(); $this->displayName = 'inviPay.com'; //$this->l('module_display_name'); $this->description = 'Metoda płatności dzięki której sprzedajesz na fakturę z odroczonym terminem płatności, bez żadnego ryzyka.'; //$this->l('module_description'); $this->confirmUninstall = $this->l('uninstall_confirmation'); if (_PS_VERSION_ < '1.5') { require _PS_MODULE_DIR_ . $this->name . '/backward_compatibility/backward.php'; } if (!Configuration::get(InvipaypaygateHelper::ADMIN_CONFIGURATION_KEY)) { $this->warning = $this->l('no_configuration_data'); } $this->configureSmarty(); }
public function __construct() { // Basic Settings $this->name = 'webpaykcc'; $this->tab = 'payments_gateways'; $this->version = '1.0.1'; $this->author = 'Camilo Castro <*****@*****.**>'; $this->need_instance = 1; $this->ps_versions_compliancy = array('min' => '1.6', 'max' => _PS_VERSION_); // This is for the views // This module does not use twitter bootstrap // helpers. But someday in the future will. // meanwhile is turned off. // $this->bootstrap = true; // $this->bootstrap = false; // Call the Parent Constructor parent::__construct(); // Now some messages $this->displayName = $this->l('Webpay KCC Payment'); $this->description = $this->l('Payment Gateway using Chile Transbank Webpay KCC'); $this->confirmUninstall = $this->l('Payments with Webpay KCC will not be possible. Are you sure to uninstall?'); // Call internal setup methods $this->setModuleSettings(); $this->checkModuleRequirements(); }
public function __construct() { parent::__construct(); $this->displayName = $this->l('Mollie Payment Module'); $this->description = $this->l('Mollie Payments'); $this->confirmUninstall = $this->l('Are you sure you want to uninstall the Mollie Payment Module?'); require_once dirname(__FILE__) . '/lib/src/Mollie/API/Autoloader.php'; try { $this->api = new Mollie_API_Client(); $this->api->setApiKey($this->getConfigValue('MOLLIE_API_KEY')); $this->api->addVersionString('Prestashop/' . (defined('_PS_VERSION_') ? _PS_VERSION_ : 'Unknown')); $this->api->addVersionString('MolliePrestashop/' . (isset($this->version) ? $this->version : 'Unknown')); } catch (Mollie_API_Exception_IncompatiblePlatform $e) { Logger::addLog(__METHOD__ . ' - System incompatible: ' . $e->getMessage(), Mollie::CRASH); } catch (Mollie_API_Exception $e) { $this->warning = $this->l('Payment error:') . $e->getMessage(); Logger::addLog(__METHOD__ . ' said: ' . $this->warning, Mollie::CRASH); } $this->statuses = array(Mollie_API_Object_Payment::STATUS_PAID => $this->getConfigValue('MOLLIE_STATUS_PAID'), Mollie_API_Object_Payment::STATUS_CANCELLED => $this->getConfigValue('MOLLIE_STATUS_CANCELLED'), Mollie_API_Object_Payment::STATUS_EXPIRED => $this->getConfigValue('MOLLIE_STATUS_EXPIRED'), Mollie_API_Object_Payment::STATUS_REFUNDED => $this->getConfigValue('MOLLIE_STATUS_REFUNDED'), Mollie_API_Object_Payment::STATUS_OPEN => $this->getConfigValue('MOLLIE_STATUS_OPEN')); // Load all translatable text here so we have a single translation point $this->lang = array(Mollie_API_Object_Payment::STATUS_PAID => $this->l('paid'), Mollie_API_Object_Payment::STATUS_CANCELLED => $this->l('cancelled'), Mollie_API_Object_Payment::STATUS_EXPIRED => $this->l('expired'), Mollie_API_Object_Payment::STATUS_REFUNDED => $this->l('refunded'), Mollie_API_Object_Payment::STATUS_OPEN => $this->l('bankwire pending'), 'This payment method is not available.' => $this->l('This payment method is not available.'), 'Click here to continue' => $this->l('Click here to continue'), 'This payment method is only available for Euros.' => $this->l('This payment method is only available for Euros.'), 'There was an error while processing your request: ' => $this->l('There was an error while processing your request: '), 'The order with this id does not exist.' => $this->l('The order with this id does not exist.'), 'We have not received a definite payment status. You will be notified as soon as we receive a confirmation of the bank/merchant.' => $this->l('We have not received a definite payment status. You will be notified as soon as we receive a confirmation of the bank/merchant.'), 'You have cancelled your payment.' => $this->l('You have cancelled your payment.'), 'Unfortunately your payment was expired.' => $this->l('Unfortunately your payment was expired.'), 'Thank you. Your payment has been received.' => $this->l('Thank you. Your payment has been received.'), 'The transaction has an unexpected status.' => $this->l('The transaction has an unexpected status.'), 'You are not authorised to see this page.' => $this->l('You are not authorised to see this page.'), 'Continue shopping' => $this->l('Continue shopping'), 'Welcome back' => $this->l('Welcome back'), 'Select your bank:' => $this->l('Select your bank:'), 'OK' => $this->l('OK'), 'Return to the homepage' => $this->l('Return to the homepage'), 'Pay with %s' => $this->l('Pay with %s'), 'Refund this order' => $this->l('Refund this order'), 'Mollie refund' => $this->l('Mollie refund'), 'Refund order #%d through the Mollie API.' => $this->l('Refund order #%d through the Mollie API.'), 'iDEAL' => $this->l('iDEAL'), 'Creditcard' => $this->l('Creditcard'), 'Mister Cash' => $this->l('Mister Cash'), 'Bank transfer' => $this->l('Bank transfer'), 'PayPal' => $this->l('PayPal'), 'paysafecard' => $this->l('paysafecard'), 'MiniTix' => $this->l('MiniTix'), 'Micropayments' => $this->l('Micropayments')); // If an update includes a new hook, it normally takes a manual reinstall for it to take effect // This would cause all config values to reset and the Mollie table to be cleared. // $this->reinstall() fixes the hook registration without those sad side effects. $version = $this->getConfigValue('MOLLIE_VERSION'); if ($version === FALSE || version_compare($version, $this->version, '<')) { $this->reinstall(); $this->updateConfigValue('MOLLIE_VERSION', $this->version); } }
/** * @brief Constructor */ public function __construct() { $this->name = 'alliance3'; $this->tab = 'payments_gateways'; $this->version = '1.2.4'; $this->author = 'go4.fi'; $this->className = 'alliance3'; parent::__construct(); $this->displayName = $this->l('Alliance Processing'); $this->description = $this->l('Experienced leader in High Risk ecommerce merchants with both onshore and offshore solutions.'); $this->confirmUninstall = $this->l('Are you sure you want to delete your details?'); $this->ps_versions_compliancy = array('min' => '1.4', 'max' => '1.5.6.2'); if (!extension_loaded('soap')) { $this->_warnings[] = $this->l('In order to use your module, please activate Soap (PHP extension)'); } if (!extension_loaded('openssl')) { $this->_warnings[] = $this->l('In order to use your module, please activate OpenSsl (PHP extension)'); } if (!function_exists('curl_init')) { $this->_warnings[] = $this->l('In order to use your module, please activate cURL (PHP extension)'); } /* Backward compatibility */ require _PS_MODULE_DIR_ . 'alliance3/backward_compatibility/backward.php'; $this->context->smarty->assign('base_dir', __PS_BASE_URI__); }
/** * @brief Constructor */ public function __construct() { $this->name = 'merchantware'; $this->tab = 'payments_gateways'; $this->version = '1.2.4'; $this->author = 'PrestaShop'; $this->className = 'Merchantware'; parent::__construct(); $this->displayName = $this->l('Merchant Warehouse'); $this->description = $this->l('Eliminate expensive and unnecessary gateway fees by partnering with Merchant Warehouse for your payment processing needs!'); $this->confirmUninstall = $this->l('Are you sure you want to delete your details?'); $this->ps_versions_compliancy = array('min' => '1.4', 'max' => _PS_VERSION_); if (!extension_loaded('soap')) { $this->_warnings[] = $this->l('In order to use your module, please activate Soap (PHP extension)'); } if (!extension_loaded('openssl')) { $this->_warnings[] = $this->l('In order to use your module, please activate OpenSsl (PHP extension)'); } if (!function_exists('curl_init')) { $this->_warnings[] = $this->l('In order to use your module, please activate cURL (PHP extension)'); } /* Backward compatibility */ require _PS_MODULE_DIR_ . 'merchantware/backward_compatibility/backward.php'; $this->context->smarty->assign('base_dir', __PS_BASE_URI__); }
public function __construct() { $this->name = 'payubiz'; $this->tab = 'payments_gateways'; $this->version = '2.0'; $this->currencies = true; $this->currencies_mode = 'radio'; parent::__construct(); $this->author = 'PayU India'; $this->page = basename(__FILE__, '.php'); $this->displayName = $this->l('PayUbiz'); $this->description = $this->l('Boost Your Sales With Market Leading Payment Gateway'); $this->confirmUninstall = $this->l('Are you sure you want to delete your details ?'); /* For 1.4.3 and less compatibility */ $updateConfig = array('PS_OS_CHEQUE' => 1, 'PS_OS_PAYMENT' => 2, 'PS_OS_PREPARATION' => 3, 'PS_OS_SHIPPING' => 4, 'PS_OS_DELIVERED' => 5, 'PS_OS_CANCELED' => 6, 'PS_OS_REFUND' => 7, 'PS_OS_ERROR' => 8, 'PS_OS_OUTOFSTOCK' => 9, 'PS_OS_BANKWIRE' => 10, 'PS_OS_PAYPAL' => 11, 'PS_OS_WS_PAYMENT' => 12); foreach ($updateConfig as $u => $v) { if (!Configuration::get($u) || (int) Configuration::get($u) < 1) { if (defined('_' . $u . '_') && (int) constant('_' . $u . '_') > 0) { Configuration::updateValue($u, constant('_' . $u . '_')); } else { Configuration::updateValue($u, $v); } } } }
function __construct() { $this->name = 'cheque'; $this->tab = 'Payment'; $this->version = 2.2; $this->currencies = true; $this->currencies_mode = 'checkbox'; $config = Configuration::getMultiple(array('CHEQUE_NAME', 'CHEQUE_ADDRESS')); if (isset($config['CHEQUE_NAME'])) { $this->chequeName = $config['CHEQUE_NAME']; } if (isset($config['CHEQUE_ADDRESS'])) { $this->address = $config['CHEQUE_ADDRESS']; } parent::__construct(); $this->displayName = $this->l('Cheque'); $this->description = $this->l('Module for accepting payments by cheque'); $this->confirmUninstall = $this->l('Are you sure you want to delete your details ?'); if (!isset($this->chequeName) or !isset($this->address)) { $this->warning = $this->l('\'To the order of\' and address must be configured in order to use this module correctly'); } if (!sizeof(Currency::checkPaymentCurrencies($this->id))) { $this->warning = $this->l('No currency set for this module'); } }
public function __construct() { if (!defined('_PS_VERSION_')) { exit; } include_once dirname(__FILE__) . '/classes/mws.php'; include_once dirname(__FILE__) . '/classes/oc.php'; include_once dirname(__FILE__) . '/classes/partner.php'; include_once dirname(__FILE__) . '/classes/ymlclass.php'; include_once dirname(__FILE__) . '/classes/hforms.php'; include_once dirname(__FILE__) . '/classes/callback.php'; include_once dirname(__FILE__) . '/lib/api.php'; include_once dirname(__FILE__) . '/lib/external_payment.php'; $this->name = 'yamodule'; $this->tab = 'payments_gateways'; $this->version = '1.3.1'; $this->author = 'Яндекс.Деньги'; $this->need_instance = 1; $this->bootstrap = 1; $this->currencies = true; $this->currencies_mode = 'checkbox'; parent::__construct(); $this->cryptor = $this->getCryptor(); $this->displayName = $this->l('Y.CMS Prestashop'); $this->description = $this->l('Yandex.Money, Yandex.Service, Yandex.Metrika, Yandex.Market Orders in the Market'); $this->confirmUninstall = $this->l('Really uninstall the module?'); if (!sizeof(Currency::checkPaymentCurrencies($this->id))) { $this->warning = $this->l('There is no set currency for your module!'); } }
public function __construct() { $this->name = 'ps_checkpayment'; $this->tab = 'payments_gateways'; $this->version = '1.0.8'; $this->author = 'PrestaShop'; $this->controllers = array('payment', 'validation'); $this->currencies = true; $this->currencies_mode = 'checkbox'; $config = Configuration::getMultiple(array('CHEQUE_NAME', 'CHEQUE_ADDRESS')); if (isset($config['CHEQUE_NAME'])) { $this->checkName = $config['CHEQUE_NAME']; } if (isset($config['CHEQUE_ADDRESS'])) { $this->address = $config['CHEQUE_ADDRESS']; } $this->bootstrap = true; parent::__construct(); $this->displayName = $this->trans('Payments by check', array(), 'Modules.CheckPayment.Admin'); $this->description = $this->trans('This module allows you to accept payments by check.', array(), 'Modules.CheckPayment.Admin'); $this->confirmUninstall = $this->trans('Are you sure you want to delete these details?', array(), 'Modules.CheckPayment.Admin'); $this->ps_versions_compliancy = array('min' => '1.7.0.0', 'max' => _PS_VERSION_); if (!isset($this->checkName) || !isset($this->address) || empty($this->checkName) || empty($this->address)) { $this->warning = $this->trans('The "Payee" and "Address" fields must be configured before using this module.', array(), 'Modules.CheckPayment.Admin'); } if (!count(Currency::checkPaymentCurrencies($this->id))) { $this->warning = $this->trans('No currency has been set for this module.', array(), 'Modules.CheckPayment.Admin'); } $this->extra_mail_vars = array('{check_name}' => Configuration::get('CHEQUE_NAME'), '{check_address}' => Configuration::get('CHEQUE_ADDRESS'), '{check_address_html}' => Tools::nl2br(Configuration::get('CHEQUE_ADDRESS'))); }
public function __construct() { include dirname(__FILE__) . '/config.php'; $this->name = 'bitpay'; $this->version = '0.4'; $this->author = 'BitPay'; $this->className = 'bitpay'; $this->currencies = true; $this->currencies_mode = 'checkbox'; $this->tab = 'payments_gateways'; $this->bitpayurl = $bitpayurl; $this->apiurl = $apiurl; $this->sslport = $sslport; $this->verifypeer = $verifypeer; $this->verifyhost = $verifyhost; if (_PS_VERSION_ > '1.5') { $this->controllers = array('payment', 'validation'); } parent::__construct(); $this->page = basename(__FILE__, '.php'); $this->displayName = $this->l('bitpay'); $this->description = $this->l('Accepts Bitcoin payments via BitPay.'); $this->confirmUninstall = $this->l('Are you sure you want to delete your details?'); // Backward compatibility require _PS_MODULE_DIR_ . 'bitpay/backward_compatibility/backward.php'; $this->context->smarty->assign('base_dir', __PS_BASE_URI__); }
public function __construct() { $this->name = 'hipay'; $this->tab = 'payments_gateways'; $this->version = 1.1; $this->currencies = true; $this->currencies_mode = 'radio'; parent::__construct(); $this->displayName = $this->l('Hipay'); $this->description = $this->l('Secure payement with Visa, Mastercard and European solutions.'); $request = ' SELECT iso_code FROM ' . _DB_PREFIX_ . 'country as c LEFT JOIN ' . _DB_PREFIX_ . 'zone as z ON z.id_zone = c.id_zone WHERE '; $result = Db::getInstance()->ExecuteS($request . $this->getRequestZones()); foreach ($result as $num => $iso) { $this->limited_countries[] = $iso['iso_code']; } if ($this->id) { $this->prod = (int) Tools::getValue('HIPAY_PROD', Configuration::get('HIPAY_PROD')); // Define extracted from mapi/mapi_defs.php if (!defined('HIPAY_GATEWAY_URL')) { define('HIPAY_GATEWAY_URL', 'https://' . ($this->prod ? '' : 'test.') . 'payment.hipay.com/order/'); } } }
public function __construct() { $this->name = 'trustly'; $this->tab = 'payments_gateways'; $this->version = '1.3.2'; $this->limited_countries = array('es'); $this->currencies = true; $this->currencies_mode = 'radio'; $this->json_rpc_target_host = (self::$_mode == TRUSTLY_TEST_MODE ? 'test.' : null) . $this->json_rpc_target_host; $this->signup_target_host = (self::$_mode == TRUSTLY_TEST_MODE ? 'test.' : null) . $this->signup_target_host; parent::__construct(); $this->displayName = 'Trustly'; $this->description = $this->l('Allow your customers to pay from their online bank account directly in your web-shop. The only payment method in Spain with 90% bank coverage.'); $this->ps_versions_compliancy = array('min' => '1.4', 'max' => _PS_VERSION_); /* For 1.4.3 and prior compatibility */ $array_name = array('PS_OS_CHEQUE', 'PS_OS_PAYMENT', 'PS_OS_PREPARATION', 'PS_OS_SHIPPING', 'PS_OS_CANCELED', 'PS_OS_REFUND', 'PS_OS_ERROR', 'PS_OS_OUTOFSTOCK', 'PS_OS_BANKWIRE', 'PS_OS_PAYPAL', 'PS_OS_WS_PAYMENT'); if (!Configuration::get('PS_OS_PAYMENT')) { foreach ($array_name as $name) { if (!Configuration::get($name) && defined('_' . $name . '_')) { Configuration::updateValue($name, constant('_' . $name . '_')); } } } /* Backward compatibility */ require _PS_MODULE_DIR_ . 'trustly/backward_compatibility/backward.php'; }
public function __construct() { parent::__construct(); if ($this->active and !extension_loaded('curl')) { $this->warning = $this->getL('curl_required'); } }
public function __construct() { $this->name = 'payplug'; $this->tab = 'payments_gateways'; $this->version = '1.0.1'; $this->author = 'PayPlug'; $this->module_key = '1ee28a8fb5e555e274bd8c2e1c45e31a'; parent::__construct(); // For 1.6 $this->bootstrap = true; // Backward compatibility if (version_compare(_PS_VERSION_, '1.5', '<')) { require _PS_MODULE_DIR_ . $this->name . '/backward_compatibility/backward.php'; } // Add warning if prestashop is an older version than 1.4 if (version_compare(_PS_VERSION_, '1.4', '<')) { $this->warning = $this->l('Sorry Payplug is not compatible with Prestashop for versions < 1.4. Please delete the payplug directory in the Prestashop modules directory for your Prestashop system to get back to normal.'); } $this->currencies = true; $this->currencies_mode = 'checkbox'; // Change descriptionn and display name $this->displayName = $this->l('PayPlug – Simple and secure online payments'); $this->description = $this->l('The simplest online payment solution: no setup fees, no fixed fees, and no merchant account required!'); $this->confirmUninstall = $this->l('Are you sure you wish to uninstall this module and delete your settings?'); if (version_compare(_PS_VERSION_, '1.5', '<')) { $cookie_admin = new Cookie('psAdmin', Tools::substr($_SERVER['PHP_SELF'], Tools::strlen(__PS_BASE_URI__), -10)); if (Tools::getValue('tab') == 'AdminPayment' && Tools::getValue('token') != Tools::getAdminTokenLite('AdminPayment')) { // Force admin status $this->context->cookie->profile = $cookie_admin->profile; $url = 'index.php?tab=AdminPayment'; $url .= '&token=' . Tools::getAdminTokenLite('AdminPayment'); Tools::redirectAdmin($url); } } }
public function __construct() { $this->name = 'bankwire'; $this->tab = 'Payment'; $this->version = '0.5'; $this->currencies = true; $this->currencies_mode = 'checkbox'; $config = Configuration::getMultiple(array('BANK_WIRE_DETAILS', 'BANK_WIRE_OWNER', 'BANK_WIRE_ADDRESS')); if (isset($config['BANK_WIRE_OWNER'])) { $this->owner = $config['BANK_WIRE_OWNER']; } if (isset($config['BANK_WIRE_DETAILS'])) { $this->details = $config['BANK_WIRE_DETAILS']; } if (isset($config['BANK_WIRE_ADDRESS'])) { $this->address = $config['BANK_WIRE_ADDRESS']; } parent::__construct(); $this->displayName = $this->l('Bank Wire'); $this->description = $this->l('Accept payments by bank wire'); $this->confirmUninstall = $this->l('Are you sure you want to delete your details?'); if (!isset($this->owner) or !isset($this->details) or !isset($this->address)) { $this->warning = $this->l('Account owner and details must be configured in order to use this module correctly'); } if (!sizeof(Currency::checkPaymentCurrencies($this->id))) { $this->warning = $this->l('No currency set for this module'); } }
public function __construct() { $this->name = 'payfortfort'; $this->version = '1.6.1'; $this->author = 'Payfort'; $this->tab = 'payments_gateways'; $this->author_uri = 'https://github.com/payfort/prestashop-payfort'; $this->fort_available_currencies = array('USD', 'AUD', 'CAD', 'EUR', 'GBP', 'NZD', 'SAR', 'JOD', 'QAR', 'AED'); //$this->bootstrap = true; //$this->ps_versions_compliancy = array('min' => '1.6', 'max' => _PS_VERSION_); parent::__construct(); $this->displayName = 'Payfort FORT Gateway'; $this->description = $this->l('Receive payment with Credit or Debit Card'); /* For 1.4.3 and less compatibility */ $updateConfig = array('PS_OS_CHEQUE' => 1, 'PS_OS_PAYMENT' => 2, 'PS_OS_PREPARATION' => 3, 'PS_OS_SHIPPING' => 4, 'PS_OS_DELIVERED' => 5, 'PS_OS_CANCELED' => 6, 'PS_OS_REFUND' => 7, 'PS_OS_ERROR' => 8, 'PS_OS_OUTOFSTOCK' => 9, 'PS_OS_BANKWIRE' => 10, 'PS_OS_PAYPAL' => 11, 'PS_OS_WS_PAYMENT' => 12); foreach ($updateConfig as $u => $v) { if (!Configuration::get($u) || (int) Configuration::get($u) < 1) { if (defined('_' . $u . '_') && (int) constant('_' . $u . '_') > 0) { Configuration::updateValue($u, constant('_' . $u . '_')); } else { Configuration::updateValue($u, $v); } } } /* Check if cURL is enabled */ if (!is_callable('curl_exec')) { $this->warning = $this->l('cURL extension must be enabled on your server to use this module.'); } /* Backward compatibility */ require _PS_MODULE_DIR_ . $this->name . '/backward_compatibility/backward.php'; }
public function __construct() { $this->name = 'payu'; $this->tab = 'payments_gateways'; $this->version = '1.2'; $this->author = 'PrestaShop'; $this->currencies = true; $this->currencies_mode = 'radio'; parent::__construct(); $this->_errors = array(); $this->page = basename(__FILE__, '.php'); $this->displayName = $this->l('PayUMoney Checkout'); $this->description = $this->l('PayUMoney Checkout API implementation'); if (!sizeof(Currency::checkPaymentCurrencies($this->id))) { $this->warning = $this->l('No currency set for this module'); } /* For 1.4.3 and less compatibility */ $updateConfig = array('PS_OS_CHEQUE' => 1, 'PS_OS_PAYMENT' => 2, 'PS_OS_PREPARATION' => 3, 'PS_OS_SHIPPING' => 4, 'PS_OS_DELIVERED' => 5, 'PS_OS_CANCELED' => 6, 'PS_OS_REFUND' => 7, 'PS_OS_ERROR' => 8, 'PS_OS_OUTOFSTOCK' => 9, 'PS_OS_BANKWIRE' => 10, 'PS_OS_PAYPAL' => 11, 'PS_OS_WS_PAYMENT' => 12); foreach ($updateConfig as $u => $v) { if (!Configuration::get($u) || (int) Configuration::get($u) < 1) { if (defined('_' . $u . '_') && (int) constant('_' . $u . '_') > 0) { Configuration::updateValue($u, constant('_' . $u . '_')); } else { Configuration::updateValue($u, $v); } } } }
public function __construct() { $this->name = 'paypal'; $this->tab = 'payments_gateways'; $this->version = '3.10.1'; $this->author = 'PrestaShop'; $this->is_eu_compatible = 1; $this->currencies = true; $this->currencies_mode = 'radio'; parent::__construct(); $this->displayName = $this->l('PayPal'); $this->description = $this->l('Accepts payments by credit cards (CB, Visa, MasterCard, Amex, Aurore, Cofinoga, 4 stars) with PayPal.'); $this->confirmUninstall = $this->l('Are you sure you want to delete your details?'); $this->page = basename(__FILE__, '.php'); if (version_compare(_PS_VERSION_, '1.5', '<')) { $mobile_enabled = (int) Configuration::get('PS_MOBILE_DEVICE'); require _PS_MODULE_DIR_ . $this->name . '/backward_compatibility/backward.php'; } else { $mobile_enabled = (int) Configuration::get('PS_ALLOW_MOBILE_DEVICE'); } if (self::isInstalled($this->name)) { $this->loadDefaults(); if ($mobile_enabled && $this->active) { $this->checkMobileCredentials(); } elseif ($mobile_enabled && !$this->active) { $this->checkMobileNeeds(); } } else { $this->checkMobileNeeds(); } }
public function __construct() { $this->name = 'cashway'; $this->tab = 'payments_gateways'; $this->version = '0.14.2'; define('CW_VERSION', $this->version); $this->author = 'CashWay'; $this->need_instance = 1; $this->bootstrap = true; $this->currencies = true; $this->currencies_mode = 'checkbox'; $this->controllers = array('payment', 'validation', 'notification'); $this->is_eu_compatible = 1; $this->ps_versions_compliancy = array('min' => '1.5', 'max' => '1.7'); parent::__construct(); $this->displayName = $this->l('CashWay'); $this->description = $this->l('Now your customers can pay their orders with cash.'); $this->confirmUninstall = $this->l('Are you sure you want to delete these details?'); $this->limited_countries = array('FR'); $this->limited_currencies = array('EUR'); if (!Configuration::get('CASHWAY_API_KEY')) { $this->warning = $this->l('Missing API Key.'); } else { $this->cashway_api_key = Configuration::get('CASHWAY_API_KEY'); } if (!Configuration::get('CASHWAY_API_SECRET')) { $this->warning .= $this->l('Missing API Secret.'); } else { $this->cashway_api_secret = Configuration::get('CASHWAY_API_SECRET'); } if (false === function_exists('curl_init')) { $this->warning = $this->l('To be able to use this module, please activate cURL (PHP extension).'); } }
public function __construct() { $this->name = 'stripejs'; $this->tab = 'payments_gateways'; $this->version = '1.0.2Beta'; $this->author = 'PrestaShop + Ollie McFarlane'; $this->need_instance = 0; $this->currencies = true; $this->currencies_mode = 'checkbox'; parent::__construct(); $this->displayName = $this->l('Stripe'); $this->description = $this->l('Accept payments by Credit Card with Stripe (Visa, Mastercard, Amex, Discover and Diners Club)'); $this->confirmUninstall = $this->l('Warning: all the Stripe customers credit cards and transaction details saved in your database will be deleted. Are you sure you want uninstall this module?'); /* Backward compatibility */ if (_PS_VERSION_ < '1.5') { $this->backward_error = $this->l('In order to work properly in PrestaShop v1.4, the Stripe module requires the backward compatibility module at least v0.3.') . '<br />' . $this->l('You can download this module for free here: http://addons.prestashop.com/en/modules-prestashop/6222-backwardcompatibility.html'); if (file_exists(_PS_MODULE_DIR_ . 'backwardcompatibility/backward_compatibility/backward.php')) { include _PS_MODULE_DIR_ . 'backwardcompatibility/backward_compatibility/backward.php'; $this->backward = true; } else { $this->warning = $this->backward_error; } } else { $this->backward = true; } }
public function __construct() { $this->name = 'bankwire'; $this->tab = 'payments_gateways'; $this->version = '1.0.8'; $this->author = 'PrestaShop'; $this->controllers = array('payment', 'validation'); $this->is_eu_compatible = 1; $this->currencies = true; $this->currencies_mode = 'checkbox'; $config = Configuration::getMultiple(array('BANK_WIRE_DETAILS', 'BANK_WIRE_OWNER', 'BANK_WIRE_ADDRESS')); if (!empty($config['BANK_WIRE_OWNER'])) { $this->owner = $config['BANK_WIRE_OWNER']; } if (!empty($config['BANK_WIRE_DETAILS'])) { $this->details = $config['BANK_WIRE_DETAILS']; } if (!empty($config['BANK_WIRE_ADDRESS'])) { $this->address = $config['BANK_WIRE_ADDRESS']; } $this->bootstrap = true; parent::__construct(); $this->displayName = $this->l('Bank wire'); $this->description = $this->l('Accept payments for your products via bank wire transfer.'); $this->confirmUninstall = $this->l('Are you sure about removing these details?'); if (!isset($this->owner) || !isset($this->details) || !isset($this->address)) { $this->warning = $this->l('Account owner and account details must be configured before using this module.'); } if (!count(Currency::checkPaymentCurrencies($this->id))) { $this->warning = $this->l('No currency has been set for this module.'); } $this->extra_mail_vars = array('{bankwire_owner}' => Configuration::get('BANK_WIRE_OWNER'), '{bankwire_details}' => nl2br(Configuration::get('BANK_WIRE_DETAILS')), '{bankwire_address}' => nl2br(Configuration::get('BANK_WIRE_ADDRESS'))); }
public function __construct() { $this->name = 'sign2pay'; $this->tab = 'payments_gateways'; $this->version = '0.1.0'; $this->author = 'Berkan Düzgün'; $this->controllers = array('payment', 'validation'); $this->availableCurrencies = array('EUR'); $config = Configuration::getMultiple(array('SIGN2PAY_APPLICATION_TOKEN', 'SIGN2PAY_MERCHANT_ID', 'SIGN2PAY_API_TOKEN')); if (!empty($config['SIGN2PAY_MERCHANT_ID'])) { $this->merchandId = $config['SIGN2PAY_MERCHANT_ID']; } if (!empty($config['SIGN2PAY_APPLICATION_TOKEN'])) { $this->applicationToken = $config['SIGN2PAY_APPLICATION_TOKEN']; } if (!empty($config['SIGN2PAY_API_TOKEN'])) { $this->apiToken = $config['SIGN2PAY_API_TOKEN']; } parent::__construct(); $this->displayName = $this->l('Sign2Pay'); $this->description = $this->l('Sign2Pay payment method.'); $this->confirmUninstall = $this->l('Are you sure about removing these details?'); if (!isset($this->merchandId) || !isset($this->applicationToken) || !isset($this->apiToken)) { $this->warning = $this->l('API credentials must be configured before using this module.'); } if (!count(Currency::checkPaymentCurrencies($this->id))) { $this->warning = $this->l('No currency has been set for this module.'); } $this->extra_mail_vars = array('{sign2pay_merchant_id}' => Configuration::get('SIGN2PAY_MERCHANT_ID'), '{sign2pay_application_token}' => nl2br(Configuration::get('SIGN2PAY_APPLICATION_TOKEN')), '{sign2pay_api_token}' => nl2br(Configuration::get('SIGN2PAY_API_TOKEN'))); }