Module "DeliveryModulesInFooter" : on avance

This commit is contained in:
2021-09-06 15:07:41 +02:00
parent b4d0169996
commit c7e6fbe6a8
13 changed files with 72 additions and 287 deletions

View File

@@ -0,0 +1,28 @@
<?php
namespace DeliveryModulesInFooter\Hook;
use Thelia\Core\Event\Hook\HookRenderBlockEvent;
use Thelia\Core\Hook\BaseHook;
/**
* Class FrontHook
* @package DeliveryModulesInFooter\Hook
* @author Laurent LE CORRE <laurent@thecoredev.fr>
*/
class FrontHook extends BaseHook
{
public function onMainFooterBody(HookRenderBlockEvent $event)
{
$content = trim($this->render("footer.html"));
if ("" != $content) {
$event->add(
array(
"id" => "delivery-modules-footer-body",
"title" => $this->trans("Our delivery modes", array(), "deliverymodulesinfooter"),
"content" => $content
)
);
}
}
}