Hardcoded 'article' bundle type in addLink prevents double-click event creation for other content types

Created on 1 November 2025, 6 days ago

Problem/Motivation

The double-click feature doesn't work when using content types other than 'article'.

I found the issue in FullCalendar.php line 328 where it's hardcoded to 'article' instead of using the bundle_type setting.

Steps to reproduce

1. Create a content type called 'event' (not article)
2. Make a calendar view using that content type
3. Enable the option to add events directly to calendar
4. Try to double-click on a date

Nothing happens because addLink stays undefined.

Proposed resolution

Change line 328 in src/Plugin/views/style/FullCalendar.php from:

if ($this->accessManager->checkNamedRoute('node.add', ['node_type' => 'article'])) {

to:

if ($this->accessManager->checkNamedRoute('node.add', ['node_type' => $settings['bundle_type']])) {

I tested this fix with 'event' and 'appointment' content types and it works great.

🐛 Bug report
Status

Active

Version

3.0

Component

Code

Created by

🇩🇪Germany laborheld

Live updates comments and jobs are added and updated live.
Sign in to follow issues

Comments & Activities

Not all content is available!

It's likely this issue predates Contrib.social: some issue and comment data are missing.

No activities found.

Production build 0.71.5 2024