Compare commits
6 Commits
| Author | SHA1 | Date | |
|---|---|---|---|
| 6186a0d8bd | |||
| b28c19cb46 | |||
| 9b2b87d6ba | |||
| dbce287834 | |||
| 78c44d8de6 | |||
| d0916e7b39 |
@@ -10,7 +10,7 @@ Contao 5 Bundle für Organisations-, Veranstaltungsort- und Event-Verwaltung ink
|
||||
## Installation (lokal via Composer)
|
||||
|
||||
```bash
|
||||
composer require mummert-media/eventmanager-bundle
|
||||
composer require mummert/eventmanager-bundle
|
||||
```
|
||||
|
||||
## Installation im Contao Manager (VCS)
|
||||
@@ -18,7 +18,7 @@ composer require mummert-media/eventmanager-bundle
|
||||
1. **Contao Manager** → **Composer** → **Repositories** → **Repository hinzufügen**
|
||||
2. Typ: `vcs`
|
||||
3. URL: `https://github.com/<owner>/eventmanager-bundle`
|
||||
4. Paket hinzufügen: `mummert-media/eventmanager-bundle`
|
||||
4. Paket hinzufügen: `mummert/eventmanager-bundle`
|
||||
5. Bei Bedarf Version `dev-main` oder ein Tag (z. B. `1.0.0`) wählen
|
||||
6. Änderungen anwenden
|
||||
|
||||
|
||||
+4
-3
@@ -1,5 +1,5 @@
|
||||
{
|
||||
"name": "mummert-media/eventmanager-bundle",
|
||||
"name": "mummert/eventmanager-bundle",
|
||||
"description": "Internal Contao backend bundle for organizations, locations and event/member assignments.",
|
||||
"type": "contao-bundle",
|
||||
"license": "proprietary",
|
||||
@@ -11,16 +11,17 @@
|
||||
"require": {
|
||||
"php": "^8.3",
|
||||
"contao/core-bundle": "^5.7",
|
||||
"contao/calendar-bundle": "^5.7",
|
||||
"contao/manager-plugin": "^2.0",
|
||||
"numero2/contao-tags": "^0.5"
|
||||
},
|
||||
"autoload": {
|
||||
"psr-4": {
|
||||
"MummertMedia\\EventManagerBundle\\": "src/"
|
||||
"Mummert\\EventManagerBundle\\": "src/"
|
||||
}
|
||||
},
|
||||
"extra": {
|
||||
"contao-manager-plugin": "MummertMedia\\EventManagerBundle\\Contao\\Manager\\Plugin"
|
||||
"contao-manager-plugin": "Mummert\\EventManagerBundle\\Contao\\Manager\\Plugin"
|
||||
},
|
||||
"prefer-stable": true,
|
||||
"config": {
|
||||
|
||||
@@ -3,16 +3,16 @@ services:
|
||||
autowire: true
|
||||
autoconfigure: true
|
||||
|
||||
MummertMedia\EventManagerBundle\:
|
||||
Mummert\EventManagerBundle\:
|
||||
resource: ../src/
|
||||
exclude:
|
||||
- ../src/DependencyInjection/
|
||||
- ../src/Contao/Manager/
|
||||
- ../src/MummertMediaEventManagerBundle.php
|
||||
- ../src/EventManagerBundle.php
|
||||
|
||||
MummertMedia\EventManagerBundle\EventListener\DataContainer\SetDateAddedCallback:
|
||||
Mummert\EventManagerBundle\EventListener\DataContainer\SetDateAddedCallback:
|
||||
tags:
|
||||
- { name: contao.callback, table: tl_organization, target: config.onbeforesubmit, method: onBeforeSubmit }
|
||||
- { name: contao.callback, table: tl_location, target: config.onbeforesubmit, method: onBeforeSubmit }
|
||||
|
||||
MummertMedia\EventManagerBundle\Service\MapModuleDataProvider: ~
|
||||
Mummert\EventManagerBundle\Service\MapModuleDataProvider: ~
|
||||
|
||||
@@ -2,8 +2,8 @@
|
||||
|
||||
declare(strict_types=1);
|
||||
|
||||
$GLOBALS['TL_MODELS']['tl_organization'] = MummertMedia\EventManagerBundle\Model\OrganizationModel::class;
|
||||
$GLOBALS['TL_MODELS']['tl_location'] = MummertMedia\EventManagerBundle\Model\LocationModel::class;
|
||||
$GLOBALS['TL_MODELS']['tl_organization'] = Mummert\EventManagerBundle\Model\OrganizationModel::class;
|
||||
$GLOBALS['TL_MODELS']['tl_location'] = Mummert\EventManagerBundle\Model\LocationModel::class;
|
||||
|
||||
$GLOBALS['BE_MOD']['content']['eventmanager_organisationen'] = [
|
||||
'tables' => ['tl_organization'],
|
||||
|
||||
@@ -46,6 +46,13 @@
|
||||
|
||||
const targetEventListId = filters.dataset.eventlistId || 'eventlist';
|
||||
const list = document.getElementById(targetEventListId);
|
||||
const initialStoredEventListView = (() => {
|
||||
try {
|
||||
return (window.localStorage.getItem('eventlist_view') || '').trim();
|
||||
} catch (error) {
|
||||
return '';
|
||||
}
|
||||
})();
|
||||
|
||||
const applyDefaultGrid = (targetList) => {
|
||||
if (!targetList) {
|
||||
@@ -53,10 +60,7 @@
|
||||
}
|
||||
|
||||
targetList.classList.add('event-filter-target-list');
|
||||
|
||||
targetList.style.display = 'grid';
|
||||
targetList.style.gridTemplateColumns = 'repeat(auto-fill, minmax(240px, 1fr))';
|
||||
targetList.style.gap = '1rem';
|
||||
targetList.classList.add('grid');
|
||||
};
|
||||
|
||||
if (!list) {
|
||||
@@ -68,6 +72,34 @@
|
||||
|
||||
applyDefaultGrid(list);
|
||||
|
||||
window.addEventListener('DOMContentLoaded', () => {
|
||||
window.setTimeout(() => {
|
||||
if ('' !== initialStoredEventListView) {
|
||||
return;
|
||||
}
|
||||
|
||||
const targetList = document.getElementById(targetEventListId);
|
||||
|
||||
if (!targetList) {
|
||||
return;
|
||||
}
|
||||
|
||||
targetList.classList.remove('list');
|
||||
applyDefaultGrid(targetList);
|
||||
|
||||
const toggleToList = document.getElementById('toggletolist');
|
||||
const toggleToGrid = document.getElementById('toggletogrid');
|
||||
|
||||
toggleToList?.classList.remove('disabled');
|
||||
toggleToGrid?.classList.add('disabled');
|
||||
|
||||
try {
|
||||
window.localStorage.setItem('eventlist_view', 'grid');
|
||||
} catch (error) {
|
||||
}
|
||||
}, 0);
|
||||
}, { once: true });
|
||||
|
||||
const events = list ? Array.from(list.querySelectorAll(':scope > .event')) : [];
|
||||
const tagSelect = filters.querySelector('#tag-filter');
|
||||
const locationSelect = filters.querySelector('#location-filter');
|
||||
|
||||
@@ -2,21 +2,21 @@
|
||||
|
||||
declare(strict_types=1);
|
||||
|
||||
namespace MummertMedia\EventManagerBundle\Contao\Manager;
|
||||
namespace Mummert\EventManagerBundle\Contao\Manager;
|
||||
|
||||
use Contao\CalendarBundle\ContaoCalendarBundle;
|
||||
use Contao\CoreBundle\ContaoCoreBundle;
|
||||
use Contao\ManagerPlugin\Bundle\BundlePluginInterface;
|
||||
use Contao\ManagerPlugin\Bundle\Config\BundleConfig;
|
||||
use Contao\ManagerPlugin\Bundle\Parser\ParserInterface;
|
||||
use MummertMedia\EventManagerBundle\MummertMediaEventManagerBundle;
|
||||
use Mummert\EventManagerBundle\EventManagerBundle;
|
||||
|
||||
class Plugin implements BundlePluginInterface
|
||||
{
|
||||
public function getBundles(ParserInterface $parser): iterable
|
||||
{
|
||||
return [
|
||||
BundleConfig::create(MummertMediaEventManagerBundle::class)
|
||||
BundleConfig::create(EventManagerBundle::class)
|
||||
->setLoadAfter([ContaoCoreBundle::class, ContaoCalendarBundle::class]),
|
||||
];
|
||||
}
|
||||
|
||||
@@ -2,7 +2,7 @@
|
||||
|
||||
declare(strict_types=1);
|
||||
|
||||
namespace MummertMedia\EventManagerBundle\Controller\Frontend;
|
||||
namespace Mummert\EventManagerBundle\Controller\Frontend;
|
||||
|
||||
use Contao\CoreBundle\Controller\FrontendModule\AbstractFrontendModuleController;
|
||||
use Contao\CoreBundle\DependencyInjection\Attribute\AsFrontendModule;
|
||||
@@ -13,8 +13,8 @@ use Contao\FrontendUser;
|
||||
use Contao\ModuleModel;
|
||||
use Contao\PageModel;
|
||||
use Contao\StringUtil;
|
||||
use MummertMedia\EventManagerBundle\Form\EventType;
|
||||
use MummertMedia\EventManagerBundle\Service\EventRepository;
|
||||
use Mummert\EventManagerBundle\Form\EventType;
|
||||
use Mummert\EventManagerBundle\Service\EventRepository;
|
||||
use Symfony\Component\Form\FormError;
|
||||
use Symfony\Component\HttpFoundation\File\UploadedFile;
|
||||
use Symfony\Component\HttpFoundation\RedirectResponse;
|
||||
|
||||
@@ -2,7 +2,7 @@
|
||||
|
||||
declare(strict_types=1);
|
||||
|
||||
namespace MummertMedia\EventManagerBundle\Controller\Frontend;
|
||||
namespace Mummert\EventManagerBundle\Controller\Frontend;
|
||||
|
||||
use Contao\CoreBundle\Controller\FrontendModule\AbstractFrontendModuleController;
|
||||
use Contao\CoreBundle\DependencyInjection\Attribute\AsFrontendModule;
|
||||
|
||||
@@ -2,7 +2,7 @@
|
||||
|
||||
declare(strict_types=1);
|
||||
|
||||
namespace MummertMedia\EventManagerBundle\Controller\Frontend;
|
||||
namespace Mummert\EventManagerBundle\Controller\Frontend;
|
||||
|
||||
use Contao\CoreBundle\Controller\FrontendModule\AbstractFrontendModuleController;
|
||||
use Contao\CoreBundle\DependencyInjection\Attribute\AsFrontendModule;
|
||||
@@ -10,7 +10,7 @@ use Contao\CoreBundle\Twig\FragmentTemplate;
|
||||
use Contao\ModuleModel;
|
||||
use Contao\PageModel;
|
||||
use Contao\StringUtil;
|
||||
use MummertMedia\EventManagerBundle\Service\MapModuleDataProvider;
|
||||
use Mummert\EventManagerBundle\Service\MapModuleDataProvider;
|
||||
use Symfony\Component\HttpFoundation\Request;
|
||||
use Symfony\Component\HttpFoundation\Response;
|
||||
|
||||
|
||||
@@ -2,7 +2,7 @@
|
||||
|
||||
declare(strict_types=1);
|
||||
|
||||
namespace MummertMedia\EventManagerBundle\Controller\Frontend;
|
||||
namespace Mummert\EventManagerBundle\Controller\Frontend;
|
||||
|
||||
use Contao\CoreBundle\Controller\FrontendModule\AbstractFrontendModuleController;
|
||||
use Contao\CoreBundle\DependencyInjection\Attribute\AsFrontendModule;
|
||||
@@ -11,7 +11,7 @@ use Contao\FrontendUser;
|
||||
use Contao\ModuleModel;
|
||||
use Contao\PageModel;
|
||||
use Contao\StringUtil;
|
||||
use MummertMedia\EventManagerBundle\Service\EventRepository;
|
||||
use Mummert\EventManagerBundle\Service\EventRepository;
|
||||
use Symfony\Component\HttpFoundation\RedirectResponse;
|
||||
use Symfony\Component\HttpFoundation\Request;
|
||||
use Symfony\Component\HttpFoundation\Response;
|
||||
|
||||
@@ -2,7 +2,7 @@
|
||||
|
||||
declare(strict_types=1);
|
||||
|
||||
namespace MummertMedia\EventManagerBundle\Controller\Frontend;
|
||||
namespace Mummert\EventManagerBundle\Controller\Frontend;
|
||||
|
||||
use Contao\CoreBundle\Controller\FrontendModule\AbstractFrontendModuleController;
|
||||
use Contao\CoreBundle\DependencyInjection\Attribute\AsFrontendModule;
|
||||
@@ -11,7 +11,7 @@ use Contao\FrontendUser;
|
||||
use Contao\ModuleModel;
|
||||
use Contao\PageModel;
|
||||
use Contao\StringUtil;
|
||||
use MummertMedia\EventManagerBundle\Service\OrganizationRepository;
|
||||
use Mummert\EventManagerBundle\Service\OrganizationRepository;
|
||||
use Symfony\Component\HttpFoundation\Request;
|
||||
use Symfony\Component\HttpFoundation\Response;
|
||||
|
||||
|
||||
@@ -2,7 +2,7 @@
|
||||
|
||||
declare(strict_types=1);
|
||||
|
||||
namespace MummertMedia\EventManagerBundle\Controller\Frontend;
|
||||
namespace Mummert\EventManagerBundle\Controller\Frontend;
|
||||
|
||||
use Contao\CoreBundle\Controller\FrontendModule\AbstractFrontendModuleController;
|
||||
use Contao\CoreBundle\DependencyInjection\Attribute\AsFrontendModule;
|
||||
@@ -13,8 +13,8 @@ use Contao\FrontendUser;
|
||||
use Contao\ModuleModel;
|
||||
use Contao\PageModel;
|
||||
use Contao\StringUtil;
|
||||
use MummertMedia\EventManagerBundle\Form\OrganizationType;
|
||||
use MummertMedia\EventManagerBundle\Service\OrganizationRepository;
|
||||
use Mummert\EventManagerBundle\Form\OrganizationType;
|
||||
use Mummert\EventManagerBundle\Service\OrganizationRepository;
|
||||
use Symfony\Component\HttpFoundation\File\UploadedFile;
|
||||
use Symfony\Component\HttpFoundation\RedirectResponse;
|
||||
use Symfony\Component\HttpFoundation\Request;
|
||||
|
||||
+2
-2
@@ -2,14 +2,14 @@
|
||||
|
||||
declare(strict_types=1);
|
||||
|
||||
namespace MummertMedia\EventManagerBundle\DependencyInjection;
|
||||
namespace Mummert\EventManagerBundle\DependencyInjection;
|
||||
|
||||
use Symfony\Component\Config\FileLocator;
|
||||
use Symfony\Component\DependencyInjection\ContainerBuilder;
|
||||
use Symfony\Component\DependencyInjection\Extension\Extension;
|
||||
use Symfony\Component\DependencyInjection\Loader\YamlFileLoader;
|
||||
|
||||
class MummertMediaEventManagerExtension extends Extension
|
||||
class EventManagerExtension extends Extension
|
||||
{
|
||||
public function load(array $configs, ContainerBuilder $container): void
|
||||
{
|
||||
@@ -2,7 +2,7 @@
|
||||
|
||||
declare(strict_types=1);
|
||||
|
||||
namespace MummertMedia\EventManagerBundle\EventListener\DataContainer;
|
||||
namespace Mummert\EventManagerBundle\EventListener\DataContainer;
|
||||
|
||||
use Contao\DataContainer;
|
||||
|
||||
|
||||
@@ -2,7 +2,7 @@
|
||||
|
||||
declare(strict_types=1);
|
||||
|
||||
namespace MummertMedia\EventManagerBundle\EventListener;
|
||||
namespace Mummert\EventManagerBundle\EventListener;
|
||||
|
||||
use Contao\CoreBundle\DependencyInjection\Attribute\AsHook;
|
||||
use Contao\StringUtil;
|
||||
|
||||
@@ -2,7 +2,7 @@
|
||||
|
||||
declare(strict_types=1);
|
||||
|
||||
namespace MummertMedia\EventManagerBundle\EventListener;
|
||||
namespace Mummert\EventManagerBundle\EventListener;
|
||||
|
||||
use Contao\CoreBundle\DependencyInjection\Attribute\AsHook;
|
||||
use Contao\Module;
|
||||
|
||||
@@ -2,7 +2,7 @@
|
||||
|
||||
declare(strict_types=1);
|
||||
|
||||
namespace MummertMedia\EventManagerBundle\EventListener;
|
||||
namespace Mummert\EventManagerBundle\EventListener;
|
||||
|
||||
use Contao\CoreBundle\DependencyInjection\Attribute\AsHook;
|
||||
use Contao\StringUtil;
|
||||
|
||||
@@ -2,11 +2,11 @@
|
||||
|
||||
declare(strict_types=1);
|
||||
|
||||
namespace MummertMedia\EventManagerBundle;
|
||||
namespace Mummert\EventManagerBundle;
|
||||
|
||||
use Symfony\Component\HttpKernel\Bundle\Bundle;
|
||||
|
||||
class MummertMediaEventManagerBundle extends Bundle
|
||||
class EventManagerBundle extends Bundle
|
||||
{
|
||||
public function getPath(): string
|
||||
{
|
||||
@@ -2,7 +2,7 @@
|
||||
|
||||
declare(strict_types=1);
|
||||
|
||||
namespace MummertMedia\EventManagerBundle\Form;
|
||||
namespace Mummert\EventManagerBundle\Form;
|
||||
|
||||
use Symfony\Component\Form\AbstractType;
|
||||
use Symfony\Component\Form\Extension\Core\Type\CheckboxType;
|
||||
|
||||
@@ -2,7 +2,7 @@
|
||||
|
||||
declare(strict_types=1);
|
||||
|
||||
namespace MummertMedia\EventManagerBundle\Form;
|
||||
namespace Mummert\EventManagerBundle\Form;
|
||||
|
||||
use Symfony\Component\Form\AbstractType;
|
||||
use Symfony\Component\Form\Extension\Core\Type\ChoiceType;
|
||||
|
||||
@@ -2,7 +2,7 @@
|
||||
|
||||
declare(strict_types=1);
|
||||
|
||||
namespace MummertMedia\EventManagerBundle\Model;
|
||||
namespace Mummert\EventManagerBundle\Model;
|
||||
|
||||
use Contao\Model;
|
||||
|
||||
|
||||
@@ -2,7 +2,7 @@
|
||||
|
||||
declare(strict_types=1);
|
||||
|
||||
namespace MummertMedia\EventManagerBundle\Model;
|
||||
namespace Mummert\EventManagerBundle\Model;
|
||||
|
||||
use Contao\Model;
|
||||
|
||||
|
||||
@@ -2,7 +2,7 @@
|
||||
|
||||
declare(strict_types=1);
|
||||
|
||||
namespace MummertMedia\EventManagerBundle\Service;
|
||||
namespace Mummert\EventManagerBundle\Service;
|
||||
|
||||
use Doctrine\DBAL\Connection;
|
||||
use Doctrine\DBAL\ParameterType;
|
||||
|
||||
@@ -2,7 +2,7 @@
|
||||
|
||||
declare(strict_types=1);
|
||||
|
||||
namespace MummertMedia\EventManagerBundle\Service;
|
||||
namespace Mummert\EventManagerBundle\Service;
|
||||
|
||||
use Contao\CalendarEventsModel;
|
||||
use Contao\CoreBundle\Framework\ContaoFramework;
|
||||
|
||||
@@ -2,7 +2,7 @@
|
||||
|
||||
declare(strict_types=1);
|
||||
|
||||
namespace MummertMedia\EventManagerBundle\Service;
|
||||
namespace Mummert\EventManagerBundle\Service;
|
||||
|
||||
use Doctrine\DBAL\Connection;
|
||||
use Doctrine\DBAL\ParameterType;
|
||||
|
||||
Reference in New Issue
Block a user