Support for Drupal 7 is ending on 5 January 2025—it’s time to migrate to Drupal 10! Learn about the many benefits of Drupal 10 and find migration tools in our resource center.
I'm not sure if this is a bug report or a feature request.
I was having trouble with a site that used nodequeue and chosen (http://drupal.org/project/chosen) .
Chosen was adding div elements with the 'node-position' class, which confused nodequeueUpdateNodePositions in nodequeue_dragdrop.js
This was causing duplicate positions on submit of the ordering form.
I fixed this by changing the selectors in the function to only operate on (and count) select form elements.
I'll attach a patch below.
It might be worth having a look at this to commit, to avoid conflicts with other DOM manipulating modules.
Comment | File | Size | Author |
---|---|---|---|
#2 | nodequeue_select_js-2098049-2.patch | 2.66 KB | mfb |
#1 | nodequeue_select_js-2098049-1.patch | 781 bytes | tripper54 |
Comments
Comment #1
tripper54 CreditAttribution: tripper54 commentedPatch attached.
Comment #2
mfbAlso running into this myself. Another idea would be to change the class to a properly name-spaced class: nodequeue-position rather than node-position.
Comment #3
tripper54 CreditAttribution: tripper54 commentedNamespacing the class is a good idea, but I'm not sure it would help with my problem. I think chosen is creating its own div tags based on select form elements on the page, and duplicating the classes.
Comment #4
mfbAh yes you are correct, my patch did not seem to help :)
Comment #5
vildechaya CreditAttribution: vildechaya commented#1 worked perfectly for me, with the same Chosen/Nodequeue conflict.
Comment #6
fizk CreditAttribution: fizk commentedThis ended up being fixed in #44017: Node Queue position duplication can cause accidental deletion of queue entries.