// Fix localization import
This commit is contained in:
1 parent
23be963aad
commit
1fac16a3b2
1 file changed
+8
-3
@@ -99,10 +99,10 @@ class AdminLocalizationControllerCore extends AdminController
|
|||||||
{
|
{
|
||||||
if (Tools::isSubmit('submitLocalizationPack'))
|
if (Tools::isSubmit('submitLocalizationPack'))
|
||||||
{
|
{
|
||||||
if (!$pack = @Tools::file_get_contents('http://api.prestashop.com/download/localization/'.Tools::getValue('iso_localization_pack').'.xml') &&
|
$pack = @Tools::file_get_contents('http://api.prestashop.com/download/localization/'.Tools::getValue('iso_localization_pack').'.xml');
|
||||||
!$pack = @Tools::file_get_contents(dirname(__FILE__).'/../../localization/'.Tools::getValue('iso_localization_pack').'.xml'))
|
if (!$pack || !($pack = @Tools::file_get_contents(dirname(__FILE__).'/../../localization/'.Tools::getValue('iso_localization_pack').'.xml')))
|
||||||
$this->_errors[] = Tools::displayError('Cannot load localization pack (from prestashop.com and from your local folder "localization")');
|
$this->_errors[] = Tools::displayError('Cannot load localization pack (from prestashop.com and from your local folder "localization")');
|
||||||
else if (!$selection = Tools::getValue('selection'))
|
if (!$selection = Tools::getValue('selection'))
|
||||||
$this->_errors[] = Tools::displayError('Please select at least one content item to import.');
|
$this->_errors[] = Tools::displayError('Please select at least one content item to import.');
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
@@ -151,22 +151,27 @@ class AdminLocalizationControllerCore extends AdminController
|
|||||||
$selection_import = array(
|
$selection_import = array(
|
||||||
array(
|
array(
|
||||||
'id' => 'states',
|
'id' => 'states',
|
||||||
|
'val' => 'states',
|
||||||
'name' => $this->l('States')
|
'name' => $this->l('States')
|
||||||
),
|
),
|
||||||
array(
|
array(
|
||||||
'id' => 'taxes',
|
'id' => 'taxes',
|
||||||
|
'val' => 'taxes',
|
||||||
'name' => $this->l('Taxes')
|
'name' => $this->l('Taxes')
|
||||||
),
|
),
|
||||||
array(
|
array(
|
||||||
'id' => 'currencies',
|
'id' => 'currencies',
|
||||||
|
'val' => 'currencies',
|
||||||
'name' => $this->l('Currencies')
|
'name' => $this->l('Currencies')
|
||||||
),
|
),
|
||||||
array(
|
array(
|
||||||
'id' => 'languages',
|
'id' => 'languages',
|
||||||
|
'val' => 'languages',
|
||||||
'name' => $this->l('Languages')
|
'name' => $this->l('Languages')
|
||||||
),
|
),
|
||||||
array(
|
array(
|
||||||
'id' => 'units',
|
'id' => 'units',
|
||||||
|
'val' => 'units',
|
||||||
'name' => $this->l('Units (e.g., weight, volume, distance)')
|
'name' => $this->l('Units (e.g., weight, volume, distance)')
|
||||||
)
|
)
|
||||||
);
|
);
|
||||||
|
|||||||
Reference in new issue
Block a user