Entity edit form title is empty when entity type is translatable and has no title field

Created on 17 June 2021, about 3 years ago
Updated 12 January 2024, 6 months ago

Problem/Motivation

Drupal\content_translation\ContentTranslationHandler::entityFormTitle uses $entity->label() to build the page title. If your eck entity does not have a title, this returns an empty string, which empties the page title.

Steps to reproduce

  1. Install `eck`, `content_translation`
  2. Create a translatable eck entity type without title field
  3. Visit the entity add/edit form

Proposed resolution

Node overrides the Drupal\content_translation\ContentTranslationHandler::entityFormTitle method and uses the entity bundle label to build the title. We could copy the node behaviour.

🐛 Bug report
Status

Fixed

Version

2.0

Component

Code

Created by

🇧🇪Belgium DieterHolvoet Brussels

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

Merge Requests

Comments & Activities

Not all content is available!

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

Production build 0.69.0 2024