Files
contao-leaflet-maps/src/Bundle/Resources/contao/config/config.php

68 lines
2.5 KiB
PHP
Raw Normal View History

2014-12-27 22:58:58 +01:00
<?php
2015-01-12 19:03:29 +01:00
/**
2017-10-05 15:45:43 +02:00
* Leaflet maps for Contao CMS.
*
2016-10-11 10:40:15 +02:00
* @package contao-leaflet-maps
2015-01-12 19:03:29 +01:00
* @author David Molineus <david.molineus@netzmacht.de>
2017-10-11 15:00:48 +02:00
* @copyright 2014-2017 netzmacht David Molineus. All rights reserved.
2017-10-05 15:45:43 +02:00
* @license LGPL-3.0 https://github.com/netzmacht/contao-leaflet-maps/blob/master/LICENSE
2015-01-12 19:03:29 +01:00
* @filesource
*/
2014-12-29 12:17:40 +01:00
/*
* Backend module.
*/
2017-10-05 16:14:46 +02:00
2015-01-09 11:53:58 +01:00
array_insert(
$GLOBALS['BE_MOD'],
1,
[
'leaflet' => [
'leaflet_map' => [
'tables' => [
2015-01-09 11:53:58 +01:00
'tl_leaflet_map',
'tl_leaflet_control',
],
2017-10-06 15:06:35 +02:00
'icon' => 'bundles/netzmachtcontaoleaflet/img/map.png',
'stylesheet' => 'bundles/netzmachtcontaoleaflet/css/backend.css',
],
'leaflet_layer' => [
'tables' => [
2015-01-09 11:53:58 +01:00
'tl_leaflet_layer',
'tl_leaflet_marker',
'tl_leaflet_vector',
'tl_leaflet_icon',
'tl_leaflet_style',
2015-01-27 17:14:58 +01:00
'tl_leaflet_popup',
],
2017-10-06 15:06:35 +02:00
'icon' => 'bundles/netzmachtcontaoleaflet/img/layers.png',
'stylesheet' => 'bundles/netzmachtcontaoleaflet/css/backend.css',
'javascript' => 'bundles/netzmachtcontaoleaflet/js/backend.js',
],
'leaflet_about' => [
2017-10-11 14:50:14 +02:00
'callback' => Netzmacht\Contao\Leaflet\Backend\About::class,
2017-10-06 15:06:35 +02:00
'icon' => 'bundles/netzmachtcontaoleaflet/img/about.png',
'stylesheet' => 'bundles/netzmachtcontaoleaflet/css/about.css',
],
],
]
2014-12-29 12:17:40 +01:00
);
if (TL_MODE === 'BE') {
2017-11-13 13:13:14 +01:00
$GLOBALS['TL_CSS'][] = 'bundles/netzmachtcontaoleaflet/css/backend_global.css';
}
2014-12-29 12:17:40 +01:00
/*
* Models.
*/
2017-10-05 16:14:46 +02:00
2017-10-06 15:04:04 +02:00
$GLOBALS['TL_MODELS']['tl_leaflet_control'] = \Netzmacht\Contao\Leaflet\Model\ControlModel::class;
$GLOBALS['TL_MODELS']['tl_leaflet_icon'] = \Netzmacht\Contao\Leaflet\Model\IconModel::class;
$GLOBALS['TL_MODELS']['tl_leaflet_layer'] = \Netzmacht\Contao\Leaflet\Model\LayerModel::class;
$GLOBALS['TL_MODELS']['tl_leaflet_map'] = \Netzmacht\Contao\Leaflet\Model\MapModel::class;
$GLOBALS['TL_MODELS']['tl_leaflet_marker'] = \Netzmacht\Contao\Leaflet\Model\MarkerModel::class;
$GLOBALS['TL_MODELS']['tl_leaflet_popup'] = \Netzmacht\Contao\Leaflet\Model\PopupModel::class;
$GLOBALS['TL_MODELS']['tl_leaflet_style'] = \Netzmacht\Contao\Leaflet\Model\StyleModel::class;
$GLOBALS['TL_MODELS']['tl_leaflet_vector'] = \Netzmacht\Contao\Leaflet\Model\VectorModel::class;