Add popup support for vectors.

This commit is contained in:
David Molineus
2015-01-27 18:17:05 +01:00
parent 3abe5c6517
commit 39f8e8d491
4 changed files with 36 additions and 3 deletions

View File

@@ -157,7 +157,7 @@ $GLOBALS['TL_DCA']['tl_leaflet_vector'] = array
'circleMarker extends circle' => array(),
),
'metasubpalettes' => array(
'addPopup' => array('popupContent'),
'addPopup' => array('popup', 'popupContent'),
),
'fields' => array
@@ -242,9 +242,23 @@ $GLOBALS['TL_DCA']['tl_leaflet_vector'] = array
'exclude' => true,
'inputType' => 'checkbox',
'filter' => true,
'eval' => array('tl_class' => 'w50', 'submitOnChange' => true),
'eval' => array('tl_class' => 'w50 m12', 'submitOnChange' => true),
'sql' => "char(1) NOT NULL default ''"
),
'popup' => array
(
'label' => &$GLOBALS['TL_LANG']['tl_leaflet_vector']['popup'],
'exclude' => true,
'inputType' => 'select',
'options_callback' => array('Netzmacht\Contao\Leaflet\Dca\Marker', 'getPopups'),
'eval' => array(
'mandatory' => false,
'tl_class' => 'w50',
'chosen' => true,
'includeBlankOption' => true,
),
'sql' => "int(10) unsigned NOT NULL default '0'",
),
'popupContent' => array
(
'label' => &$GLOBALS['TL_LANG']['tl_leaflet_vector']['popupContent'],