OpenCart 🇺🇦

Схема

public mixed savedListings ( )

Аргументы

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

Описание

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

Исходный код

$this->data = array_merge($this->data, $this->load->language('openbay/amazon_listingsaved'));

$this->document->setTitle($this->language->get('lang_title'));
$this->document->addStyle('view/stylesheet/openbay.css');
$this->document->addScript('view/javascript/openbay/faq.js');

$this->data['link_overview'] = $this->url->link('openbay/amazon/overview', 'token=' . $this->session->data['token'], 'SSL');

$this->data['breadcrumbs'] = array();
$this->data['breadcrumbs'][] = array(
	'href'      => HTTPS_SERVER . 'index.php?route=common/home&token=' . $this->session->data['token'],
	'text'      => $this->language->get('text_home'),
	'separator' => false
);
$this->data['breadcrumbs'][] = array(
	'href'      => HTTPS_SERVER . 'index.php?route=extension/openbay&token=' . $this->session->data['token'],
	'text'      => $this->language->get('lang_openbay'),
	'separator' => ' :: '
);
$this->data['breadcrumbs'][] = array(
	'href'      => HTTPS_SERVER . 'index.php?route=openbay/amazon/overview&token=' . $this->session->data['token'],
	'text'      => $this->language->get('lang_overview'),
	'separator' => ' :: '
);

$this->data['breadcrumbs'][] = array(
	'href'      => HTTPS_SERVER . 'index.php?route=openbay/amazon/savedListings&token=' . $this->session->data['token'],
	'text'      => $this->language->get('lang_saved_listings'),
	'separator' => ' :: '
);

$this->template = 'openbay/amazon_saved_listings.tpl';
$this->children = array(
	'common/header',
	'common/footer'
);

$this->data['token'] = $this->session->data['token'];
$this->load->model('openbay/amazon');
$saved_products = $this->model_openbay_amazon->getSavedProducts();

$this->data['saved_products'] = array();

foreach($saved_products as $saved_product) {
	$this->data['saved_products'][] = array(
		'product_id' => $saved_product['product_id'],
		'product_name' => $saved_product['product_name'],
		'product_model' => $saved_product['product_model'],
		'product_sku' => $saved_product['product_sku'],
		'amazon_sku' => $saved_product['amazon_sku'],
		'var' => $saved_product['var'],
		'edit_link' => $this->url->link('openbay/amazon_product', 'token=' . $this->session->data['token'] . '&product_id=' . $saved_product['product_id'] . '&var=' . $saved_product['var'], 'SSL'),
	);
}

$this->data['deleteSavedAjax'] = $this->url->link('openbay/amazon/deleteSavedAjax', 'token=' . $this->session->data['token'], 'SSL');
$this->data['uploadSavedAjax'] = $this->url->link('openbay/amazon_product/uploadSavedAjax', 'token=' . $this->session->data['token'], 'SSL');

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