feat(main): Groups and blocks
This commit is contained in:
@@ -2,6 +2,7 @@
|
||||
|
||||
namespace Websmid\CustomHtml\Module;
|
||||
|
||||
use Websmid\CustomHtml\Config\Config;
|
||||
use Tools;
|
||||
|
||||
trait AdminHooks
|
||||
@@ -13,6 +14,17 @@ trait AdminHooks
|
||||
|
||||
public function getContent()
|
||||
{
|
||||
Tools::redirectAdmin($this->get('router')->generate('customhtml_index'));
|
||||
Tools::redirectAdmin($this->get('router')->generate('customhtmlgroup_index'));
|
||||
}
|
||||
|
||||
public function hookActionAdminControllerSetMedia(): void
|
||||
{
|
||||
$controllerName = $this->context->controller->controller_name ?? '';
|
||||
|
||||
if (!in_array($controllerName, Config::ADMIN_CONTROLLERS, true)) {
|
||||
return;
|
||||
}
|
||||
|
||||
$this->context->controller->addCSS($this->getPathUri() . 'views/css/admin/grid.css');
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user