### Display Organizer Title Source: https://github.com/georgringer/eventnews/blob/main/Resources/Private/Templates/News/Month.html Use this ViewHelper to display the title of an organizer. No specific setup is required beyond having organizer data available. ```Fluid {organizer.title} ``` -------------------------------- ### Create and Configure Event News Record Source: https://context7.com/georgringer/eventnews/llms.txt Demonstrates how to create a new news record and set it as an event with specific properties like full-day status, end date, and associated location and organizer objects. Also shows how to use simple text-based location and organizer. ```php setIsEvent(true); // Set event as full-day (no specific time) $event->setFullDay(true); // Set event end date for multi-day events $eventEnd = new \DateTime('2024-12-31'); $event->setEventEnd($eventEnd); // Create and assign a location $location = new Location(); $location->setTitle('Conference Center'); $location->setDescription('Main conference hall'); $location->setLat(52.5200); $location->setLng(13.4050); $location->setLink('https://example.com/venue'); $event->setLocation($location); // Create and assign an organizer $organizer = new Organizer(); $organizer->setTitle('TYPO3 Association'); $organizer->setDescription('Official TYPO3 organization'); $organizer->setLink('https://typo3.org'); $event->setOrganizer($organizer); // Alternative: Use simple text-based location/organizer $event->setLocationSimple('Berlin, Germany'); $event->setOrganizerSimple('TYPO3 Team'); // Check event properties if ($event->getIsEvent() && $event->isFullDay()) { echo "Full-day event ending: " . $event->getEventEnd()->format('Y-m-d'); } ``` -------------------------------- ### Create and Configure Location Model Source: https://context7.com/georgringer/eventnews/llms.txt Illustrates how to instantiate and populate the Location model with details such as title, description, geographic coordinates (latitude and longitude), and an external website link. ```php setTitle('TYPO3 Conference Hall'); $location->setDescription('The main venue for all TYPO3 conferences and meetups.'); // Set geographic coordinates for map integration $location->setLat(48.1351); // Latitude $location->setLng(11.5820); // Longitude // Set external link to venue website $location->setLink('https://conference-venue.example.com'); // Access location properties echo "Venue: " . $location->getTitle(); echo "Coordinates: " . $location->getLat() . ", " . $location->getLng(); echo "More info: " . $location->getLink(); ``` -------------------------------- ### Repository Methods for Locations and Organizers Source: https://context7.com/georgringer/eventnews/llms.txt Demonstrates dependency injection and querying methods for fetching locations and organizers, including storage page filtering. ```php locationRepository = $locationRepository; $this->organizerRepository = $organizerRepository; } // Find all locations (sorted by title ascending) $allLocations = $this->locationRepository->findAll(); // Find locations from specific storage pages // Accepts comma-separated list of page IDs $locations = $this->locationRepository->findByStartingPoint('10,20,30'); // Find all organizers $allOrganizers = $this->organizerRepository->findAll(); // Find organizers from specific storage pages $organizers = $this->organizerRepository->findByStartingPoint('15,25'); ``` -------------------------------- ### Create and Configure Organizer Model Source: https://context7.com/georgringer/eventnews/llms.txt Shows how to create an Organizer object and set its title, description, and a related website link. This model is used to store information about event organizers. ```php setTitle('TYPO3 User Group Munich'); $organizer->setDescription('Local TYPO3 community organizing regular meetups and workshops.'); $organizer->setLink('https://usergroup-munich.typo3.org'); // Access organizer properties echo "Organized by: " . $organizer->getTitle(); echo "About: " . $organizer->getDescription(); echo "Website: " . $organizer->getLink(); ``` -------------------------------- ### Implement Month View Template Source: https://context7.com/georgringer/eventnews/llms.txt Provides a complete Fluid template structure including organizer/location filters, date range inputs, and calendar navigation. ```html {namespace events=GeorgRinger\Eventnews\ViewHelpers} {namespace n=GeorgRinger\News\ViewHelpers}
{f:format.date(date: day.ts, format: '%A')}
{day.day} ``` -------------------------------- ### Configure Demand Object for Event Filtering Source: https://context7.com/georgringer/eventnews/llms.txt Demonstrates how to initialize and configure the Demand Data Transfer Object (DTO) for filtering news records, including event-specific criteria like locations, organizers, date ranges, and event restrictions. It also shows how to set parameters for calendar views. ```php Demand::EVENT_RESTRICTION_ONLY_EVENTS // Show only events ]; $demand = new Demand($settings); // Filter by locations (array of location UIDs) $demand->setLocations([1, 2, 3]); // Filter by organizers (array of organizer UIDs) $demand->setOrganizers([5, 6]); // Set date range filter $demand->setSearchDateFrom('2024-01-01'); $demand->setSearchDateTo('2024-12-31'); // Set month/year for calendar view $demand->setMonth(6); // June $demand->setYear(2024); // Enable day-specific filtering $demand->setDay(15); $demand->setRespectDay(true); // Event restriction constants: // Demand::EVENT_RESTRICTION_ONLY_EVENTS = 1 (show only events) // Demand::EVENT_RESTRICTION_NO_EVENTS = 2 (show only regular news) // Access filtered values (removes empty entries) $activeLocations = $demand->getLocations(); $activeOrganizers = $demand->getOrganizers(); ``` -------------------------------- ### Render Calendar Grid with CalendarViewHelper Source: https://context7.com/georgringer/eventnews/llms.txt Use the CalendarViewHelper to generate a grid structure and map news events to specific days. ```html {namespace events=GeorgRinger\\\Eventnews\\\ViewHelpers}
{f:format.date(date: day.ts, format: '%a')}
{day.day}
  • {event.title}
