OpenCart 🇺🇦

Схема

public mixed payment_method ( )

Аргументы

Аргумент Возможный тип Описание
У метода нет аргументов

Описание

Метод пока еще не документирован.

Исходный код

if ($this->config->get('amazon_checkout_mode') == 'sandbox') {
	$amazon_payment_js = 'https://static-eu.payments-amazon.com/cba/js/gb/sandbox/PaymentWidgets.js';
} elseif ($this->config->get('amazon_checkout_mode') == 'live') {
	$amazon_payment_js = 'https://static-eu.payments-amazon.com/cba/js/gb/PaymentWidgets.js';
}

$this->document->addScript($amazon_payment_js);

$this->document->setTitle($this->language->get('heading_title'));

if (isset($this->session->data['cba'])) {
	$contract_id = $this->session->data['cba']['contract_id'];
} else {
	$this->redirect($this->url->link('common/home'));
}

$this->language->load('payment/amazon_checkout');

$this->data['heading_title'] = $this->language->get('heading_title');
$this->data['heading_payment'] = $this->language->get('heading_payment');
$this->data['text_back'] = $this->language->get('text_back');
$this->data['text_continue'] = $this->language->get('text_continue');
$this->data['error_payment_method'] = $this->language->get('error_payment_method');

$this->data['merchant_id'] = $this->config->get('amazon_checkout_merchant_id');
$this->data['confirm_order'] = $this->url->link('payment/amazon_checkout/confirm', '', 'SSL');

$this->data['continue'] = $this->url->link('payment/amazon_checkout/confirm', '', 'SSL');
$this->data['back'] = $this->url->link('payment/amazon_checkout/address', '', 'SSL');
$this->data['text_back'] = $this->language->get('text_back');

if (file_exists(DIR_TEMPLATE . $this->config->get('config_template') . '/template/payment/amazon_checkout_payment.tpl')) {
	$this->template = $this->config->get('config_template') . '/template/payment/amazon_checkout_payment.tpl';
} else {
	$this->template = 'default/template/payment/amazon_checkout_payment.tpl';
}

$this->children = array(
	'common/column_left',
	'common/column_right',
	'common/content_top',
	'common/content_bottom',
	'common/footer',
	'common/header'
);

$this->response->setOutput($this->render(true));