DownloadPHP 7.4PHP 8Joomla 3.10Joomla 4.4Joomla 5
The Create Event menu item shows an event creation form allowing permitted users to create events from the frontend of your Joomla calendar. If the logged in user has no edit state rights, the events must be approved and published by an administrator.
One of the most important features is the series definition, where the author can define a recurring pattern for events. All these instances will be then copies of the original event. If an original event of a series is edited and some instances have been manipulated individually, a popup is shown which asks you if you want overwrite these changes. When denied, then only the instances which are identical to the original event are overwritten with the data from the original event. More about series can be found in the Event Management article.
If you create a new event and start typing the title a drop down list is displayed with events which do have a similar title. If the author clicks then on such an entry, then the page is loaded with the values from that event. It is basically an instant copy feature.
It is possible to activate an overlapping check in the event form options. If this option is activated, every time when the date is changed of the event a check is done if there is another event in the same calendar within the same time range. When an existing event ends on the start time in the form, then it is possible to create an event, as the overlapping check is exclusive. If there is one a warning is displayed. Additionally you can set the parameter to "Disabled save" which deactivates the save buttons.
If the check is enabled you have also the option to include location and room checks, means it checks additionally if the location and rooms of the events do overlap.
You can define a list of colors in the DPCalendar options for event editing. This means that users can choose from a fixed list of colors while manipulating an event. It is then not possible anymore to choose another color.
When there is a need to change the order of the fields for the event form, then use the flat mode setting in the DPCalendar options in the event form tab. Once enabled, there are no event tabs displayed in the front form and a subform appears below the setting in the configuration to define the order of the fields.
This setting works only for the front end and allows the admin to create simple forms for the average user without any complex attributes. With different menu items it is also possible to show different forms then for different user groups, like that power users can have more settings available.
It is possible to disable fields or whole tabs that they will not be visible for the user who is editing an event. These settings can be controlled in the menu item or global DPCalendar options and are ignored on the back end as there should be all fields and tabs visible. It allows the admin to create very simple front end forms together with the flat mode.
The author field is an user list. In the back end it opens the user list view. On the front this view is not available so the raw user list is displayed. To achieve that you have to create a layout override by coping the file /components/com_dpcalendar/layouts/form/author.php to /templates/{{your template}}/html/layouts/com_dpcalendar/form/author.php. For example when you want to use a specific custom field, then you can use the following query (replace 33 with the ID of your specific custom field):
<?phpdefined('_JEXEC') or die();echo "select u.id as value, concat(ifnull(f.value, ''), ' ', u.name) as text from #__users u left join #__fields_values f on u.id = f.item_id and f.field_id = 33 union all select '', '' order by text";
An event can be attached to multiple locations. If the locations have also rooms, then you can assign the event to a specific room of the selected locations.
The location lookup field offers the possibility to create new locations on the fly. If a location doesn't exist, the author can search in the maps provider database for the location and assign it to the event. When saving the event, the location will be created then automatically in DPCalendar.
In the global DPCalendar options in the event form tab can almost every field be defaulted. Like that it is possible to define the default calendar or color when the form is opened. These values can be overridden in every menu item.
It is also possible to prefill the event form with get parameters in the url. Like that can links be created with prefilled values. For example, when a system is able to create emails with links which do open the event form, it can append parameters to prefill existing fields. The following example prefills the title and description field: /index.php?option=com_dpcalendar&view=form&layout=edit&e_id=44&Itemid=141&jform\[title\]=test+title&jform\[description\]=test+description
Keep in mind that the url arguments must be encoded.
The settings can be configured globally in the DPCalendar options or per menu item. If the value is empty in the menu item, then it will be inherited from the global options.
Comments (0)