// reset category filter on adminproducts on multishop when category is not associated to the shop
This commit is contained in:
@@ -126,6 +126,15 @@ class AdminProductsControllerCore extends AdminController
|
|||||||
|
|
||||||
if (Tools::getValue('reset_filter_category'))
|
if (Tools::getValue('reset_filter_category'))
|
||||||
$this->context->cookie->id_category_products_filter = false;
|
$this->context->cookie->id_category_products_filter = false;
|
||||||
|
if (Shop::isFeatureActive() && $this->context->cookie->id_category_products_filter)
|
||||||
|
{
|
||||||
|
$category = new Category((int)$this->context->cookie->id_category_products_filter);
|
||||||
|
if (!$category->inShop())
|
||||||
|
{
|
||||||
|
$this->context->cookie->id_category_products_filter = false;
|
||||||
|
Tools::redirectAdmin($this->context->link->getAdminLink('AdminProducts'));
|
||||||
|
}
|
||||||
|
}
|
||||||
/* Join categories table */
|
/* Join categories table */
|
||||||
if ($id_category = (int)Tools::getValue('productFilter_cl!name'))
|
if ($id_category = (int)Tools::getValue('productFilter_cl!name'))
|
||||||
{
|
{
|
||||||
|
|||||||
Reference in New Issue
Block a user