This is another followup to #3040236: Turn default entity ID field into an autocomplete, which turned the "Default entity ID" textfield into an autocomplete field.
However, if there are only few entities or if Javascript is turned off, a dropdown would be nicer.
This ain't more than a nice-to-have cream topping though, which we would probably only implement if anyone asks for it.

Support from Acquia helps fund testing for Drupal Acquia logo

Comments

Pancho created an issue. See original summary.

Pancho’s picture

Category: Feature request » Task
Status: Active » Needs review
FileSize
13.72 KB

Here's a patch that displays a select unless there are more than 25 referenceable entities in which case it turns into an autocomplete.

Pancho’s picture

  • Pancho committed 9ea8029 on 8.x-4.x
    Issue #3047921 by Pancho: Turn default entity ID field into a select if...
Pancho’s picture

Title: Turn default entity ID field into select for few entries or non-JS » Turn default entity ID field into a select if no more than 25 entries
Status: Needs review » Fixed

Left the non-JS case out for now.

Status: Fixed » Closed (fixed)

Automatically closed - issue fixed for 2 weeks with no activity.