// reported fix from 1.4.x
This commit is contained in:
@@ -142,6 +142,7 @@ class AdminBackupControllerCore extends AdminController
|
||||
'content' => $this->content,
|
||||
'url_post' => self::$currentIndex.'&token='.$this->token,
|
||||
));
|
||||
parent::initContent();
|
||||
}
|
||||
|
||||
/**
|
||||
|
||||
@@ -372,7 +372,10 @@ class AdminCategoriesControllerCore extends AdminController
|
||||
if (!$object->updatePosition((int)Tools::getValue('way'), (int)Tools::getValue('position')))
|
||||
$this->_errors[] = Tools::displayError('Failed to update the position.');
|
||||
else
|
||||
{
|
||||
$object->regenerateEntireNtree();
|
||||
Tools::redirectAdmin(self::$currentIndex.'&'.$this->table.'Orderby=position&'.$this->table.'Orderway=asc&conf=5'.(($id_category = (int)Tools::getValue($this->identifier, Tools::getValue('id_category_parent', 1))) ? ('&'.$this->identifier.'='.$id_category) : '').'&token='.Tools::getAdminTokenLite('AdminCategories'));
|
||||
}
|
||||
}
|
||||
/* Delete multiple objects */
|
||||
else if (Tools::getValue('submitDel'.$this->table))
|
||||
|
||||
@@ -315,9 +315,9 @@ class AdminCustomerThreadsControllerCore extends AdminController
|
||||
'{comment}' => stripslashes($_POST['message_forward']));
|
||||
|
||||
if (Mail::Send(
|
||||
(int)$cookie->id_lang,
|
||||
$this->context->language->id,
|
||||
'forward_msg',
|
||||
Mail::l('Fwd: Customer message', (int)$cookie->id_lang),
|
||||
Mail::l('Fwd: Customer message', $this->context->language->id),
|
||||
$params, $email, null,
|
||||
$current_employee->email, $current_employee->firstname.' '.$current_employee->lastname,
|
||||
null, null, _PS_MAIL_DIR_, true))
|
||||
@@ -357,7 +357,7 @@ class AdminCustomerThreadsControllerCore extends AdminController
|
||||
);
|
||||
//#ct == id_customer_thread #tc == token of thread <== used in the synchronization imap
|
||||
if (Mail::Send(
|
||||
$ct->id_lang,
|
||||
(int)$ct->id_lang,
|
||||
'reply_msg',
|
||||
Mail::l('An answer to your message is available', $ct->id_lang).' #ct'.$ct->id.'#tc'.$ct->token,
|
||||
$params, Tools::getValue('msg_email'), null, null, null, $file_attachment, null,
|
||||
|
||||
@@ -801,9 +801,10 @@ class AdminImportControllerCore extends AdminController
|
||||
$category->doNotRegenerateNTree = true;
|
||||
|
||||
// If id category AND id category already in base, trying to update
|
||||
if ($category->id && $category->categoryExists($category->id))
|
||||
if ($category->id && $category->categoryExists($category->id) && $category->id != 1)
|
||||
$res = $category->update();
|
||||
|
||||
if ($category->id == 1)
|
||||
$this->_errors[] = Tools::displayError('Root category cannot be modify');
|
||||
// If no id_category or update failed
|
||||
if (!$res)
|
||||
$res = $category->add();
|
||||
@@ -1840,4 +1841,4 @@ class AdminImportControllerCore extends AdminController
|
||||
{
|
||||
$this->warnings[] = $product_name.(isset($product_id) ? ' (ID '.$product_id.')' : '').' '.Tools::displayError($message);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user