Problem/Motivation

In user testing we performed with several colleagues, we found that the entity autocomplete form widget for providing term values for multi-value term reference fields was not very intuitive. This was likely because we don't use that widget in our large Drupal distribution anywhere else. Instead, we use multi-value select fields, and typically enhance them with a JS widget like Select2 or Chosen.

Steps to reproduce

Proposed resolution

Provide a config option to control what widget type is used for multi-value term reference field assignments.

Remaining tasks

User interface changes

API changes

Data model changes

Command icon Show commands

Start within a Git clone of the project using the version control instructions.

Or, if you do not have SSH keys set up on git.drupalcode.org:

Comments

bkosborne created an issue. See original summary.

bkosborne’s picture

Status: Active » Needs review

Ready for review.

Since the autocomplete widget and the multi-value select widget submit form values differently, I had to update our form submit handler to normalize the results, but I think it resulted in more readable code anyway.

fjgarlin’s picture

Status: Needs review » Reviewed & tested by the community

I agree that the new code is more readable. I guess that was a nice side effect of adding the extra widget.

Thanks for the additional test.
- Multiselect widget: https://project.pages.drupalcode.org/-/bulk_edit_terms/-/jobs/5925242/ar...
- Autocomplete widget: https://project.pages.drupalcode.org/-/bulk_edit_terms/-/jobs/5925242/ar...

As the tests are working with the two previous choices, I am marking this RTBC. Thanks!!

PS: what do you think about adding tugboat previews for this module? This can go on a separate issue and it'd be as easy as adding one file to the repo (actually two, because it'll need a composer.json file too). Info and example. This will give us a live environment where we can test manually as well (in addition to the tests).

  • bkosborne committed b8e271ad on 2.x
    Issue #3536405: Support multi-value select for term assignment instead...
bkosborne’s picture

Status: Reviewed & tested by the community » Fixed
bkosborne’s picture

Thanks!

Yes, adding Tugboat previews would be great. We use tugboat quite at bit at my work. If you create the issue I can work on it.

fjgarlin’s picture

bkosborne’s picture

Title: Support multi-value select for term assignment instead of autocomplete » Support multi-value select for term assignment as an alternative to the autocomplete input

Status: Fixed » Closed (fixed)

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