``` -------------------------------- ### Configure New News as Event Source: https://github.com/georgringer/eventnews/blob/main/Documentation/AdministratorManual/Index.rst Sets default behavior for new news records and hides the 'Is event' checkbox in the backend. ```typoscript tx_news.newRecordAsEvent = 1 TCEFORM.tx_news_domain_model_news.is_event { disabled = 1 } ``` -------------------------------- ### Configure Template Root Paths Source: https://github.com/georgringer/eventnews/blob/main/Documentation/AdministratorManual/Index.rst Defines the directory for custom extension templates via TypoScript. ```typoscript plugin.tx_eventnews { view { templateRootPaths { 10 = EXT:your-site-package/Resources/Private/Extensions/Eventnews/Templates/ } } } ``` -------------------------------- ### Initialize SearchDemand Object Source: https://context7.com/georgringer/eventnews/llms.txt Instantiate and configure the SearchDemand DTO to handle event filtering criteria from form submissions. ```php setLocations([1, 3, 7]); $search->setOrganizers([2, 4]); $search->setCategories([10, 20, 30]); $search->setTags([5, 8]); // Set date range from date picker inputs $search->setSearchDateFrom('2024-06-01'); $search->setSearchDateTo('2024-06-30'); // Access search criteria $selectedLocations = $search->getLocations(); $selectedCategories = $search->getCategories(); $dateFrom = $search->getSearchDateFrom(); ``` -------------------------------- ### Page TSconfig Configuration Source: https://context7.com/georgringer/eventnews/llms.txt Configures backend behavior for news records, including automatic event creation and field visibility. ```typoscript # Automatically create new news records as events tx_news.newRecordAsEvent = 1 # Hide the "Is event" checkbox (when all records should be events) TCEFORM.tx_news_domain_model_news.is_event { disabled = 1 } # Optionally hide event fields for regular news pages TCEFORM.tx_news_domain_model_news { event_end.disabled = 1 full_day.disabled = 1 location.disabled = 1 organizer.disabled = 1 } ``` -------------------------------- ### Filter Events with DayCompare ViewHelper Source: https://context7.com/georgringer/eventnews/llms.txt Use DayCompare to conditionally display news items based on whether they match a selected day in the demand object. ```html {namespace events=GeorgRinger\\\Eventnews\\\ViewHelpers}

{newsItem.title}

Start: {newsItem.datetime -> f:format.date(format: 'd.m.Y H:i')}

End: {newsItem.eventEnd -> f:format.date(format: 'd.m.Y H:i')}

{newsItem.title}

``` -------------------------------- ### TypoScript Configuration Source: https://context7.com/georgringer/eventnews/llms.txt Configures plugin settings, template paths, and storage page overrides for the Eventnews extension. ```typoscript # Basic plugin configuration plugin.tx_news.settings { # Use EventNews demand class for filtering demandClass = GeorgRinger\Eventnews\Domain\Model\Dto\Demand # Event restriction settings: # 1 = Show only events # 2 = Show only regular news (no events) # 0 or empty = Show all eventRestriction = 2 # Add eventRestriction to overridable settings overrideFlexformSettingsIfEmpty := addToList(eventRestriction) } # EventNews specific settings plugin.tx_eventnews { view { # Override template paths templateRootPaths { 10 = EXT:your-site-package/Resources/Private/Extensions/Eventnews/Templates/ } partialRootPaths { 10 = EXT:your-site-package/Resources/Private/Extensions/Eventnews/Partials/ } layoutRootPaths { 10 = EXT:your-site-package/Resources/Private/Extensions/Eventnews/Layouts/ } } settings { # Storage page for locations (overrides general startingpoint) startingpointLocation = 50 # Storage page for organizers (overrides general startingpoint) startingpointOrganizer = 51 } } ``` -------------------------------- ### Render Event Calendar and List Source: https://context7.com/georgringer/eventnews/llms.txt Displays a monthly calendar view and a list of events with conditional rendering based on the selected day. ```html
{day.day}
``` -------------------------------- ### Format Date for Month Navigation Source: https://github.com/georgringer/eventnews/blob/main/Resources/Private/Templates/News/Month.html Formats a date for displaying month names in navigation. Use the '%B %Y' format for 'Month Year' representation. ```Fluid {f:format.date(date:previousMonthData.date,format:'%B %Y')} ``` ```Fluid {f:format.date(date:currentMonthData.date,format:'%B %Y')} ``` ```Fluid {f:format.date(date:nextMonthData.date,format:'%B %Y')} ``` -------------------------------- ### Display Day of Month Source: https://github.com/georgringer/eventnews/blob/main/Resources/Private/Templates/News/Month.html Displays the day of the month. Assumes 'day.day' variable is available. ```Fluid {day.day} ``` -------------------------------- ### Display News Item Organizer and Location Source: https://github.com/georgringer/eventnews/blob/main/Resources/Private/Templates/News/Month.html Displays the organizer and location details for a news item, including their UIDs. Requires 'n.organizer.title', 'n.organizer.uid', 'n.location.title', and 'n.location.uid' to be present. ```Fluid : {n.organizer.title} (uid: {n.organizer.uid}) ``` ```Fluid : {n.location.title} (uid: {n.location.uid}) ``` -------------------------------- ### Display Tag Title Source: https://github.com/georgringer/eventnews/blob/main/Resources/Private/Templates/News/Month.html Use this ViewHelper to display the title of a tag. Ensure tag data is available in the template's scope. ```Fluid {tag.title} ``` -------------------------------- ### Filter Organizer ViewHelper Source: https://context7.com/georgringer/eventnews/llms.txt Filters organizers to display only those associated with events in the current news list. ```html {namespace events=GeorgRinger\Eventnews\ViewHelpers}

