[*] CORE : Manual merge of https://github.com/PrestaShop/PrestaShop/ thanks @kpodemski
This commit is contained in:
1 parent
6d5ca9969e
commit
c98b5e0c78
5 files changed
+28
No files matched your search
@@ -34,6 +34,7 @@ class CMSCore extends ObjectModel
|
|||||||
public $link_rewrite;
|
public $link_rewrite;
|
||||||
public $id_cms_category;
|
public $id_cms_category;
|
||||||
public $position;
|
public $position;
|
||||||
|
public $indexation;
|
||||||
public $active;
|
public $active;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
@@ -46,6 +47,7 @@ class CMSCore extends ObjectModel
|
|||||||
'fields' => array(
|
'fields' => array(
|
||||||
'id_cms_category' => array('type' => self::TYPE_INT, 'validate' => 'isUnsignedInt'),
|
'id_cms_category' => array('type' => self::TYPE_INT, 'validate' => 'isUnsignedInt'),
|
||||||
'position' => array('type' => self::TYPE_INT),
|
'position' => array('type' => self::TYPE_INT),
|
||||||
|
'indexation' => array('type' => self::TYPE_BOOL),
|
||||||
'active' => array('type' => self::TYPE_BOOL),
|
'active' => array('type' => self::TYPE_BOOL),
|
||||||
|
|
||||||
// Lang fields
|
// Lang fields
|
||||||
|
|||||||
@@ -152,6 +152,26 @@ class AdminCmsControllerCore extends AdminController
|
|||||||
'cols' => 40,
|
'cols' => 40,
|
||||||
'hint' => $this->l('Invalid characters:').' <>;=#{}'
|
'hint' => $this->l('Invalid characters:').' <>;=#{}'
|
||||||
),
|
),
|
||||||
|
array(
|
||||||
|
'type' => 'radio',
|
||||||
|
'label' => $this->l('Indexation (by search engines):'),
|
||||||
|
'name' => 'indexation',
|
||||||
|
'required' => false,
|
||||||
|
'class' => 't',
|
||||||
|
'is_bool' => true,
|
||||||
|
'values' => array(
|
||||||
|
array(
|
||||||
|
'id' => 'indexation_on',
|
||||||
|
'value' => 1,
|
||||||
|
'label' => $this->l('Enabled')
|
||||||
|
),
|
||||||
|
array(
|
||||||
|
'id' => 'indexation_off',
|
||||||
|
'value' => 0,
|
||||||
|
'label' => $this->l('Disabled')
|
||||||
|
)
|
||||||
|
),
|
||||||
|
),
|
||||||
array(
|
array(
|
||||||
'type' => 'radio',
|
'type' => 'radio',
|
||||||
'label' => $this->l('Displayed:'),
|
'label' => $this->l('Displayed:'),
|
||||||
|
|||||||
@@ -110,6 +110,9 @@ class CmsControllerCore extends FrontController
|
|||||||
'content_only' => (int)(Tools::getValue('content_only')),
|
'content_only' => (int)(Tools::getValue('content_only')),
|
||||||
'path' => $path
|
'path' => $path
|
||||||
));
|
));
|
||||||
|
|
||||||
|
if ($this->cms->indexation == 0)
|
||||||
|
$this->context->smarty->assign('nobots', true);
|
||||||
}
|
}
|
||||||
else if ($this->assignCase == 2)
|
else if ($this->assignCase == 2)
|
||||||
{
|
{
|
||||||
|
|||||||
@@ -365,6 +365,7 @@ CREATE TABLE `PREFIX_cms` (
|
|||||||
`id_cms_category` int(10) unsigned NOT NULL,
|
`id_cms_category` int(10) unsigned NOT NULL,
|
||||||
`position` int(10) unsigned NOT NULL DEFAULT '0',
|
`position` int(10) unsigned NOT NULL DEFAULT '0',
|
||||||
`active` tinyint(1) unsigned NOT NULL default '0',
|
`active` tinyint(1) unsigned NOT NULL default '0',
|
||||||
|
`indexation` tinyint(1) unsigned NOT NULL default '1',
|
||||||
PRIMARY KEY (`id_cms`)
|
PRIMARY KEY (`id_cms`)
|
||||||
) ENGINE=ENGINE_TYPE DEFAULT CHARSET=utf8;
|
) ENGINE=ENGINE_TYPE DEFAULT CHARSET=utf8;
|
||||||
|
|
||||||
|
|||||||
@@ -1,3 +1,5 @@
|
|||||||
ALTER TABLE `PREFIX_customer_message` CHANGE `ip_address` `ip_address` VARCHAR( 15 ) NULL DEFAULT NULL;
|
ALTER TABLE `PREFIX_customer_message` CHANGE `ip_address` `ip_address` VARCHAR( 15 ) NULL DEFAULT NULL;
|
||||||
|
|
||||||
UPDATE `PREFIX_orders` SET conversion_rate = 1 WHERE conversion_rate = 0;
|
UPDATE `PREFIX_orders` SET conversion_rate = 1 WHERE conversion_rate = 0;
|
||||||
|
|
||||||
|
ALTER TABLE `PREFIX_cms` ADD `indexation` tinyint(1) UNSIGNED NULL DEFAULT '1' AFTER `active`;
|
||||||
Reference in new issue
Block a user