Replies: 1 comment 3 replies
-
This is currently working as expected so I converted your issue to a discussion. I agree it could make sense to give nested entries the option to have Post/Expiry Date fields, especially since Matrix fields have an Entry URI Format setting – so nested entries could have their own URLs. |
Beta Was this translation helpful? Give feedback.
3 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
-
What happened?
Description
Multiple customers have asked us why the post and expiry dates cannot be set for entries inside matrix fields.
After looking at the code I found that this has been disabled.
Is there a reason why this is the case? Can this be changed?
Steps to reproduce
Expected behavior
The fields should be visible.
In Craft CMS, all entries have a status, a start date, and an end date, therefore, the editor should have the option to set them.
Move this block of code out of the condition:
Code
If enabled, everything works as expected, my entry gets hidden in the frontend after expiration.

Actual behavior
The fields are not visible because of this condition:
code
if ($section && $section->type !== Section::TYPE_SINGLE) {}
Craft CMS version
5.7.4
PHP version
8.2
Operating system and version
No response
Database type and version
No response
Image driver and version
No response
Installed plugins and versions
Beta Was this translation helpful? Give feedback.
All reactions