public function postProcess() { if (!($object = $this->loadObject(true))) { return; } if (!in_array($this->display, array('edit', 'add'))) { $this->multishop_context_group = false; } if (Tools::isSubmit('forcedeleteImage') || isset($_FILES['category_image']) && $_FILES['category_image']['size'] > 0 || Tools::getValue('deleteImage')) { $this->processForceDeleteImage(); if (Tools::isSubmit('forcedeleteImage')) { Tools::redirectAdmin(self::$currentIndex . '&token=' . Tools::getAdminTokenLite('AdminCategories') . '&conf=7'); } } else { if (Tools::isSubmit('submitAdd' . $this->table)) { $this->action = 'save'; if ($id_smart_blog_category = (int) pSQL(Tools::getValue('id_smart_blog_category'))) { $this->id_object = $id_smart_blog_category; if (!BlogCategory::checkBeforeMove($id_smart_blog_category, (int) pSQL(Tools::getValue('id_parent')))) { $this->errors[] = Tools::displayError('The Blog Category cannot be moved here.'); Tools::redirectAdmin(self::$currentIndex . '&updatesmart_blog_category&viewsmart_blog_category&id_smart_blog_category=' . (int) $object->id . '&token=' . pSQL(Tools::getValue('token'))); return false; } } $object = parent::postProcess(); $this->updateAssoShop((int) Tools::getValue('id_smart_blog_category')); if ($object !== false) { Tools::redirectAdmin(self::$currentIndex . '&conf=3&viewsmart_blog_category&id_smart_blog_category=' . (int) $object->id . '&token=' . pSQL(Tools::getValue('token'))); } return $object; } } return parent::postProcess(); }