Active
Project:
Calendar
Version:
8.x-2.x-dev
Component:
Code
Priority:
Normal
Category:
Support request
Assigned:
Unassigned
Reporter:
Created:
6 Aug 2020 at 17:37 UTC
Updated:
7 Jun 2022 at 12:27 UTC
Jump to comment: Most recent
Our reservation/calendaring system is built around a custom "reservation" entity instead of a node/content entity. Is it possible to get the module to work with a custom entity?
Right now, when I try to follow the usage instructions, I get errors saying "InvalidArgumentException: Field title is unknown", which I assume is because the base field on the entity is "name" instead of "title".
Comments
Comment #2
solide-echt commentedApologies for replying late. In principle there's nothing preventing us from using calendar for custom entities, provided the entity supports views integration (e.g. extend EntityViewsData) to start with. It's not high on my priority list though - as you probably figured out already. I've just finished a rather complicated project - meaning ambition and budget were somewhat misaligned :-) - so hope to spend some dedicated time on calendar in the coming weeks. Stay tuned...
Comment #3
jwineichen commentedAmbition/budget misalignment; has that ever not happened?
Completely understand about priorities. I assume the vast majority of Calendar users are working with node entities and not custom ones.
I was able to cobble together a calendar-like view by grouping by date and then writing out a VERY elaborate series of Grid CSS rules. It's nowhere close to perfect (gotta work with the tools/skills you have) and getting this module to work would be way better, but it's at least mostly functional until that time hopefully comes.
Comment #4
dunot commentedGet the issue for standart node on Drupal core 9.3.13.
InvalidArgumentException: Field is unknown. in Drupal\Core\Entity\ContentEntityBase->getTranslatedField()Views cont. filter is created_year