carto_J5 to main #1
@ -1,2 +0,0 @@
|
|||||||
<html><body bgcolor="#FFFFFF"></body></html>
|
|
||||||
<!-- prevents web server from listing directory content -->
|
|
||||||
@ -1 +0,0 @@
|
|||||||
Hello World administration
|
|
||||||
29
com_leaflet/admin/services/provider.php
Normal file
29
com_leaflet/admin/services/provider.php
Normal file
@ -0,0 +1,29 @@
|
|||||||
|
<?php
|
||||||
|
|
||||||
|
defined('_JEXEC') or die;
|
||||||
|
|
||||||
|
use Joomla\CMS\Dispatcher\ComponentDispatcherFactoryInterface;
|
||||||
|
use Joomla\CMS\Extension\ComponentInterface;
|
||||||
|
use Joomla\CMS\Extension\MVCComponent;
|
||||||
|
use Joomla\CMS\Extension\Service\Provider\ComponentDispatcherFactory;
|
||||||
|
use Joomla\CMS\Extension\Service\Provider\MVCFactory;
|
||||||
|
use Joomla\CMS\MVC\Factory\MVCFactoryInterface;
|
||||||
|
use Joomla\DI\Container;
|
||||||
|
use Joomla\DI\ServiceProviderInterface;
|
||||||
|
|
||||||
|
return new class implements ServiceProviderInterface {
|
||||||
|
|
||||||
|
public function register(Container $container): void {
|
||||||
|
$container->registerServiceProvider(new MVCFactory('\\Digitanie\\Component\\Leaflet'));
|
||||||
|
$container->registerServiceProvider(new ComponentDispatcherFactory('\\Digitanie\\Component\\Leaflet'));
|
||||||
|
$container->set(
|
||||||
|
ComponentInterface::class,
|
||||||
|
function (Container $container) {
|
||||||
|
$component = new MVCComponent($container->get(ComponentDispatcherFactoryInterface::class));
|
||||||
|
$component->setMVCFactory($container->get(MVCFactoryInterface::class));
|
||||||
|
|
||||||
|
return $component;
|
||||||
|
}
|
||||||
|
);
|
||||||
|
}
|
||||||
|
};
|
||||||
27
com_leaflet/admin/src/Controller/DisplayController.php
Normal file
27
com_leaflet/admin/src/Controller/DisplayController.php
Normal file
@ -0,0 +1,27 @@
|
|||||||
|
<?php
|
||||||
|
|
||||||
|
namespace Digitanie\Component\Leaflet\Administrator\Controller;
|
||||||
|
|
||||||
|
defined('_JEXEC') or die;
|
||||||
|
|
||||||
|
use Joomla\CMS\MVC\Controller\BaseController;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Default Controller of Leaflet component
|
||||||
|
*
|
||||||
|
* @package Joomla.Administrator
|
||||||
|
* @subpackage com_leaflet
|
||||||
|
*/
|
||||||
|
class DisplayController extends BaseController {
|
||||||
|
/**
|
||||||
|
* The default view for the display method.
|
||||||
|
*
|
||||||
|
* @var string
|
||||||
|
*/
|
||||||
|
protected $default_view = 'Leaflet';
|
||||||
|
|
||||||
|
public function display($cachable = false, $urlparams = array()) {
|
||||||
|
return parent::display($cachable, $urlparams);
|
||||||
|
}
|
||||||
|
|
||||||
|
}
|
||||||
23
com_leaflet/admin/src/View/Leaflet/HtmlView.php
Normal file
23
com_leaflet/admin/src/View/Leaflet/HtmlView.php
Normal file
@ -0,0 +1,23 @@
|
|||||||
|
<?php
|
||||||
|
|
||||||
|
namespace Digitanie\Component\Leaflet\Administrator\View\Leaflet;
|
||||||
|
|
||||||
|
defined('_JEXEC') or die;
|
||||||
|
|
||||||
|
use Joomla\CMS\MVC\View\HtmlView as BaseHtmlView;
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Main "Leaflet" Admin View
|
||||||
|
*/
|
||||||
|
class HtmlView extends BaseHtmlView {
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Display the main "Leaflet" view
|
||||||
|
*
|
||||||
|
* @param string $tpl The name of the template file to parse; automatically searches through the template paths.
|
||||||
|
* @return void
|
||||||
|
*/
|
||||||
|
function display($tpl = null) {
|
||||||
|
parent::display($tpl);
|
||||||
|
}
|
||||||
|
}
|
||||||
6
com_leaflet/admin/tmpl/leaflet/default.php
Normal file
6
com_leaflet/admin/tmpl/leaflet/default.php
Normal file
@ -0,0 +1,6 @@
|
|||||||
|
<?php
|
||||||
|
|
||||||
|
// No direct access to this file
|
||||||
|
defined('_JEXEC') or die('Restricted Access');
|
||||||
|
?>
|
||||||
|
<h2>Leaflet administration</h2>
|
||||||
Loading…
Reference in New Issue
Block a user