<?php
$layout=$this->item->params->get('layout','default');
require_once __DIR__."/Helper.php";
$list_event=WpBookingPro_listeventHelper::getListEvent();
$form=WpBookingPro_listeventHelper::getForm();
$form_field=WpBookingPro_listeventHelper::getFormField();
$form_booking=WpBookingPro_listeventHelper::getFormBooking();
$plugin_name=WPBOOKINGPRO_PLUGIN_NAME;
$template_path=get_template_directory();
$block_name= basename(__DIR__);
$layout_name="tmpl/$layout.php";
$template1_path="$template_path/$plugin_name/blocks/$block_name/$layout_name";
$template2_path= __DIR__ . "/tmpl/$layout.php";
if(file_exists($template1_path)){
    require $template1_path;
}else{
    require $template2_path;
}
