No title sort for Entity Reference fields

Created on 26 September 2015, over 9 years ago
Updated 4 August 2024, 5 months ago

Problem/Motivation

I created a field referencing content (formerly called Entity Reference). In the "sort by" selection box, neither "Title" nor the name I had used as override for "Title" (which was "City") appeared in the list.

Strangely enough, I saw the names of overridden title fields for other content types, just not for the content type I was referencing in that case.

Summary Update:
Steps to reproduce:

  • Create some content types
  • Update the title field label from 'Title' to something else (in all content types including Article and Page).
  • Add an entity reference field to any content type, the sort by select list won't have the 'Title' option.

The title field is being shared between content types, at least in the entity reference Sort By select list.
So if the title field label is updated in one or more content types, then chances are that the Sort By select list displays one of the updated labels instead of 'Title'.

So imagine the next scenario w/only two content types:

  • Content type one set its title field label to 'title one'
  • Content type two set its title field label to 'title two'
  • Add an entity reference field to content type one pointing to content type two, and try to sort by title.

The sort by title select list won't display the 'Title' option, instead it would display 'title one' or 'title two' (but only one of those). So if you want to sort the entity reference field pointing to content type two by title, and neither 'Title' or 'title two' are on the Sort By select list it can be confusing.
How are you going to know that the option to select is 'title one' because that corresponds to the title field? In this scenario w/two content types is easy to figure out, but imagine multiple content types and even worst more than one person working in the same project.

Solution Suggested:
For consistency always display 'Title' as an option in the Sort By reference select list instead of any custom title field label.

Steps to reproduce

Proposed resolution

Remaining tasks

User interface changes

Introduced terminology

API changes

Data model changes

Release notes snippet

πŸ› Bug report
Status

Active

Version

11.0 πŸ”₯

Component
FieldΒ  β†’

Last updated 2 days ago

Created by

πŸ‡ΊπŸ‡ΈUnited States ExTexan

Live updates comments and jobs are added and updated live.
  • Needs issue summary update

    Issue summaries save everyone time if they are kept up-to-date. See Update issue summary task instructions.

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.

Production build 0.71.5 2024