Term Reference Tree: Re-implement Track List (Allow field term value sorting/ordering)

Created on 26 June 2019, about 5 years ago
Updated 23 May 2024, about 1 month ago

This patch brings back Track List but in ajax: It gives us a functional widget to drag-sort terms within a field value!

Example:

@bachbach resurrected this from the 7.x to the 8.x port. Remnants of D7 were still in there, and there's still a lot of cleanup opportunity.

@bachbach's original comment here:
Hi,
as i needed it for a project, i reimplemented the track_list feature in drupal 8.
I took a other approche than D7 module as i used drupal builtin ajax possibilities to refresh the tracklist.
I worked on :
# Information added by Drupal.org packaging script on 2019-06-21
version: '8.x-1.0-alpha2+15-dev'
core: '8.x'
project: 'term_reference_tree'
datestamp: 1561103289

what do you think ?
here is the patch

✨ Feature request
Status

Needs review

Version

1.1

Component

Code

Created by

πŸ‡«πŸ‡·France bachbach Le Havre

Live updates comments and jobs are added and updated live.
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.

  • πŸ‡ΊπŸ‡ΈUnited States troybthompson

    Has anyone been able to get this to work in D10? I really miss this feature for my site with 1000+ terms.

  • πŸ‡ΊπŸ‡ΈUnited States sidgrafix

    @troybthompson

    - I personally gave up on this feature from the patch provided and just wrote some simple jQuery as some Drupal.behaviors in a custom theme or module (can't remember which exactly at the moment) to build my own track list for use taking selected terms when editing or adding content that uses a specific term list plus a few extras specific to it's use case.

    I'd be happy to share some code but it's tailored for the site it is used on (so you may have to translate some of the selectors to more generic element classes - output specifically by term reference tree should you want to use it on any term reference tree) if that makes sense...

    It also doesn't rely on ajax to communicate back and forth from the term reference tree and the tracklist (but you have to save the content for any changes in the tracklist to stay - because it doesn't rely on ajax). Which based on what I remember ajax was a big part of the problem with the patch listed here for the feature. I figured someday I might be able to get around to modifying what I have and applying as an alternative patch here - but I just haven't had the time...and other than sharing what I put together, I still don't.

    But if your interested let me know..

  • πŸ‡ΊπŸ‡ΈUnited States troybthompson

    Thank you for the detailed information. I don't think I'm technical enough to do that but I appreciate your response.

Production build 0.69.0 2024