Filter by Organizer

``` -------------------------------- ### Display Location Title Source: https://github.com/georgringer/eventnews/blob/main/Resources/Private/Templates/News/Month.html Use this ViewHelper to display the title of a location. Ensure location data is present in the template context. ```Fluid {location.title} ``` -------------------------------- ### Define NewsController Month Action Source: https://context7.com/georgringer/eventnews/llms.txt Signature for the monthAction in NewsController, which supports monthly calendar views and demand-based filtering. ```php

{event.title}

- {f:format.date(date:event.eventEnd, format:'d.m.Y H:i')} Full Day

Location: {event.location.title}

Organizer: {event.organizer.title}

``` -------------------------------- ### Display News Item Title and Date Source: https://github.com/georgringer/eventnews/blob/main/Resources/Private/Templates/News/Month.html Displays the title of a news item along with its formatted date. The date is formatted as 'DD.MM'. Ensure 'n.title' and 'n.datetime' are available. ```Fluid {n.title} | {f:format.date(date:n.datetime,format:'%d.%m')} ``` -------------------------------- ### Display Category Title Source: https://github.com/georgringer/eventnews/blob/main/Resources/Private/Templates/News/Month.html Use this ViewHelper to display the title of a category. This assumes category data is accessible within the template. ```Fluid {category.title} ``` -------------------------------- ### Import Deprecated Eventnews TypoScript Constants Source: https://github.com/georgringer/eventnews/blob/main/Configuration/TypoScript/constants.txt This TypoScript code imports constants from the EXT:eventnews extension. Note that this file is deprecated and will be removed in EXT:eventnews 7.x. ```typoscript @import 'EXT:eventnews/Configuration/TypoScript/constants.typoscript' ``` -------------------------------- ### Display News Item Title Source: https://github.com/georgringer/eventnews/blob/main/Resources/Private/Templates/News/Month.html Displays the title of a news item. Assumes 'newsItem.title' variable is available. ```Fluid {newsItem.title} ``` -------------------------------- ### Format Date for Day of Week Source: https://github.com/georgringer/eventnews/blob/main/Resources/Private/Templates/News/Month.html Formats a date to display the abbreviated day of the week (e.g., 'Mon', 'Tue'). ```Fluid {f:format.date(date: day.ts, format: '%a')} ``` -------------------------------- ### Filter Location ViewHelper Source: https://context7.com/georgringer/eventnews/llms.txt Filters locations to display only those associated with events in the current news list. ```html {namespace events=GeorgRinger\Eventnews\ViewHelpers}

Filter by Location

``` -------------------------------- ### Modify News Month View with PSR-14 Event Source: https://context7.com/georgringer/eventnews/llms.txt Implement an event listener to manipulate assigned view variables and access the controller. Register the listener in your Services.yaml file using the event.listener tag. ```php getAssignedValues(); // Add custom data $assignedValues['customVariable'] = 'My custom value'; $assignedValues['featuredEvents'] = $this->getFeaturedEvents(); // Modify existing data $demand = $assignedValues['demand']; // ... modify demand // Set modified values back $event->setAssignedValues($assignedValues); // Access the controller if needed $controller = $event->getNewsController(); } private function getFeaturedEvents(): array { // Custom logic return []; } } // Register in Services.yaml: // services: // YourVendor\YourExtension\EventListener\ModifyMonthViewEventListener: // tags: // - name: event.listener // identifier: 'your-extension/modify-month-view' // event: GeorgRinger\Eventnews\Event\NewsMonthActionEvent ``` -------------------------------- ### Format Event End Date Source: https://github.com/georgringer/eventnews/blob/main/Resources/Private/Templates/News/Month.html Formats the event's end date to display as 'DD.MM.YYYY'. Ensure 'n.eventEnd' contains a valid date. ```Fluid {f:format.date(date:n.eventEnd,format:'%d.%m.%Y')} ``` === COMPLETE CONTENT === This response contains all available snippets from this library. No additional content exists. Do not make further requests.