// Merge -> revision 8014
This commit is contained in:
@@ -25,7 +25,7 @@
|
||||
* International Registered Trademark & Property of PrestaShop SA
|
||||
*/
|
||||
|
||||
if (!defined('_CAN_LOAD_FILES_'))
|
||||
if (!defined('_PS_VERSION_'))
|
||||
exit;
|
||||
|
||||
class authorizeAIM extends PaymentModule
|
||||
|
||||
@@ -25,7 +25,7 @@
|
||||
* International Registered Trademark & Property of PrestaShop SA
|
||||
*/
|
||||
|
||||
if (!defined('_CAN_LOAD_FILES_'))
|
||||
if (!defined('_PS_VERSION_'))
|
||||
exit;
|
||||
|
||||
class BankWire extends PaymentModule
|
||||
|
||||
@@ -25,7 +25,7 @@
|
||||
* International Registered Trademark & Property of PrestaShop SA
|
||||
*/
|
||||
|
||||
if (!defined('_CAN_LOAD_FILES_'))
|
||||
if (!defined('_PS_VERSION_'))
|
||||
exit;
|
||||
|
||||
class BirthdayPresent extends Module
|
||||
|
||||
@@ -25,7 +25,7 @@
|
||||
* International Registered Trademark & Property of PrestaShop SA
|
||||
*/
|
||||
|
||||
if (!defined('_CAN_LOAD_FILES_'))
|
||||
if (!defined('_PS_VERSION_'))
|
||||
exit;
|
||||
|
||||
class BlockAdvertising extends Module
|
||||
|
||||
@@ -25,7 +25,7 @@
|
||||
* International Registered Trademark & Property of PrestaShop SA
|
||||
*/
|
||||
|
||||
if (!defined('_CAN_LOAD_FILES_'))
|
||||
if (!defined('_PS_VERSION_'))
|
||||
exit;
|
||||
|
||||
class BlockBestSellers extends Module
|
||||
|
||||
@@ -25,7 +25,7 @@
|
||||
* International Registered Trademark & Property of PrestaShop SA
|
||||
*/
|
||||
|
||||
if (!defined('_CAN_LOAD_FILES_'))
|
||||
if (!defined('_PS_VERSION_'))
|
||||
exit;
|
||||
|
||||
class BlockCart extends Module
|
||||
|
||||
@@ -25,7 +25,7 @@
|
||||
* International Registered Trademark & Property of PrestaShop SA
|
||||
*/
|
||||
|
||||
if (!defined('_CAN_LOAD_FILES_'))
|
||||
if (!defined('_PS_VERSION_'))
|
||||
exit;
|
||||
|
||||
class BlockCategories extends Module
|
||||
|
||||
@@ -24,7 +24,8 @@
|
||||
* @license http://opensource.org/licenses/afl-3.0.php Academic Free License (AFL 3.0)
|
||||
* International Registered Trademark & Property of PrestaShop SA
|
||||
*/
|
||||
if (!defined('_CAN_LOAD_FILES_'))
|
||||
|
||||
if (!defined('_PS_VERSION_'))
|
||||
exit;
|
||||
|
||||
class BlockCms extends Module
|
||||
@@ -110,8 +111,14 @@ class BlockCms extends Module
|
||||
LEFT JOIN `'._DB_PREFIX_.'cms_block_lang` cbl ON (cbl.`id_cms_block` = cb.`id_cms_block`)
|
||||
WHERE cb.`id_cms_block` = '.(int)$id_cms_block);
|
||||
|
||||
$store_display_update = array(0, $size = count($cmsBlocks), $display = Configuration::get('PS_STORES_DISPLAY_FOOTER'));
|
||||
foreach ($cmsBlocks AS $cmsBlock)
|
||||
{
|
||||
$cmsBlocks['name'][(int)$cmsBlock['id_lang']] = $cmsBlock['name'];
|
||||
if ($store_display_update['0'] < $store_display_update['1'])
|
||||
$cmsBlocks[$store_display_update['0']]['display_store'] = $store_display_update['2'];
|
||||
++$store_display_update['0'];
|
||||
}
|
||||
return $cmsBlocks;
|
||||
}
|
||||
|
||||
@@ -589,6 +596,10 @@ class BlockCms extends Module
|
||||
INSERT INTO `'._DB_PREFIX_.'cms_block_lang` (`id_cms_block`, `id_lang`, `name`)
|
||||
VALUES('.(int)$id_cms_block.', '.(int)$language['id_lang'].',
|
||||
"'.pSQL(Tools::getValue('block_name_'.$language['id_lang'])).'")');
|
||||
|
||||
Db::getInstance()->Execute('
|
||||
UPDATE `'._DB_PREFIX_.'cms_block
|
||||
SET `display_store` = '.Configuration::get('PS_STORES_DISPLAY_FOOTER'));
|
||||
}
|
||||
elseif (Tools::isSubmit('editBlockCMS'))
|
||||
{
|
||||
@@ -619,6 +630,8 @@ class BlockCms extends Module
|
||||
`display_store` = '.(int)(Tools::getValue('PS_STORES_DISPLAY_CMS')).'
|
||||
WHERE `id_cms_block` = '.(int)($id_cms_block));
|
||||
|
||||
Configuration::updateValue('PS_STORES_DISPLAY_FOOTER', (int)(Tools::getValue('PS_STORES_DISPLAY_CMS')));
|
||||
|
||||
foreach ($languages as $language)
|
||||
Db::getInstance()->Execute('
|
||||
UPDATE `'._DB_PREFIX_.'cms_block_lang`
|
||||
|
||||
@@ -25,7 +25,7 @@
|
||||
* International Registered Trademark & Property of PrestaShop SA
|
||||
*/
|
||||
|
||||
if (!defined('_CAN_LOAD_FILES_'))
|
||||
if (!defined('_PS_VERSION_'))
|
||||
exit;
|
||||
|
||||
class BlockCurrencies extends Module
|
||||
|
||||
@@ -25,7 +25,7 @@
|
||||
* International Registered Trademark & Property of PrestaShop SA
|
||||
*/
|
||||
|
||||
if (!defined('_CAN_LOAD_FILES_'))
|
||||
if (!defined('_PS_VERSION_'))
|
||||
exit;
|
||||
|
||||
class blockcustomerprivacy extends Module
|
||||
@@ -157,4 +157,4 @@ class blockcustomerprivacy extends Module
|
||||
));
|
||||
return $this->display(__FILE__, 'blockcustomerprivacy.tpl');
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -25,7 +25,7 @@
|
||||
* International Registered Trademark & Property of PrestaShop SA
|
||||
*/
|
||||
|
||||
if (!defined('_CAN_LOAD_FILES_'))
|
||||
if (!defined('_PS_VERSION_'))
|
||||
exit;
|
||||
|
||||
class BlockLanguages extends Module
|
||||
|
||||
@@ -170,9 +170,9 @@ function reloadContent(params_plus)
|
||||
reloadContent();
|
||||
return false;
|
||||
});
|
||||
ajaxCart.overrideButtonsInThePage();
|
||||
}
|
||||
});
|
||||
|
||||
ajaxQueries.push(ajaxQuery);
|
||||
}
|
||||
|
||||
|
||||
@@ -25,7 +25,7 @@
|
||||
* International Registred Trademark & Property of PrestaShop SA
|
||||
*/
|
||||
|
||||
if (!defined('_CAN_LOAD_FILES_'))
|
||||
if (!defined('_PS_VERSION_'))
|
||||
exit;
|
||||
|
||||
class BlockLayered extends Module
|
||||
@@ -1491,4 +1491,4 @@ if (!isset($doneCategories[(int)$id_category]['p']))
|
||||
else
|
||||
return $share_url;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
+165
-148
@@ -25,7 +25,7 @@
|
||||
* International Registered Trademark & Property of PrestaShop SA
|
||||
*/
|
||||
|
||||
if (!defined('_CAN_LOAD_FILES_'))
|
||||
if (!defined('_PS_VERSION_'))
|
||||
exit;
|
||||
|
||||
class BlockLink extends Module
|
||||
@@ -35,56 +35,56 @@ class BlockLink extends Module
|
||||
|
||||
public function __construct()
|
||||
{
|
||||
$this->name = 'blocklink';
|
||||
$this->tab = 'front_office_features';
|
||||
$this->version = '1.5';
|
||||
$this->name = 'blocklink';
|
||||
$this->tab = 'front_office_features';
|
||||
$this->version = '1.5';
|
||||
$this->author = 'PrestaShop';
|
||||
$this->need_instance = 0;
|
||||
|
||||
parent::__construct();
|
||||
|
||||
$this->displayName = $this->l('Link block');
|
||||
$this->description = $this->l('Adds a block with additional links.');
|
||||
$this->displayName = $this->l('Link block');
|
||||
$this->description = $this->l('Adds a block with additional links.');
|
||||
$this->confirmUninstall = $this->l('Are you sure you want to delete all your links ?');
|
||||
}
|
||||
|
||||
public function install()
|
||||
{
|
||||
if (!parent::install() OR
|
||||
!$this->registerHook('leftColumn') OR
|
||||
!Db::getInstance()->Execute('
|
||||
CREATE TABLE '._DB_PREFIX_.'blocklink (
|
||||
`id_blocklink` int(2) NOT NULL AUTO_INCREMENT,
|
||||
`url` varchar(255) NOT NULL,
|
||||
`new_window` TINYINT(1) NOT NULL,
|
||||
PRIMARY KEY(`id_blocklink`))
|
||||
ENGINE='._MYSQL_ENGINE_.' default CHARSET=utf8') OR
|
||||
!Db::getInstance()->Execute('
|
||||
CREATE TABLE '._DB_PREFIX_.'blocklink_lang (
|
||||
`id_blocklink` int(2) NOT NULL,
|
||||
`id_lang` int(2) NOT NULL,
|
||||
`text` varchar(64) NOT NULL,
|
||||
PRIMARY KEY(`id_blocklink`, `id_lang`))
|
||||
ENGINE='._MYSQL_ENGINE_.' default CHARSET=utf8') OR
|
||||
!Configuration::updateValue('PS_BLOCKLINK_TITLE', array('1' => 'Block link', '2' => 'Bloc lien')))
|
||||
return false;
|
||||
return true;
|
||||
if (!parent::install() OR
|
||||
!$this->registerHook('leftColumn') OR
|
||||
!Db::getInstance()->Execute('
|
||||
CREATE TABLE '._DB_PREFIX_.'blocklink (
|
||||
`id_blocklink` int(2) NOT NULL AUTO_INCREMENT,
|
||||
`url` varchar(255) NOT NULL,
|
||||
`new_window` TINYINT(1) NOT NULL,
|
||||
PRIMARY KEY(`id_blocklink`))
|
||||
ENGINE='._MYSQL_ENGINE_.' default CHARSET=utf8') OR
|
||||
!Db::getInstance()->Execute('
|
||||
CREATE TABLE '._DB_PREFIX_.'blocklink_lang (
|
||||
`id_blocklink` int(2) NOT NULL,
|
||||
`id_lang` int(2) NOT NULL,
|
||||
`text` varchar(64) NOT NULL,
|
||||
PRIMARY KEY(`id_blocklink`, `id_lang`))
|
||||
ENGINE='._MYSQL_ENGINE_.' default CHARSET=utf8') OR
|
||||
!Configuration::updateValue('PS_BLOCKLINK_TITLE', array('1' => 'Block link', '2' => 'Bloc lien')))
|
||||
return false;
|
||||
return true;
|
||||
}
|
||||
|
||||
public function uninstall()
|
||||
{
|
||||
if (!parent::uninstall() OR
|
||||
!Db::getInstance()->Execute('DROP TABLE '._DB_PREFIX_.'blocklink') OR
|
||||
!Db::getInstance()->Execute('DROP TABLE '._DB_PREFIX_.'blocklink_lang') OR
|
||||
!Configuration::deleteByName('PS_BLOCKLINK_TITLE') OR
|
||||
!Configuration::deleteByName('PS_BLOCKLINK_URL'))
|
||||
return false;
|
||||
return true;
|
||||
if (!parent::uninstall() OR
|
||||
!Db::getInstance()->Execute('DROP TABLE '._DB_PREFIX_.'blocklink') OR
|
||||
!Db::getInstance()->Execute('DROP TABLE '._DB_PREFIX_.'blocklink_lang') OR
|
||||
!Configuration::deleteByName('PS_BLOCKLINK_TITLE') OR
|
||||
!Configuration::deleteByName('PS_BLOCKLINK_URL'))
|
||||
return false;
|
||||
return true;
|
||||
}
|
||||
|
||||
public function hookLeftColumn($params)
|
||||
{
|
||||
$links = $this->getLinks();
|
||||
$links = $this->getLinks();
|
||||
|
||||
$this->context->smarty->assign(array(
|
||||
'blocklink_links' => $links,
|
||||
@@ -92,7 +92,7 @@ class BlockLink extends Module
|
||||
'url' => Configuration::get('PS_BLOCKLINK_URL'),
|
||||
'lang' => 'text_'.$this->context->language->id
|
||||
));
|
||||
if (!$links)
|
||||
if (!$links)
|
||||
return false;
|
||||
return $this->display(__FILE__, 'blocklink.tpl');
|
||||
}
|
||||
@@ -104,14 +104,14 @@ class BlockLink extends Module
|
||||
|
||||
public function getLinks()
|
||||
{
|
||||
$result = array();
|
||||
/* Get id and url */
|
||||
if (!$links = Db::getInstance()->ExecuteS('SELECT `id_blocklink`, `url`, `new_window` FROM '._DB_PREFIX_.'blocklink'.((int)(Configuration::get('PS_BLOCKLINK_ORDERWAY')) == 1 ? ' ORDER BY `id_blocklink` DESC' : '')))
|
||||
return false;
|
||||
$i = 0;
|
||||
foreach ($links AS $link)
|
||||
{
|
||||
$result[$i]['id'] = $link['id_blocklink'];
|
||||
$result = array();
|
||||
/* Get id and url */
|
||||
if (!$links = Db::getInstance()->ExecuteS('SELECT `id_blocklink`, `url`, `new_window` FROM '._DB_PREFIX_.'blocklink'.((int)(Configuration::get('PS_BLOCKLINK_ORDERWAY')) == 1 ? ' ORDER BY `id_blocklink` DESC' : '')))
|
||||
return false;
|
||||
$i = 0;
|
||||
foreach ($links AS $link)
|
||||
{
|
||||
$result[$i]['id'] = $link['id_blocklink'];
|
||||
$result[$i]['url'] = $link['url'];
|
||||
$result[$i]['newWindow'] = $link['new_window'];
|
||||
/* Get multilingual text */
|
||||
@@ -121,58 +121,58 @@ class BlockLink extends Module
|
||||
$result[$i]['text_'.$text['id_lang']] = $text['text'];
|
||||
$i++;
|
||||
}
|
||||
return $result;
|
||||
return $result;
|
||||
}
|
||||
|
||||
public function addLink()
|
||||
{
|
||||
/* Url registration */
|
||||
if (!Db::getInstance()->Execute('INSERT INTO '._DB_PREFIX_.'blocklink VALUES (NULL, \''.pSQL($_POST['url']).'\', '.((isset($_POST['newWindow']) AND $_POST['newWindow']) == 'on' ? 1 : 0).')') OR !$lastId = Db::getInstance()->Insert_ID())
|
||||
return false;
|
||||
/* Multilingual text */
|
||||
$languages = Language::getLanguages();
|
||||
$defaultLanguage = (int)(Configuration::get('PS_LANG_DEFAULT'));
|
||||
if (!$languages)
|
||||
return false;
|
||||
foreach ($languages AS $language)
|
||||
if (!empty($_POST['text_'.$language['id_lang']]))
|
||||
{
|
||||
if (!Db::getInstance()->Execute('INSERT INTO '._DB_PREFIX_.'blocklink_lang VALUES ('.(int)($lastId).', '.(int)($language['id_lang']).', \''.pSQL($_POST['text_'.$language['id_lang']]).'\')'))
|
||||
return false;
|
||||
}
|
||||
else
|
||||
if (!Db::getInstance()->Execute('INSERT INTO '._DB_PREFIX_.'blocklink_lang VALUES ('.(int)($lastId).', '.(int)($language['id_lang']).', \''.pSQL($_POST['text_'.$defaultLanguage]).'\')'))
|
||||
return false;
|
||||
return true;
|
||||
/* Url registration */
|
||||
if (!Db::getInstance()->Execute('INSERT INTO '._DB_PREFIX_.'blocklink VALUES (NULL, \''.pSQL($_POST['url']).'\', '.((isset($_POST['newWindow']) AND $_POST['newWindow']) == 'on' ? 1 : 0).')') OR !$lastId = Db::getInstance()->Insert_ID())
|
||||
return false;
|
||||
/* Multilingual text */
|
||||
$languages = Language::getLanguages();
|
||||
$defaultLanguage = (int)(Configuration::get('PS_LANG_DEFAULT'));
|
||||
if (!$languages)
|
||||
return false;
|
||||
foreach ($languages AS $language)
|
||||
if (!empty($_POST['text_'.$language['id_lang']]))
|
||||
{
|
||||
if (!Db::getInstance()->Execute('INSERT INTO '._DB_PREFIX_.'blocklink_lang VALUES ('.(int)($lastId).', '.(int)($language['id_lang']).', \''.pSQL($_POST['text_'.$language['id_lang']]).'\')'))
|
||||
return false;
|
||||
}
|
||||
else
|
||||
if (!Db::getInstance()->Execute('INSERT INTO '._DB_PREFIX_.'blocklink_lang VALUES ('.(int)($lastId).', '.(int)($language['id_lang']).', \''.pSQL($_POST['text_'.$defaultLanguage]).'\')'))
|
||||
return false;
|
||||
return true;
|
||||
}
|
||||
|
||||
public function updateLink()
|
||||
{
|
||||
/* Url registration */
|
||||
if (!Db::getInstance()->Execute('UPDATE '._DB_PREFIX_.'blocklink SET `url`=\''.pSQL($_POST['url']).'\', `new_window`='.(isset($_POST['newWindow']) ? 1 : 0).' WHERE `id_blocklink`='.(int)($_POST['id'])))
|
||||
return false;
|
||||
/* Multilingual text */
|
||||
$languages = Language::getLanguages();
|
||||
$defaultLanguage = (int)(Configuration::get('PS_LANG_DEFAULT'));
|
||||
if (!$languages)
|
||||
/* Url registration */
|
||||
if (!Db::getInstance()->Execute('UPDATE '._DB_PREFIX_.'blocklink SET `url`=\''.pSQL($_POST['url']).'\', `new_window`='.(isset($_POST['newWindow']) ? 1 : 0).' WHERE `id_blocklink`='.(int)($_POST['id'])))
|
||||
return false;
|
||||
/* Multilingual text */
|
||||
$languages = Language::getLanguages();
|
||||
$defaultLanguage = (int)(Configuration::get('PS_LANG_DEFAULT'));
|
||||
if (!$languages)
|
||||
return false;
|
||||
if (!Db::getInstance()->Execute('DELETE FROM '._DB_PREFIX_.'blocklink_lang WHERE `id_blocklink` = '.(int)($_POST['id'])))
|
||||
return false ;
|
||||
foreach ($languages AS $language)
|
||||
if (!empty($_POST['text_'.$language['id_lang']]))
|
||||
foreach ($languages AS $language)
|
||||
if (!empty($_POST['text_'.$language['id_lang']]))
|
||||
{
|
||||
if (!Db::getInstance()->Execute('INSERT INTO '._DB_PREFIX_.'blocklink_lang VALUES ('.(int)($_POST['id']).', '.(int)($language['id_lang']).', \''.pSQL($_POST['text_'.$language['id_lang']]).'\')'))
|
||||
return false;
|
||||
if (!Db::getInstance()->Execute('INSERT INTO '._DB_PREFIX_.'blocklink_lang VALUES ('.(int)($_POST['id']).', '.(int)($language['id_lang']).', \''.pSQL($_POST['text_'.$language['id_lang']]).'\')'))
|
||||
return false;
|
||||
}
|
||||
else
|
||||
else
|
||||
if (!Db::getInstance()->Execute('INSERT INTO '._DB_PREFIX_.'blocklink_lang VALUES ('.(int)($_POST['id']).', '.$language['id_lang'].', \''.pSQL($_POST['text_'.$defaultLanguage]).'\')'))
|
||||
return false;
|
||||
return true;
|
||||
return false;
|
||||
return true;
|
||||
}
|
||||
|
||||
public function deleteLink()
|
||||
{
|
||||
return Db::getInstance()->Execute('DELETE FROM '._DB_PREFIX_.'blocklink WHERE `id_blocklink`='.(int)($_GET['id']));
|
||||
return Db::getInstance()->Execute('DELETE FROM '._DB_PREFIX_.'blocklink WHERE `id_blocklink`='.(int)($_GET['id']));
|
||||
}
|
||||
|
||||
public function updateTitle()
|
||||
@@ -181,92 +181,98 @@ class BlockLink extends Module
|
||||
$result = array();
|
||||
foreach ($languages AS $language)
|
||||
$result[$language['id_lang']] = $_POST['title_'.$language['id_lang']];
|
||||
if (!Configuration::updateValue('PS_BLOCKLINK_TITLE', $result))
|
||||
return false;
|
||||
return Configuration::updateValue('PS_BLOCKLINK_URL', $_POST['title_url']);
|
||||
if (!Configuration::updateValue('PS_BLOCKLINK_TITLE', $result))
|
||||
return false;
|
||||
return Configuration::updateValue('PS_BLOCKLINK_URL', $_POST['title_url']);
|
||||
}
|
||||
|
||||
public function getContent()
|
||||
{
|
||||
$this->_html = '<h2>'.$this->displayName.'</h2>
|
||||
$this->_html = '<h2>'.$this->displayName.'</h2>
|
||||
<script type="text/javascript" src="'.$this->_path.'blocklink.js"></script>';
|
||||
|
||||
/* Add a link */
|
||||
if (isset($_POST['submitLinkAdd']))
|
||||
/* Add a link */
|
||||
if (isset($_POST['submitLinkAdd']))
|
||||
{
|
||||
if (empty($_POST['text_'.Configuration::get('PS_LANG_DEFAULT')]) OR empty($_POST['url']))
|
||||
$this->_html .= $this->displayError($this->l('You must fill in all fields'));
|
||||
elseif (!Validate::isUrl(str_replace('http://', '', $_POST['url'])))
|
||||
$this->_html .= $this->displayError($this->l('Bad URL'));
|
||||
else
|
||||
if ($this->addLink())
|
||||
if (empty($_POST['text_'.Configuration::get('PS_LANG_DEFAULT')]) OR empty($_POST['url']))
|
||||
$this->_html .= $this->displayError($this->l('You must fill in all fields'));
|
||||
elseif (!Validate::isUrl(str_replace('http://', '', $_POST['url'])))
|
||||
$this->_html .= $this->displayError($this->l('Bad URL'));
|
||||
else
|
||||
if ($this->addLink())
|
||||
$this->_html .= $this->displayConfirmation($this->l('The link has been added.'));
|
||||
else
|
||||
$this->_html .= $this->displayError($this->l('An error occurred during link creation.'));
|
||||
else
|
||||
$this->_html .= $this->displayError($this->l('An error occurred during link creation.'));
|
||||
}
|
||||
/* Update a link */
|
||||
elseif (isset($_POST['submitLinkUpdate']))
|
||||
{
|
||||
if (empty($_POST['text_'.Configuration::get('PS_LANG_DEFAULT')]) OR empty($_POST['url']))
|
||||
$this->_html .= $this->displayError($this->l('You must fill in all fields'));
|
||||
elseif (!Validate::isUrl(str_replace('http://', '', $_POST['url'])))
|
||||
$this->_html .= $this->displayError($this->l('Bad URL'));
|
||||
else
|
||||
if (empty($_POST['id']) OR !is_numeric($_POST['id']) OR !$this->updateLink())
|
||||
$this->_html .= $this->displayError($this->l('An error occurred during link updating.'));
|
||||
else
|
||||
$this->_html .= $this->displayConfirmation($this->l('The link has been updated.'));
|
||||
}
|
||||
/* Update the block title */
|
||||
elseif (isset($_POST['submitTitle']))
|
||||
{
|
||||
if (empty($_POST['title_'.Configuration::get('PS_LANG_DEFAULT')]))
|
||||
$this->_html .= $this->displayError($this->l('"title" field cannot be empty.'));
|
||||
elseif (!empty($_POST['title_url']) AND !Validate::isUrl(str_replace('http://', '', $_POST['title_url'])))
|
||||
$this->_html .= $this->displayError($this->l('The \'title\' field is invalid'));
|
||||
elseif (!Validate::isGenericName($_POST['title_'.Configuration::get('PS_LANG_DEFAULT')]))
|
||||
$this->_html .= $this->displayError($this->l('The \'title\' field is invalid'));
|
||||
elseif (!$this->updateTitle())
|
||||
$this->_html .= $this->displayError($this->l('An error occurred during title updating.'));
|
||||
else
|
||||
$this->_html .= $this->displayConfirmation($this->l('The block title has been updated.'));
|
||||
}
|
||||
/* Delete a link*/
|
||||
elseif (isset($_GET['id']))
|
||||
{
|
||||
if (!is_numeric($_GET['id']) OR !$this->deleteLink())
|
||||
$this->_html .= $this->displayError($this->l('An error occurred during link deletion.'));
|
||||
else
|
||||
$this->_html .= $this->displayConfirmation($this->l('The link has been deleted.'));
|
||||
}
|
||||
if (isset($_POST['submitOrderWay']))
|
||||
/* Update a link */
|
||||
elseif (isset($_POST['submitLinkUpdate']))
|
||||
{
|
||||
if (Configuration::updateValue('PS_BLOCKLINK_ORDERWAY', (int)Tools::getValue('orderWay')))
|
||||
|
||||
if (empty($_POST['text_'.Configuration::get('PS_LANG_DEFAULT')]) OR empty($_POST['url']))
|
||||
$this->_html .= $this->displayError($this->l('You must fill in all fields'));
|
||||
elseif (!Validate::isUrl(str_replace('http://', '', $_POST['url'])))
|
||||
$this->_html .= $this->displayError($this->l('Bad URL'));
|
||||
else
|
||||
if (empty($_POST['id']) OR !is_numeric($_POST['id']) OR !$this->updateLink())
|
||||
$this->_html .= $this->displayError($this->l('An error occurred during link updating.'));
|
||||
else
|
||||
$this->_html .= $this->displayConfirmation($this->l('The link has been updated.'));
|
||||
}
|
||||
|
||||
/* Update the block title */
|
||||
elseif (isset($_POST['submitTitle']))
|
||||
{
|
||||
|
||||
if (empty($_POST['title_'.Configuration::get('PS_LANG_DEFAULT')]))
|
||||
$this->_html .= $this->displayError($this->l('"title" field cannot be empty.'));
|
||||
elseif (!empty($_POST['title_url']) AND !Validate::isUrl(str_replace('http://', '', $_POST['title_url'])))
|
||||
$this->_html .= $this->displayError($this->l('The \'title\' field is invalid'));
|
||||
elseif (!Validate::isGenericName($_POST['title_'.Configuration::get('PS_LANG_DEFAULT')]))
|
||||
$this->_html .= $this->displayError($this->l('The \'title\' field is invalid'));
|
||||
elseif (!$this->updateTitle())
|
||||
$this->_html .= $this->displayError($this->l('An error occurred during title updating.'));
|
||||
else
|
||||
$this->_html .= $this->displayConfirmation($this->l('The block title has been updated.'));
|
||||
}
|
||||
|
||||
/* Delete a link*/
|
||||
elseif (isset($_GET['id']))
|
||||
{
|
||||
|
||||
if (!is_numeric($_GET['id']) OR !$this->deleteLink())
|
||||
$this->_html .= $this->displayError($this->l('An error occurred during link deletion.'));
|
||||
else
|
||||
$this->_html .= $this->displayConfirmation($this->l('The link has been deleted.'));
|
||||
}
|
||||
|
||||
if (isset($_POST['submitOrderWay']))
|
||||
{
|
||||
if (Configuration::updateValue('PS_BLOCKLINK_ORDERWAY', (int)(Tools::getValue('orderWay'))))
|
||||
$this->_html .= $this->displayConfirmation($this->l('Sort order updated'));
|
||||
else
|
||||
$this->_html .= $this->displayError($this->l('An error occurred during sort order set-up.'));
|
||||
}
|
||||
|
||||
$this->_displayForm();
|
||||
$this->_list();
|
||||
$this->_displayForm();
|
||||
$this->_list();
|
||||
|
||||
return $this->_html;
|
||||
}
|
||||
return $this->_html;
|
||||
}
|
||||
|
||||
private function _displayForm()
|
||||
{
|
||||
/* Language */
|
||||
$defaultLanguage = (int)(Configuration::get('PS_LANG_DEFAULT'));
|
||||
$defaultLanguage = (int)(Configuration::get('PS_LANG_DEFAULT'));
|
||||
$languages = Language::getLanguages(false);
|
||||
$divLangName = 'text¤title';
|
||||
/* Title */
|
||||
$title_url = Configuration::get('PS_BLOCKLINK_URL');
|
||||
$title_url = Configuration::get('PS_BLOCKLINK_URL');
|
||||
|
||||
$this->_html .= '
|
||||
$this->_html .= '
|
||||
<script type="text/javascript">
|
||||
id_language = Number('.$defaultLanguage.');
|
||||
</script>
|
||||
<fieldset>
|
||||
<fieldset>
|
||||
<legend><img src="'.$this->_path.'add.png" alt="" title="" /> '.$this->l('Add a new link').'</legend>
|
||||
<form method="post" action="'.$_SERVER['REQUEST_URI'].'">
|
||||
<label>'.$this->l('Text:').'</label>
|
||||
@@ -287,7 +293,7 @@ class BlockLink extends Module
|
||||
<div class="margin-form">
|
||||
<input type="hidden" name="id" id="id" value="'.($this->error AND isset($_POST['id']) ? $_POST['id'] : '').'" />
|
||||
<input type="submit" class="button" name="submitLinkAdd" value="'.$this->l('Add this link').'" />
|
||||
<input type="submit" class="button disable" name="submitLinkUpdate" value="'.$this->l('Edit this link').'" disabled="disabled" id="submitLinkUpdate" />
|
||||
<input type="submit" class="button disable" name="submitLinkUpdate" value="'.$this->l('Edit this link').'" id="submitLinkUpdate" />
|
||||
</div>
|
||||
</form>
|
||||
</fieldset>
|
||||
@@ -327,29 +333,29 @@ class BlockLink extends Module
|
||||
|
||||
private function _list()
|
||||
{
|
||||
$links = $this->getLinks();
|
||||
$languages = Language::getLanguages();
|
||||
if ($links)
|
||||
$links = $this->getLinks();
|
||||
$languages = Language::getLanguages();
|
||||
if ($links)
|
||||
{
|
||||
$this->_html .= '
|
||||
$this->_html .= '
|
||||
<script type="text/javascript">
|
||||
var currentUrl = \''.AdminTab::$currentIndex.'&configure='.$this->name.'\';
|
||||
var token=\''.Tools::getValue('token').'\';
|
||||
var links = new Array();';
|
||||
foreach ($links AS $link)
|
||||
foreach ($links AS $link)
|
||||
{
|
||||
$this->_html .= 'links['.$link['id'].'] = new Array(\''.addslashes($link['url']).'\', '.$link['newWindow'];
|
||||
foreach ($languages AS $language)
|
||||
$this->_html .= 'links['.$link['id'].'] = new Array(\''.addslashes($link['url']).'\', '.$link['newWindow'];
|
||||
foreach ($languages AS $language)
|
||||
if (isset($link['text_'.$language['id_lang']]))
|
||||
$this->_html .= ', \''.addslashes($link['text_'.$language['id_lang']]).'\'';
|
||||
else
|
||||
$this->_html .= ', \'\'';
|
||||
$this->_html .= ');';
|
||||
$this->_html .= ');';
|
||||
}
|
||||
$this->_html .= '</script>';
|
||||
$this->_html .= '</script>';
|
||||
}
|
||||
$this->_html .= '
|
||||
<h3 class="blue space">'.$this->l('Link list').'</h3>
|
||||
$this->_html .= '
|
||||
<h3 class="blue space">'.$this->l('Link list').'</h3>
|
||||
<table class="table">
|
||||
<tr>
|
||||
<th>'.$this->l('ID').'</th>
|
||||
@@ -375,9 +381,20 @@ class BlockLink extends Module
|
||||
<img src="../img/admin/delete.gif" alt="" title="" onclick="linkDeletion('.$link['id'].')" style="cursor: pointer" />
|
||||
</td>
|
||||
</tr>';
|
||||
$i = 0;
|
||||
$nb = count($languages);
|
||||
$idLng = 0;
|
||||
while($i < $nb)
|
||||
{
|
||||
if ($languages[$i]['id_lang'] == (int)Configuration::get('PS_LANG_DEFAULT'))
|
||||
{
|
||||
$idLng = $i;
|
||||
}
|
||||
$i++;
|
||||
}
|
||||
$this->_html .= '
|
||||
</table>
|
||||
<input type="hidden" id="languageFirst" value="'.$languages[0]['id_lang'].'" />
|
||||
<input type="hidden" id="languageNb" value="'.sizeof($languages).'" />';
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -25,7 +25,7 @@
|
||||
* International Registered Trademark & Property of PrestaShop SA
|
||||
*/
|
||||
|
||||
if (!defined('_CAN_LOAD_FILES_'))
|
||||
if (!defined('_PS_VERSION_'))
|
||||
exit;
|
||||
|
||||
class BlockManufacturer extends Module
|
||||
|
||||
@@ -25,7 +25,7 @@
|
||||
* International Registered Trademark & Property of PrestaShop SA
|
||||
*/
|
||||
|
||||
if (!defined('_CAN_LOAD_FILES_'))
|
||||
if (!defined('_PS_VERSION_'))
|
||||
exit;
|
||||
|
||||
class BlockMyAccount extends Module
|
||||
|
||||
@@ -25,7 +25,7 @@
|
||||
* International Registered Trademark & Property of PrestaShop SA
|
||||
*/
|
||||
|
||||
if (!defined('_CAN_LOAD_FILES_'))
|
||||
if (!defined('_PS_VERSION_'))
|
||||
exit;
|
||||
|
||||
class BlockNewProducts extends Module
|
||||
|
||||
@@ -25,7 +25,7 @@
|
||||
* International Registered Trademark & Property of PrestaShop SA
|
||||
*/
|
||||
|
||||
if (!defined('_CAN_LOAD_FILES_'))
|
||||
if (!defined('_PS_VERSION_'))
|
||||
exit;
|
||||
|
||||
class Blocknewsletter extends Module
|
||||
|
||||
@@ -25,7 +25,7 @@
|
||||
* International Registered Trademark & Property of PrestaShop SA
|
||||
*/
|
||||
|
||||
if (!defined('_CAN_LOAD_FILES_'))
|
||||
if (!defined('_PS_VERSION_'))
|
||||
exit;
|
||||
|
||||
class BlockPaymentLogo extends Module
|
||||
|
||||
@@ -25,7 +25,7 @@
|
||||
* International Registered Trademark & Property of PrestaShop SA
|
||||
*/
|
||||
|
||||
if (!defined('_CAN_LOAD_FILES_'))
|
||||
if (!defined('_PS_VERSION_'))
|
||||
exit;
|
||||
|
||||
class BlockPermanentLinks extends Module
|
||||
|
||||
@@ -25,7 +25,7 @@
|
||||
* International Registered Trademark & Property of PrestaShop SA
|
||||
*/
|
||||
|
||||
if (!defined('_CAN_LOAD_FILES_'))
|
||||
if (!defined('_PS_VERSION_'))
|
||||
exit;
|
||||
|
||||
include_once(_PS_CLASS_DIR_.'../tools/pear/PEAR.php');
|
||||
|
||||
@@ -25,7 +25,7 @@
|
||||
* International Registered Trademark & Property of PrestaShop SA
|
||||
*/
|
||||
|
||||
if (!defined('_CAN_LOAD_FILES_'))
|
||||
if (!defined('_PS_VERSION_'))
|
||||
exit;
|
||||
|
||||
class BlockSearch extends Module
|
||||
|
||||
@@ -24,7 +24,8 @@
|
||||
* @license http://opensource.org/licenses/afl-3.0.php Academic Free License (AFL 3.0)
|
||||
* International Registered Trademark & Property of PrestaShop SA
|
||||
*/
|
||||
if (!defined('_CAN_LOAD_FILES_'))
|
||||
|
||||
if (!defined('_PS_VERSION_'))
|
||||
exit;
|
||||
|
||||
class BlockSpecials extends Module
|
||||
|
||||
@@ -25,7 +25,7 @@
|
||||
* International Registered Trademark & Property of PrestaShop SA
|
||||
*/
|
||||
|
||||
if (!defined('_CAN_LOAD_FILES_'))
|
||||
if (!defined('_PS_VERSION_'))
|
||||
exit;
|
||||
|
||||
class BlockStore extends Module
|
||||
|
||||
@@ -25,7 +25,7 @@
|
||||
* International Registered Trademark & Property of PrestaShop SA
|
||||
*/
|
||||
|
||||
if (!defined('_CAN_LOAD_FILES_'))
|
||||
if (!defined('_PS_VERSION_'))
|
||||
exit;
|
||||
|
||||
class BlockSupplier extends Module
|
||||
|
||||
@@ -25,7 +25,7 @@
|
||||
* International Registered Trademark & Property of PrestaShop SA
|
||||
*/
|
||||
|
||||
if (!defined('_CAN_LOAD_FILES_'))
|
||||
if (!defined('_PS_VERSION_'))
|
||||
exit;
|
||||
|
||||
define('BLOCKTAGS_MAX_LEVEL', 3);
|
||||
|
||||
@@ -25,7 +25,7 @@
|
||||
* International Registered Trademark & Property of PrestaShop SA
|
||||
*/
|
||||
|
||||
if (!defined('_CAN_LOAD_FILES_'))
|
||||
if (!defined('_PS_VERSION_'))
|
||||
exit;
|
||||
|
||||
class BlockUserInfo extends Module
|
||||
|
||||
@@ -25,7 +25,7 @@
|
||||
* International Registered Trademark & Property of PrestaShop SA
|
||||
*/
|
||||
|
||||
if (!defined('_CAN_LOAD_FILES_'))
|
||||
if (!defined('_PS_VERSION_'))
|
||||
exit;
|
||||
|
||||
class BlockViewed extends Module
|
||||
|
||||
@@ -25,7 +25,7 @@
|
||||
* International Registered Trademark & Property of PrestaShop SA
|
||||
*/
|
||||
|
||||
if (!defined('_CAN_LOAD_FILES_'))
|
||||
if (!defined('_PS_VERSION_'))
|
||||
exit;
|
||||
|
||||
class WishList extends ObjectModel
|
||||
|
||||
@@ -25,7 +25,7 @@
|
||||
* International Registered Trademark & Property of PrestaShop SA
|
||||
*/
|
||||
|
||||
if (!defined('_CAN_LOAD_FILES_'))
|
||||
if (!defined('_PS_VERSION_'))
|
||||
exit;
|
||||
|
||||
class BlockWishList extends Module
|
||||
|
||||
@@ -24,7 +24,8 @@
|
||||
* @license http://opensource.org/licenses/afl-3.0.php Academic Free License (AFL 3.0)
|
||||
* International Registered Trademark & Property of PrestaShop SA
|
||||
*/
|
||||
if (!defined('_CAN_LOAD_FILES_'))
|
||||
|
||||
if (!defined('_PS_VERSION_'))
|
||||
exit;
|
||||
|
||||
class CanadaPost extends CarrierModule
|
||||
|
||||
@@ -25,7 +25,7 @@
|
||||
* International Registered Trademark & Property of PrestaShop SA
|
||||
*/
|
||||
|
||||
if (!defined('_CAN_LOAD_FILES_'))
|
||||
if (!defined('_PS_VERSION_'))
|
||||
exit;
|
||||
|
||||
class CarrierCompare extends Module
|
||||
|
||||
@@ -25,7 +25,7 @@
|
||||
* International Registered Trademark & Property of PrestaShop SA
|
||||
*/
|
||||
|
||||
if (!defined('_CAN_LOAD_FILES_'))
|
||||
if (!defined('_PS_VERSION_'))
|
||||
exit;
|
||||
|
||||
class CashOnDelivery extends PaymentModule
|
||||
|
||||
@@ -24,7 +24,8 @@
|
||||
* @license http://opensource.org/licenses/afl-3.0.php Academic Free License (AFL 3.0)
|
||||
* International Registered Trademark & Property of PrestaShop SA
|
||||
*/
|
||||
if (!defined('_CAN_LOAD_FILES_'))
|
||||
|
||||
if (!defined('_PS_VERSION_'))
|
||||
exit;
|
||||
|
||||
if (!in_array('PrepaidServices', get_declared_classes())) include_once(_PS_MODULE_DIR_.'cashticket/PrepaidServices.php');
|
||||
|
||||
@@ -25,7 +25,7 @@
|
||||
* International Registered Trademark & Property of PrestaShop SA
|
||||
*/
|
||||
|
||||
if (!defined('_CAN_LOAD_FILES_'))
|
||||
if (!defined('_PS_VERSION_'))
|
||||
exit;
|
||||
|
||||
class Cheque extends PaymentModule
|
||||
|
||||
@@ -25,7 +25,7 @@
|
||||
* International Registered Trademark & Property of PrestaShop SA
|
||||
*/
|
||||
|
||||
if (!defined('_CAN_LOAD_FILES_'))
|
||||
if (!defined('_PS_VERSION_'))
|
||||
exit;
|
||||
|
||||
class Criteo extends Module
|
||||
|
||||
@@ -25,7 +25,7 @@
|
||||
* International Registered Trademark & Property of PrestaShop SA
|
||||
*/
|
||||
|
||||
if (!defined('_CAN_LOAD_FILES_'))
|
||||
if (!defined('_PS_VERSION_'))
|
||||
exit;
|
||||
|
||||
class CrossSelling extends Module
|
||||
@@ -146,4 +146,4 @@ class CrossSelling extends Module
|
||||
}
|
||||
return $this->display(__FILE__, 'crossselling.tpl');
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -24,7 +24,8 @@
|
||||
* @license http://opensource.org/licenses/afl-3.0.php Academic Free License (AFL 3.0)
|
||||
* International Registered Trademark & Property of PrestaShop SA
|
||||
*/
|
||||
if (!defined('_CAN_LOAD_FILES_'))
|
||||
|
||||
if (!defined('_PS_VERSION_'))
|
||||
exit;
|
||||
|
||||
class DateOfDelivery extends Module
|
||||
@@ -515,4 +516,4 @@ class DateOfDelivery extends Module
|
||||
$date_maximal_string
|
||||
);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -1,6 +1,31 @@
|
||||
<?php
|
||||
/*
|
||||
* 2007-2011 PrestaShop
|
||||
*
|
||||
* NOTICE OF LICENSE
|
||||
*
|
||||
* This source file is subject to the Academic Free License (AFL 3.0)
|
||||
* that is bundled with this package in the file LICENSE.txt.
|
||||
* It is also available through the world-wide-web at this URL:
|
||||
* http://opensource.org/licenses/afl-3.0.php
|
||||
* If you did not receive a copy of the license and are unable to
|
||||
* obtain it through the world-wide-web, please send an email
|
||||
* to license@prestashop.com so we can send you a copy immediately.
|
||||
*
|
||||
* DISCLAIMER
|
||||
*
|
||||
* Do not edit or add to this file if you wish to upgrade PrestaShop to newer
|
||||
* versions in the future. If you wish to customize PrestaShop for your
|
||||
* needs please refer to http://www.prestashop.com for more information.
|
||||
*
|
||||
* @author PrestaShop SA <contact@prestashop.com>
|
||||
* @copyright 2007-2011 PrestaShop SA
|
||||
* @version Release: $Revision$
|
||||
* @license http://opensource.org/licenses/afl-3.0.php Academic Free License (AFL 3.0)
|
||||
* International Registered Trademark & Property of PrestaShop SA
|
||||
*/
|
||||
|
||||
if (!defined('_CAN_LOAD_FILES_'))
|
||||
if (!defined('_PS_VERSION_'))
|
||||
exit;
|
||||
|
||||
require_once(_PS_MODULE_DIR_ . "dejala/dejalaconfig.php");
|
||||
|
||||
@@ -5,8 +5,10 @@
|
||||
* DejalaCart class, dejalacart.php
|
||||
* Manage cart information related to dejala.fr carrier
|
||||
**/
|
||||
if (!defined('_CAN_LOAD_FILES_'))
|
||||
|
||||
if (!defined('_PS_VERSION_'))
|
||||
exit;
|
||||
|
||||
class DejalaCart extends ObjectModel
|
||||
{
|
||||
public $id;
|
||||
|
||||
@@ -24,7 +24,8 @@
|
||||
* @license http://opensource.org/licenses/afl-3.0.php Academic Free License (AFL 3.0)
|
||||
* International Registered Trademark & Property of PrestaShop SA
|
||||
*/
|
||||
if (!defined('_CAN_LOAD_FILES_'))
|
||||
|
||||
if (!defined('_PS_VERSION_'))
|
||||
exit;
|
||||
|
||||
class dibs extends PaymentModule
|
||||
|
||||
@@ -89,7 +89,7 @@ class eBayRequest
|
||||
|
||||
$this->apiUrl = 'https://api.ebay.com/ws/api.dll';
|
||||
$this->apiCall = $apiCall;
|
||||
$this->compatibilityLevel = 719;
|
||||
$this->compatibilityLevel = 741;
|
||||
|
||||
$this->runame = 'Prestashop-Prestash-70a5-4-pepwa';
|
||||
|
||||
@@ -355,7 +355,7 @@ class eBayRequest
|
||||
|
||||
|
||||
/******************************************************************/
|
||||
/** Add Product Methods *******************************************/
|
||||
/** Add / Update / End Product Methods ****************************/
|
||||
/******************************************************************/
|
||||
|
||||
|
||||
@@ -374,7 +374,7 @@ class eBayRequest
|
||||
$requestXml .= ' <ErrorLanguage>fr_FR</ErrorLanguage>'."\n";
|
||||
$requestXml .= ' <WarningLevel>High</WarningLevel>'."\n";
|
||||
$requestXml .= ' <Item>'."\n";
|
||||
$requestXml .= ' <SKU>prestashop-'.$datas['id_product'].(isset($datas['reference']) ? '-'.$datas['reference'] : '').'</SKU>';
|
||||
$requestXml .= ' <SKU>prestashop-'.$datas['id_product'].'</SKU>';
|
||||
$requestXml .= ' <Title>'.substr($datas['name'], 0, 55).'</Title>'."\n";
|
||||
if (isset($datas['pictures']))
|
||||
{
|
||||
@@ -503,7 +503,7 @@ class eBayRequest
|
||||
$requestXml .= ' <WarningLevel>High</WarningLevel>'."\n";
|
||||
$requestXml .= ' <Item>'."\n";
|
||||
$requestXml .= ' <ItemID>'.$datas['itemID'].'</ItemID>'."\n";
|
||||
$requestXml .= ' <SKU>prestashop-'.$datas['id_product'].(isset($datas['reference']) ? '-'.$datas['reference'] : '').'</SKU>';
|
||||
$requestXml .= ' <SKU>prestashop-'.$datas['id_product'].'</SKU>';
|
||||
$requestXml .= ' <Quantity>'.$datas['quantity'].'</Quantity>'."\n";
|
||||
$requestXml .= ' <StartPrice>'.$datas['price'].'</StartPrice>'."\n";
|
||||
if (Configuration::get('EBAY_SYNC_OPTION_RESYNC') != 1)
|
||||
@@ -579,6 +579,86 @@ class eBayRequest
|
||||
|
||||
|
||||
|
||||
function endFixedPriceItem($datas = array())
|
||||
{
|
||||
// Check data
|
||||
if (!$datas)
|
||||
return false;
|
||||
|
||||
// Set Api Call
|
||||
$this->apiCall = 'EndFixedPriceItem';
|
||||
|
||||
// Build the request Xml string
|
||||
$requestXml = '<?xml version="1.0" encoding="utf-8"?>'."\n";
|
||||
$requestXml .= '<EndFixedPriceItemRequest xmlns="urn:ebay:apis:eBLBaseComponents">'."\n";
|
||||
$requestXml .= ' <ErrorLanguage>fr_FR</ErrorLanguage>'."\n";
|
||||
$requestXml .= ' <WarningLevel>High</WarningLevel>'."\n";
|
||||
$requestXml .= ' <ItemID>'.$datas['itemID'].'</ItemID>'."\n";
|
||||
$requestXml .= ' <SKU>prestashop-'.$datas['id_product'].'</SKU>';
|
||||
$requestXml .= ' <EndingReason>NotAvailable</EndingReason>'."\n";
|
||||
$requestXml .= ' <RequesterCredentials>'."\n";
|
||||
$requestXml .= ' <eBayAuthToken>'.Configuration::get('EBAY_API_TOKEN').'</eBayAuthToken>'."\n";
|
||||
$requestXml .= ' </RequesterCredentials>'."\n";
|
||||
$requestXml .= ' <WarningLevel>High</WarningLevel>'."\n";
|
||||
$requestXml .= '</EndFixedPriceItemRequest>'."\n";
|
||||
|
||||
|
||||
// Send the request and get response
|
||||
$responseXml = $this->makeRequest($requestXml);
|
||||
if (stristr($responseXml, 'HTTP 404') || $responseXml == '')
|
||||
{
|
||||
$this->error = 'Error sending '.$this->apiCall.' request';
|
||||
return false;
|
||||
}
|
||||
|
||||
// Loading XML tree in array
|
||||
$this->response = simplexml_load_string($responseXml);
|
||||
|
||||
|
||||
// Checking Errors
|
||||
$this->error = '';
|
||||
$this->errorCode = '';
|
||||
if (isset($this->response->Errors) && isset($this->response->Ack) && (string)$this->response->Ack != 'Success' && (string)$this->response->Ack != 'Warning')
|
||||
foreach ($this->response->Errors as $e)
|
||||
{
|
||||
// if product no longer on eBay, we log the error code
|
||||
if ((int)$e->ErrorCode == 291)
|
||||
$this->errorCode = (int)$e->ErrorCode;
|
||||
|
||||
// We log error message
|
||||
if ($e->SeverityCode == 'Error')
|
||||
{
|
||||
if ($this->error != '')
|
||||
$this->error .= '<br />';
|
||||
$this->error .= (string)$e->LongMessage;
|
||||
if (isset($e->ErrorParameters->Value))
|
||||
$this->error .= '<br />'.(string)$e->ErrorParameters->Value;
|
||||
}
|
||||
}
|
||||
|
||||
// Checking Success
|
||||
$this->itemID = 0;
|
||||
if (isset($this->response->Ack) && ((string)$this->response->Ack == 'Success' || (string)$this->response->Ack == 'Warning'))
|
||||
{
|
||||
$this->fees = 0;
|
||||
$this->itemID = (string)$this->response->ItemID;
|
||||
if (isset($this->response->Fees->Fee))
|
||||
foreach ($this->response->Fees->Fee as $f)
|
||||
$this->fees += (float)$f->Fee;
|
||||
}
|
||||
elseif ($this->error == '')
|
||||
$this->error = 'Sorry, technical problem, try again later.';
|
||||
|
||||
if (!empty($this->error))
|
||||
return false;
|
||||
|
||||
return true;
|
||||
}
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
@@ -653,7 +733,7 @@ class eBayRequest
|
||||
foreach ($datas['variations'] as $key => $variation)
|
||||
{
|
||||
$requestXml .= ' <Variation>'."\n";
|
||||
$requestXml .= ' <SKU>prestashop-'.$key.(isset($variation['reference']) ? '-'.$variation['reference'] : '').'</SKU>'."\n";
|
||||
$requestXml .= ' <SKU>prestashop-'.$key.'</SKU>'."\n";
|
||||
$requestXml .= ' <StartPrice>'.$variation['price'].'</StartPrice>'."\n";
|
||||
$requestXml .= ' <Quantity>'.$variation['quantity'].'</Quantity>'."\n";
|
||||
$requestXml .= ' <VariationSpecifics>'."\n";
|
||||
@@ -929,6 +1009,18 @@ class eBayRequest
|
||||
}
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
/******************************************************************/
|
||||
/** Order Methods *************************************************/
|
||||
/******************************************************************/
|
||||
@@ -1068,6 +1160,9 @@ class eBayRequest
|
||||
'shippingServiceCost' => (string)$order->ShippingServiceSelected->ShippingServiceCost,
|
||||
'email' => (string)$order->TransactionArray->Transaction[0]->Buyer->Email,
|
||||
'product_list' => $itemList,
|
||||
'payment_method' => (string)$order->CheckoutStatus->PaymentMethod,
|
||||
'id_order_seller' => (string)$order->ShippingDetails->SellingManagerSalesRecordNumber,
|
||||
'date_add' => substr((string)$order->CreatedTime, 0, 10).' '.substr((string)$order->CreatedTime, 11, 8),
|
||||
//'object' => $order
|
||||
);
|
||||
}
|
||||
|
||||
+33
-3
@@ -25,6 +25,9 @@
|
||||
* International Registered Trademark & Property of PrestaShop SA
|
||||
*/
|
||||
|
||||
// Security
|
||||
if (!defined('_PS_VERSION_'))
|
||||
exit;
|
||||
|
||||
// Loading eBay Class Request
|
||||
if (file_exists(dirname(__FILE__).'/eBayRequest.php'))
|
||||
@@ -420,9 +423,12 @@ class Ebay extends Module
|
||||
|
||||
// Validate order
|
||||
$paiement = new eBayPayment();
|
||||
$paiement->validateOrder(intval($cartAdd->id), Configuration::get('PS_OS_PAYMENT'), floatval($cartAdd->getOrderTotal(true, 3)), 'Paypal eBay', NULL, array(), intval($cartAdd->id_currency));
|
||||
$paiement->validateOrder(intval($cartAdd->id), Configuration::get('PS_OS_PAYMENT'), floatval($cartAdd->getOrderTotal(true, 3)), 'eBay '.$order['payment_method'].' '.$order['id_order_seller'], NULL, array(), intval($cartAdd->id_currency));
|
||||
$id_order = $paiement->currentOrder;
|
||||
|
||||
// Fix on date
|
||||
Db::getInstance()->autoExecute(_DB_PREFIX_.'orders', array('date_add' => pSQL($order['date_add'])), 'UPDATE', '`id_order` = '.(int)$id_order);
|
||||
|
||||
// Fix on sending e-mail
|
||||
Db::getInstance()->autoExecute(_DB_PREFIX_.'customer', array('email' => pSQL($order['email'])), 'UPDATE', '`id_customer` = '.(int)$id_customer);
|
||||
|
||||
@@ -1514,8 +1520,19 @@ class Ebay extends Module
|
||||
$itemID = Db::getInstance()->getValue('SELECT `id_product_ref` FROM `'._DB_PREFIX_.'ebay_product` WHERE `id_product` = '.(int)$product->id.' AND `id_attribute` = '.(int)$datasTmp['id_attribute']);
|
||||
if ($itemID)
|
||||
{
|
||||
// Update
|
||||
// Get Item ID
|
||||
$datasTmp['itemID'] = $itemID;
|
||||
|
||||
// Delete or Update
|
||||
if ($datasTmp['quantity'] < 1)
|
||||
{
|
||||
// Delete
|
||||
if ($ebay->endFixedPriceItem($datasTmp))
|
||||
Db::getInstance()->Execute('DELETE FROM `'._DB_PREFIX_.'ebay_product` WHERE `id_product_ref` = \''.pSQL($datasTmp['itemID']).'\'');
|
||||
}
|
||||
else
|
||||
{
|
||||
// Update
|
||||
if ($ebay->reviseFixedPriceItem($datasTmp))
|
||||
Db::getInstance()->autoExecute(_DB_PREFIX_.'ebay_product', array('date_upd' => pSQL($date)), 'UPDATE', '`id_product_ref` = '.(int)$itemID);
|
||||
|
||||
@@ -1529,6 +1546,7 @@ class Ebay extends Module
|
||||
Db::getInstance()->autoExecute(_DB_PREFIX_.'ebay_product', array('id_country' => 8, 'id_product' => (int)$product->id, 'id_attribute' => (int)$datasTmp['id_attribute'], 'id_product_ref' => pSQL($ebay->itemID), 'date_add' => pSQL($date), 'date_upd' => pSQL($date)), 'INSERT');
|
||||
}
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
// Add
|
||||
@@ -1562,8 +1580,19 @@ class Ebay extends Module
|
||||
|
||||
if ($itemID)
|
||||
{
|
||||
// Update
|
||||
// Get Item ID
|
||||
$datas['itemID'] = $itemID;
|
||||
|
||||
// Delete or Update
|
||||
if ($datas['quantity'] < 1)
|
||||
{
|
||||
// Delete
|
||||
if ($ebay->endFixedPriceItem($datas))
|
||||
Db::getInstance()->Execute('DELETE FROM `'._DB_PREFIX_.'ebay_product` WHERE `id_product_ref` = \''.pSQL($datas['itemID']).'\'');
|
||||
}
|
||||
else
|
||||
{
|
||||
// Update
|
||||
if ($ebay->reviseFixedPriceItem($datas))
|
||||
Db::getInstance()->autoExecute(_DB_PREFIX_.'ebay_product', array('date_upd' => pSQL($date)), 'UPDATE', '`id_product_ref` = '.(int)$itemID);
|
||||
|
||||
@@ -1577,6 +1606,7 @@ class Ebay extends Module
|
||||
Db::getInstance()->autoExecute(_DB_PREFIX_.'ebay_product', array('id_country' => 8, 'id_product' => (int)$product->id, 'id_attribute' => 0, 'id_product_ref' => pSQL($ebay->itemID), 'date_add' => pSQL($date), 'date_upd' => pSQL($date)), 'INSERT');
|
||||
}
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
// Add
|
||||
|
||||
@@ -25,7 +25,7 @@
|
||||
* International Registered Trademark & Property of PrestaShop SA
|
||||
*/
|
||||
|
||||
if (!defined('_CAN_LOAD_FILES_'))
|
||||
if (!defined('_PS_VERSION_'))
|
||||
exit;
|
||||
|
||||
class Editorial extends Module
|
||||
|
||||
@@ -24,7 +24,8 @@
|
||||
* @license http://opensource.org/licenses/afl-3.0.php Academic Free License (AFL 3.0)
|
||||
* International Registered Trademark & Property of PrestaShop SA
|
||||
*/
|
||||
if (!defined('_CAN_LOAD_FILES_'))
|
||||
|
||||
if (!defined('_PS_VERSION_'))
|
||||
exit;
|
||||
|
||||
class Ekomi extends Module
|
||||
|
||||
@@ -24,7 +24,8 @@
|
||||
* @license http://opensource.org/licenses/afl-3.0.php Academic Free License (AFL 3.0)
|
||||
* International Registered Trademark & Property of PrestaShop SA
|
||||
*/
|
||||
if (!defined('_CAN_LOAD_FILES_'))
|
||||
|
||||
if (!defined('_PS_VERSION_'))
|
||||
exit;
|
||||
|
||||
class Envoimoinscher extends Module
|
||||
|
||||
@@ -24,7 +24,8 @@
|
||||
* @license http://opensource.org/licenses/afl-3.0.php Academic Free License (AFL 3.0)
|
||||
* International Registered Trademark & Property of PrestaShop SA
|
||||
*/
|
||||
if (!defined('_CAN_LOAD_FILES_'))
|
||||
|
||||
if (!defined('_PS_VERSION_'))
|
||||
exit;
|
||||
|
||||
class FedexCarrier extends CarrierModule
|
||||
|
||||
@@ -25,7 +25,7 @@
|
||||
* International Registered Trademark & Property of PrestaShop SA
|
||||
*/
|
||||
|
||||
if (!defined('_CAN_LOAD_FILES_'))
|
||||
if (!defined('_PS_VERSION_'))
|
||||
exit;
|
||||
|
||||
class Feeder extends Module
|
||||
|
||||
@@ -24,7 +24,8 @@
|
||||
* @license http://opensource.org/licenses/afl-3.0.php Academic Free License (AFL 3.0)
|
||||
* International Registered Trademark & Property of PrestaShop SA
|
||||
*/
|
||||
if (!defined('_CAN_LOAD_FILES_'))
|
||||
|
||||
if (!defined('_PS_VERSION_'))
|
||||
exit;
|
||||
|
||||
if ((basename(__FILE__) == 'fianetfraud.php'))
|
||||
|
||||
@@ -24,7 +24,8 @@
|
||||
* @license http://opensource.org/licenses/afl-3.0.php Academic Free License (AFL 3.0)
|
||||
* International Registered Trademark & Property of PrestaShop SA
|
||||
*/
|
||||
if (!defined('_CAN_LOAD_FILES_'))
|
||||
|
||||
if (!defined('_PS_VERSION_'))
|
||||
exit;
|
||||
|
||||
class FianetSceau extends Module
|
||||
|
||||
@@ -25,7 +25,7 @@
|
||||
* International Registered Trademark & Property of PrestaShop SA
|
||||
*/
|
||||
|
||||
if (!defined('_CAN_LOAD_FILES_'))
|
||||
if (!defined('_PS_VERSION_'))
|
||||
exit;
|
||||
|
||||
class Followup extends Module
|
||||
|
||||
@@ -25,7 +25,7 @@
|
||||
* International Registered Trademark & Property of PrestaShop SA
|
||||
*/
|
||||
|
||||
if (!defined('_CAN_LOAD_FILES_'))
|
||||
if (!defined('_PS_VERSION_'))
|
||||
exit;
|
||||
|
||||
class GAdsense extends Module
|
||||
|
||||
@@ -1,6 +1,31 @@
|
||||
<?php
|
||||
/*
|
||||
* 2007-2011 PrestaShop
|
||||
*
|
||||
* NOTICE OF LICENSE
|
||||
*
|
||||
* This source file is subject to the Academic Free License (AFL 3.0)
|
||||
* that is bundled with this package in the file LICENSE.txt.
|
||||
* It is also available through the world-wide-web at this URL:
|
||||
* http://opensource.org/licenses/afl-3.0.php
|
||||
* If you did not receive a copy of the license and are unable to
|
||||
* obtain it through the world-wide-web, please send an email
|
||||
* to license@prestashop.com so we can send you a copy immediately.
|
||||
*
|
||||
* DISCLAIMER
|
||||
*
|
||||
* Do not edit or add to this file if you wish to upgrade PrestaShop to newer
|
||||
* versions in the future. If you wish to customize PrestaShop for your
|
||||
* needs please refer to http://www.prestashop.com for more information.
|
||||
*
|
||||
* @author PrestaShop SA <contact@prestashop.com>
|
||||
* @copyright 2007-2011 PrestaShop SA
|
||||
* @version Release: $Revision$
|
||||
* @license http://opensource.org/licenses/afl-3.0.php Academic Free License (AFL 3.0)
|
||||
* International Registered Trademark & Property of PrestaShop SA
|
||||
*/
|
||||
|
||||
if (!defined('_CAN_LOAD_FILES_'))
|
||||
if (!defined('_PS_VERSION_'))
|
||||
exit;
|
||||
|
||||
class GAnalytics extends Module
|
||||
|
||||
@@ -25,7 +25,7 @@
|
||||
* International Registered Trademark & Property of PrestaShop SA
|
||||
*/
|
||||
|
||||
if (!defined('_CAN_LOAD_FILES_'))
|
||||
if (!defined('_PS_VERSION_'))
|
||||
exit;
|
||||
|
||||
class GCheckout extends PaymentModule
|
||||
|
||||
@@ -25,7 +25,7 @@
|
||||
* International Registered Trademark & Property of PrestaShop SA
|
||||
*/
|
||||
|
||||
if (!defined('_CAN_LOAD_FILES_'))
|
||||
if (!defined('_PS_VERSION_'))
|
||||
exit;
|
||||
|
||||
class GraphArtichow extends ModuleGraphEngine
|
||||
|
||||
@@ -25,7 +25,7 @@
|
||||
* International Registered Trademark & Property of PrestaShop SA
|
||||
*/
|
||||
|
||||
if (!defined('_CAN_LOAD_FILES_'))
|
||||
if (!defined('_PS_VERSION_'))
|
||||
exit;
|
||||
|
||||
class GraphGoogleChart extends ModuleGraphEngine
|
||||
|
||||
@@ -25,7 +25,7 @@
|
||||
* International Registered Trademark & Property of PrestaShop SA
|
||||
*/
|
||||
|
||||
if (!defined('_CAN_LOAD_FILES_'))
|
||||
if (!defined('_PS_VERSION_'))
|
||||
exit;
|
||||
|
||||
class GraphVisifire extends ModuleGraphEngine
|
||||
|
||||
@@ -35,7 +35,7 @@
|
||||
* @version 1.4
|
||||
*/
|
||||
|
||||
if (!defined('_CAN_LOAD_FILES_'))
|
||||
if (!defined('_PS_VERSION_'))
|
||||
exit;
|
||||
|
||||
class GraphXmlSwfCharts extends ModuleGraphEngine
|
||||
|
||||
@@ -25,7 +25,7 @@
|
||||
* International Registered Trademark & Property of PrestaShop SA
|
||||
*/
|
||||
|
||||
if (!defined('_CAN_LOAD_FILES_'))
|
||||
if (!defined('_PS_VERSION_'))
|
||||
exit;
|
||||
|
||||
class GridHtml extends ModuleGridEngine
|
||||
|
||||
@@ -25,7 +25,7 @@
|
||||
* International Registered Trademark & Property of PrestaShop SA
|
||||
*/
|
||||
|
||||
if (!defined('_CAN_LOAD_FILES_'))
|
||||
if (!defined('_PS_VERSION_'))
|
||||
exit;
|
||||
|
||||
class Gsitemap extends Module
|
||||
|
||||
@@ -25,7 +25,7 @@
|
||||
* International Registered Trademark & Property of PrestaShop SA
|
||||
*/
|
||||
|
||||
if (!defined('_CAN_LOAD_FILES_'))
|
||||
if (!defined('_PS_VERSION_'))
|
||||
exit;
|
||||
|
||||
class Hipay extends PaymentModule
|
||||
|
||||
@@ -25,7 +25,7 @@
|
||||
* International Registered Trademark & Property of PrestaShop SA
|
||||
*/
|
||||
|
||||
if (!defined('_CAN_LOAD_FILES_'))
|
||||
if (!defined('_PS_VERSION_'))
|
||||
exit;
|
||||
|
||||
class HomeFeatured extends Module
|
||||
|
||||
@@ -24,7 +24,8 @@
|
||||
* @license http://opensource.org/licenses/afl-3.0.php Academic Free License (AFL 3.0)
|
||||
* International Registered Trademark & Property of PrestaShop SA
|
||||
*/
|
||||
if (!defined('_CAN_LOAD_FILES_'))
|
||||
|
||||
if (!defined('_PS_VERSION_'))
|
||||
exit;
|
||||
|
||||
class iAdvize extends Module
|
||||
@@ -156,4 +157,4 @@ class iAdvize extends Module
|
||||
</script>
|
||||
<!-- /End - iAdvize - Live chat -->'."\n";
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -1,5 +1,31 @@
|
||||
<?php
|
||||
if (!defined('_CAN_LOAD_FILES_'))
|
||||
/*
|
||||
* 2007-2011 PrestaShop
|
||||
*
|
||||
* NOTICE OF LICENSE
|
||||
*
|
||||
* This source file is subject to the Academic Free License (AFL 3.0)
|
||||
* that is bundled with this package in the file LICENSE.txt.
|
||||
* It is also available through the world-wide-web at this URL:
|
||||
* http://opensource.org/licenses/afl-3.0.php
|
||||
* If you did not receive a copy of the license and are unable to
|
||||
* obtain it through the world-wide-web, please send an email
|
||||
* to license@prestashop.com so we can send you a copy immediately.
|
||||
*
|
||||
* DISCLAIMER
|
||||
*
|
||||
* Do not edit or add to this file if you wish to upgrade PrestaShop to newer
|
||||
* versions in the future. If you wish to customize PrestaShop for your
|
||||
* needs please refer to http://www.prestashop.com for more information.
|
||||
*
|
||||
* @author PrestaShop SA <contact@prestashop.com>
|
||||
* @copyright 2007-2011 PrestaShop SA
|
||||
* @version Release: $Revision$
|
||||
* @license http://opensource.org/licenses/afl-3.0.php Academic Free License (AFL 3.0)
|
||||
* International Registered Trademark & Property of PrestaShop SA
|
||||
*/
|
||||
|
||||
if (!defined('_PS_VERSION_'))
|
||||
exit;
|
||||
|
||||
class importerosc extends ImportModule
|
||||
|
||||
@@ -25,7 +25,7 @@
|
||||
* International Registered Trademark & Property of PrestaShop SA
|
||||
*/
|
||||
|
||||
if (!defined('_CAN_LOAD_FILES_'))
|
||||
if (!defined('_PS_VERSION_'))
|
||||
exit;
|
||||
|
||||
class LiveZilla extends Module
|
||||
@@ -118,4 +118,4 @@ class LiveZilla extends Module
|
||||
{
|
||||
return $this->displayBlock();
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -25,7 +25,7 @@
|
||||
* International Registered Trademark & Property of PrestaShop SA
|
||||
*/
|
||||
|
||||
if (!defined('_CAN_LOAD_FILES_'))
|
||||
if (!defined('_PS_VERSION_'))
|
||||
exit;
|
||||
|
||||
class LoyaltyModule extends ObjectModel
|
||||
@@ -240,4 +240,4 @@ class LoyaltyModule extends ObjectModel
|
||||
VALUES ('.(int)($this->id).', '.(int)($this->id_loyalty_state).', '.(int)($this->points).', NOW())');
|
||||
}
|
||||
|
||||
}
|
||||
}
|
||||
|
||||
@@ -25,7 +25,7 @@
|
||||
* International Registered Trademark & Property of PrestaShop SA
|
||||
*/
|
||||
|
||||
if (!defined('_CAN_LOAD_FILES_'))
|
||||
if (!defined('_PS_VERSION_'))
|
||||
exit;
|
||||
|
||||
class LoyaltyStateModule extends ObjectModel
|
||||
@@ -90,4 +90,4 @@ class LoyaltyStateModule extends ObjectModel
|
||||
|
||||
return true;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -25,7 +25,7 @@
|
||||
* International Registered Trademark & Property of PrestaShop SA
|
||||
*/
|
||||
|
||||
if (!defined('_CAN_LOAD_FILES_'))
|
||||
if (!defined('_PS_VERSION_'))
|
||||
exit;
|
||||
|
||||
/*
|
||||
|
||||
@@ -25,7 +25,7 @@
|
||||
* International Registered Trademark & Property of PrestaShop SA
|
||||
*/
|
||||
|
||||
if (!defined('_CAN_LOAD_FILES_'))
|
||||
if (!defined('_PS_VERSION_'))
|
||||
exit;
|
||||
|
||||
class MailAlerts extends Module
|
||||
@@ -580,4 +580,4 @@ class MailAlerts extends Module
|
||||
WHERE `id_product_attribute` = '.(int)$params['id_product_attribute'].'
|
||||
AND `id_product` = '.(int)$params['id_product']);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -25,7 +25,7 @@
|
||||
* International Registered Trademark & Property of PrestaShop SA
|
||||
*/
|
||||
|
||||
if (!defined('_CAN_LOAD_FILES_'))
|
||||
if (!defined('_PS_VERSION_'))
|
||||
exit;
|
||||
|
||||
require_once(_PS_MODULE_DIR_.'mondialrelay/classes/MondialRelayClass.php');
|
||||
|
||||
@@ -25,7 +25,7 @@
|
||||
* International Registered Trademark & Property of PrestaShop SA
|
||||
*/
|
||||
|
||||
if (!defined('_CAN_LOAD_FILES_'))
|
||||
if (!defined('_PS_VERSION_'))
|
||||
exit;
|
||||
|
||||
class MoneyBookers extends PaymentModule
|
||||
|
||||
@@ -25,7 +25,7 @@
|
||||
* International Registered Trademark & Property of PrestaShop SA
|
||||
*/
|
||||
|
||||
if (!defined('_CAN_LOAD_FILES_'))
|
||||
if (!defined('_PS_VERSION_'))
|
||||
exit;
|
||||
|
||||
class Newsletter extends Module
|
||||
|
||||
@@ -25,6 +25,9 @@
|
||||
* International Registered Trademark & Property of PrestaShop SA
|
||||
*/
|
||||
|
||||
if (!defined('_PS_VERSION_'))
|
||||
exit;
|
||||
|
||||
class Ogone extends PaymentModule
|
||||
{
|
||||
private $_ignoreKeyList = array('secure_key');
|
||||
@@ -213,4 +216,4 @@ class Ogone extends PaymentModule
|
||||
$pcc->add();
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -25,7 +25,7 @@
|
||||
* International Registered Trademark & Property of PrestaShop SA
|
||||
*/
|
||||
|
||||
if (!defined('_CAN_LOAD_FILES_'))
|
||||
if (!defined('_PS_VERSION_'))
|
||||
exit;
|
||||
|
||||
class Pagesnotfound extends Module
|
||||
|
||||
@@ -24,7 +24,8 @@
|
||||
* @license http://opensource.org/licenses/afl-3.0.php Academic Free License (AFL 3.0)
|
||||
* International Registered Trademark & Property of PrestaShop SA
|
||||
*/
|
||||
if (!defined('_CAN_LOAD_FILES_'))
|
||||
|
||||
if (!defined('_PS_VERSION_'))
|
||||
exit;
|
||||
|
||||
define('_PAYPAL_INTEGRAL_', 0);
|
||||
|
||||
@@ -24,7 +24,8 @@
|
||||
* @license http://opensource.org/licenses/afl-3.0.php Academic Free License (AFL 3.0)
|
||||
* International Registered Trademark & Property of PrestaShop SA
|
||||
*/
|
||||
if (!defined('_CAN_LOAD_FILES_'))
|
||||
|
||||
if (!defined('_PS_VERSION_'))
|
||||
exit;
|
||||
|
||||
include_once(_PS_MODULE_DIR_.'paysafecard/PrepaidServices.php');
|
||||
|
||||
@@ -25,7 +25,8 @@
|
||||
* @license http://opensource.org/licenses/afl-3.0.php Academic Free License (AFL 3.0)
|
||||
* International Registred Trademark & Property of PrestaShop SA
|
||||
*/
|
||||
if (!defined('_CAN_LOAD_FILES_'))
|
||||
|
||||
if (!defined('_PS_VERSION_'))
|
||||
exit;
|
||||
|
||||
class PrestaFraud extends Module
|
||||
|
||||
@@ -26,7 +26,7 @@
|
||||
* International Registered Trademark & Property of PrestaShop SA
|
||||
*/
|
||||
|
||||
if (!defined('_CAN_LOAD_FILES_'))
|
||||
if (!defined('_PS_VERSION_'))
|
||||
exit;
|
||||
|
||||
class ProductComment extends ObjectModel
|
||||
|
||||
@@ -25,7 +25,7 @@
|
||||
* International Registered Trademark & Property of PrestaShop SA
|
||||
*/
|
||||
|
||||
if (!defined('_CAN_LOAD_FILES_'))
|
||||
if (!defined('_PS_VERSION_'))
|
||||
exit;
|
||||
|
||||
class ProductComments extends Module
|
||||
|
||||
@@ -25,7 +25,7 @@
|
||||
* International Registered Trademark & Property of PrestaShop SA
|
||||
*/
|
||||
|
||||
if (!defined('_CAN_LOAD_FILES_'))
|
||||
if (!defined('_PS_VERSION_'))
|
||||
exit;
|
||||
|
||||
class productsCategory extends Module
|
||||
@@ -177,4 +177,4 @@ class productsCategory extends Module
|
||||
$this->context->controller->addCSS($this->_path.'productscategory.css', 'all');
|
||||
$this->context->controller->addJS(array($this->_path.'productscategory.js', _PS_JS_DIR_.'jquery/jquery.serialScroll-1.2.2-min.js'));
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -25,7 +25,7 @@
|
||||
* International Registered Trademark & Property of PrestaShop SA
|
||||
*/
|
||||
|
||||
if (!defined('_CAN_LOAD_FILES_'))
|
||||
if (!defined('_PS_VERSION_'))
|
||||
exit;
|
||||
|
||||
class ProductToolTip extends Module
|
||||
|
||||
@@ -25,7 +25,7 @@
|
||||
* International Registered Trademark & Property of PrestaShop SA
|
||||
*/
|
||||
|
||||
if (!defined('_CAN_LOAD_FILES_'))
|
||||
if (!defined('_PS_VERSION_'))
|
||||
exit;
|
||||
|
||||
class ReferralProgramModule extends ObjectModel
|
||||
|
||||
@@ -25,7 +25,7 @@
|
||||
* International Registered Trademark & Property of PrestaShop SA
|
||||
*/
|
||||
|
||||
if (!defined('_CAN_LOAD_FILES_'))
|
||||
if (!defined('_PS_VERSION_'))
|
||||
exit;
|
||||
|
||||
class ReferralProgram extends Module
|
||||
|
||||
@@ -25,7 +25,7 @@
|
||||
* International Registered Trademark & Property of PrestaShop SA
|
||||
*/
|
||||
|
||||
if (!defined('_CAN_LOAD_FILES_'))
|
||||
if (!defined('_PS_VERSION_'))
|
||||
exit;
|
||||
|
||||
class Reverso extends Module
|
||||
|
||||
@@ -24,7 +24,8 @@
|
||||
* @license http://opensource.org/licenses/afl-3.0.php Academic Free License (AFL 3.0)
|
||||
* International Registered Trademark & Property of PrestaShop SA
|
||||
*/
|
||||
if (!defined('_CAN_LOAD_FILES_'))
|
||||
|
||||
if (!defined('_PS_VERSION_'))
|
||||
exit;
|
||||
|
||||
class Secuvad extends Module
|
||||
|
||||
@@ -25,7 +25,7 @@
|
||||
* International Registered Trademark & Property of PrestaShop SA
|
||||
*/
|
||||
|
||||
if (!defined('_CAN_LOAD_FILES_'))
|
||||
if (!defined('_PS_VERSION_'))
|
||||
exit;
|
||||
|
||||
class SEKeywords extends ModuleGraph
|
||||
|
||||
@@ -25,7 +25,7 @@
|
||||
* International Registered Trademark & Property of PrestaShop SA
|
||||
*/
|
||||
|
||||
if (!defined('_CAN_LOAD_FILES_'))
|
||||
if (!defined('_PS_VERSION_'))
|
||||
exit;
|
||||
|
||||
class sendToAFriend extends Module
|
||||
|
||||
@@ -1,4 +1,32 @@
|
||||
<?php
|
||||
/*
|
||||
* 2007-2011 PrestaShop
|
||||
*
|
||||
* NOTICE OF LICENSE
|
||||
*
|
||||
* This source file is subject to the Academic Free License (AFL 3.0)
|
||||
* that is bundled with this package in the file LICENSE.txt.
|
||||
* It is also available through the world-wide-web at this URL:
|
||||
* http://opensource.org/licenses/afl-3.0.php
|
||||
* If you did not receive a copy of the license and are unable to
|
||||
* obtain it through the world-wide-web, please send an email
|
||||
* to license@prestashop.com so we can send you a copy immediately.
|
||||
*
|
||||
* DISCLAIMER
|
||||
*
|
||||
* Do not edit or add to this file if you wish to upgrade PrestaShop to newer
|
||||
* versions in the future. If you wish to customize PrestaShop for your
|
||||
* needs please refer to http://www.prestashop.com for more information.
|
||||
*
|
||||
* @author PrestaShop SA <contact@prestashop.com>
|
||||
* @copyright 2007-2011 PrestaShop SA
|
||||
* @version Release: $Revision$
|
||||
* @license http://opensource.org/licenses/afl-3.0.php Academic Free License (AFL 3.0)
|
||||
* International Registered Trademark & Property of PrestaShop SA
|
||||
*/
|
||||
|
||||
if (!defined('_PS_VERSION_'))
|
||||
exit;
|
||||
|
||||
class shopimporter extends ImportModule
|
||||
{
|
||||
|
||||
@@ -25,7 +25,7 @@
|
||||
* International Registered Trademark & Property of PrestaShop SA
|
||||
*/
|
||||
|
||||
if (!defined('_CAN_LOAD_FILES_'))
|
||||
if (!defined('_PS_VERSION_'))
|
||||
exit;
|
||||
|
||||
class Socolissimo extends CarrierModule
|
||||
|
||||
@@ -25,7 +25,7 @@
|
||||
* International Registered Trademark & Property of PrestaShop SA
|
||||
*/
|
||||
|
||||
if (!defined('_CAN_LOAD_FILES_'))
|
||||
if (!defined('_PS_VERSION_'))
|
||||
exit;
|
||||
|
||||
class StatsBestCategories extends ModuleGrid
|
||||
|
||||
@@ -25,7 +25,7 @@
|
||||
* International Registered Trademark & Property of PrestaShop SA
|
||||
*/
|
||||
|
||||
if (!defined('_CAN_LOAD_FILES_'))
|
||||
if (!defined('_PS_VERSION_'))
|
||||
exit;
|
||||
|
||||
class StatsBestCustomers extends ModuleGrid
|
||||
|
||||
@@ -25,10 +25,9 @@
|
||||
* International Registered Trademark & Property of PrestaShop SA
|
||||
*/
|
||||
|
||||
if (!defined('_CAN_LOAD_FILES_'))
|
||||
if (!defined('_PS_VERSION_'))
|
||||
exit;
|
||||
|
||||
|
||||
class StatsBestManufacturers extends ModuleGrid
|
||||
{
|
||||
private $_html = null;
|
||||
|
||||
@@ -25,7 +25,7 @@
|
||||
* International Registered Trademark & Property of PrestaShop SA
|
||||
*/
|
||||
|
||||
if (!defined('_CAN_LOAD_FILES_'))
|
||||
if (!defined('_PS_VERSION_'))
|
||||
exit;
|
||||
|
||||
class StatsBestProducts extends ModuleGrid
|
||||
|
||||
@@ -25,7 +25,7 @@
|
||||
* International Registered Trademark & Property of PrestaShop SA
|
||||
*/
|
||||
|
||||
if (!defined('_CAN_LOAD_FILES_'))
|
||||
if (!defined('_PS_VERSION_'))
|
||||
exit;
|
||||
|
||||
class StatsBestSuppliers extends ModuleGrid
|
||||
|
||||
@@ -25,7 +25,7 @@
|
||||
* International Registered Trademark & Property of PrestaShop SA
|
||||
*/
|
||||
|
||||
if (!defined('_CAN_LOAD_FILES_'))
|
||||
if (!defined('_PS_VERSION_'))
|
||||
exit;
|
||||
|
||||
class StatsBestVouchers extends ModuleGrid
|
||||
@@ -129,4 +129,4 @@ class StatsBestVouchers extends ModuleGrid
|
||||
$this->_values = Db::getInstance(_PS_USE_SQL_SLAVE_)->ExecuteS($this->_query);
|
||||
$this->_totalCount = Db::getInstance(_PS_USE_SQL_SLAVE_)->getValue('SELECT FOUND_ROWS()');
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -25,7 +25,7 @@
|
||||
* International Registered Trademark & Property of PrestaShop SA
|
||||
*/
|
||||
|
||||
if (!defined('_CAN_LOAD_FILES_'))
|
||||
if (!defined('_PS_VERSION_'))
|
||||
exit;
|
||||
|
||||
class StatsCarrier extends ModuleGraph
|
||||
|
||||
@@ -25,7 +25,7 @@
|
||||
* International Registered Trademark & Property of PrestaShop SA
|
||||
*/
|
||||
|
||||
if (!defined('_CAN_LOAD_FILES_'))
|
||||
if (!defined('_PS_VERSION_'))
|
||||
exit;
|
||||
|
||||
class StatsCatalog extends Module
|
||||
|
||||
@@ -25,7 +25,7 @@
|
||||
* International Registered Trademark & Property of PrestaShop SA
|
||||
*/
|
||||
|
||||
if (!defined('_CAN_LOAD_FILES_'))
|
||||
if (!defined('_PS_VERSION_'))
|
||||
exit;
|
||||
|
||||
class StatsCheckUp extends Module
|
||||
|
||||
@@ -25,7 +25,7 @@
|
||||
* International Registered Trademark & Property of PrestaShop SA
|
||||
*/
|
||||
|
||||
if (!defined('_CAN_LOAD_FILES_'))
|
||||
if (!defined('_PS_VERSION_'))
|
||||
exit;
|
||||
|
||||
class StatsData extends Module
|
||||
|
||||
@@ -25,7 +25,7 @@
|
||||
* International Registered Trademark & Property of PrestaShop SA
|
||||
*/
|
||||
|
||||
if (!defined('_CAN_LOAD_FILES_'))
|
||||
if (!defined('_PS_VERSION_'))
|
||||
exit;
|
||||
|
||||
class StatsEquipment extends ModuleGraph
|
||||
|
||||
Some files were not shown because too many files have changed in this diff Show More
Reference in New Issue
Block a user