Browse code

Finalize module and also provide content element

Benjamin Roth authored on10/01/2023 21:52:20
Showing1 changed files
... ...
@@ -12,7 +12,7 @@ declare(strict_types=1);
12 12
 
13 13
 use vonRotenberg\ModalBundle\Controller\FrontendModule\ModalModuleController;
14 14
 
15
-$GLOBALS['TL_DCA']['tl_module']['palettes'][ModalModuleController::TYPE] = '{title_legend},name,type;{config_legend},modal_configurations';
15
+$GLOBALS['TL_DCA']['tl_module']['palettes'][ModalModuleController::TYPE] = '{title_legend},name,type;{modalconfig_legend},modal_configurations';
16 16
 
17 17
 
18 18
 $GLOBALS['TL_DCA']['tl_module']['fields']['modal_configurations'] = array
... ...
@@ -20,6 +20,6 @@ $GLOBALS['TL_DCA']['tl_module']['fields']['modal_configurations'] = array
20 20
     'exclude'                  => true,
21 21
     'inputType'                => 'select',
22 22
     'foreignKey'               => 'tl_vr_modal.title',
23
-    'eval'                     => array('mandatory' => true, 'tl_class' => 'w50', 'insertBlankOption' => true, 'chosen' => true),
23
+    'eval'                     => array('mandatory' => true, 'tl_class' => 'w50', 'includeBlankOption' => true, 'chosen' => true),
24 24
     'sql'                      => 'int(10) unsigned NOT NULL default 0'
25 25
 );
Browse code

Modal configuration dropdown in module

Benjamin Roth authored on10/01/2023 14:41:17
Showing1 changed files
... ...
@@ -12,4 +12,14 @@ declare(strict_types=1);
12 12
 
13 13
 use vonRotenberg\ModalBundle\Controller\FrontendModule\ModalModuleController;
14 14
 
15
-$GLOBALS['TL_DCA']['tl_module']['palettes'][ModalModuleController::TYPE] = '{title_legend},name,type;{redirect_legend},jumpTo';
15
+$GLOBALS['TL_DCA']['tl_module']['palettes'][ModalModuleController::TYPE] = '{title_legend},name,type;{config_legend},modal_configurations';
16
+
17
+
18
+$GLOBALS['TL_DCA']['tl_module']['fields']['modal_configurations'] = array
19
+(
20
+    'exclude'                  => true,
21
+    'inputType'                => 'select',
22
+    'foreignKey'               => 'tl_vr_modal.title',
23
+    'eval'                     => array('mandatory' => true, 'tl_class' => 'w50', 'insertBlankOption' => true, 'chosen' => true),
24
+    'sql'                      => 'int(10) unsigned NOT NULL default 0'
25
+);
Browse code

Change directory structure of bundle and add first draft of fragment controller module

Benjamin Roth authored on10/01/2023 14:11:33
Showing1 changed files
1 1
new file mode 100644
... ...
@@ -0,0 +1,15 @@
1
+<?php
2
+
3
+declare(strict_types=1);
4
+
5
+/*
6
+ * This file is part of modal bundle for Contao.
7
+ *
8
+ * (c) Benjamin Roth
9
+ *
10
+ * @license LGPL-3.0-or-later
11
+ */
12
+
13
+use vonRotenberg\ModalBundle\Controller\FrontendModule\ModalModuleController;
14
+
15
+$GLOBALS['TL_DCA']['tl_module']['palettes'][ModalModuleController::TYPE] = '{title_legend},name,type;{redirect_legend},jumpTo';