cms
cms copied to clipboard
[5.x]: Entry author field is not pre-populated with current user when `Show the Title field` is disabled and the `Title Format` contains dynamic output in an entry type
What happened?
Description
If an entry type is set to hide the title field, and the title format is set to something that's not a plain string, e.g. {section.name|raw}
, when you create a new entry in a section using that entry type, the author field is not pre-populated and thus causes validation errors when trying to save.
Steps to reproduce
- Create a new entry type with
show the title field
toggled off - Set the title format for this entry type to
{section.name|raw}
or something else that dynamically generates a value - Save the entry type
- Create a new section
- Set the type to channel or structure
- Associate your entry type to the section
- Save section
- Create a new entry in this section
- You should see the author field not pre-populate with your user account
Expected behavior
The author field is pre-populated as it is when using the normal title field
Actual behavior
The author field is empty
Craft CMS version
5.0.0-beta.2
PHP version
8.2.15
Operating system and version
Linux 6.6.12-linuxkit
Database type and version
MySQL 8.0.30
Image driver and version
Imagick 3.7.0 (ImageMagick 7.1.1-13)
Installed plugins and versions
No response