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.
references-dialog.js needs various bugfixes and performance improvements:
- variable caching instead of writing the same jQuery statement $(...) multiple times
- missing line endings (;)
- wrong "undefined" comparisons
- context bugfix for $('.' + key + ' a.references-dialog-activate')
Surprisingly, the context bugfix was no problem for jQuery 1.5 (?), even though it's wrong.
But I noticed it was if you're using a higher jQuery version (with for example the jQuery Update module).
Comment | File | Size | Author |
---|---|---|---|
#2 | references_dialog-various_js_bugfixes-1889582-2.patch | 7.13 KB | jover |
Comments
Comment #1
joverPatch will follow...
Comment #2
joverPatched
Comment #3
joverNeeds review...
Issue #1850808: jQuery 1.7.1 incompatability became obsolete with this patch...
Comment #4
rogical CreditAttribution: rogical commentedNice patch, If we can have a test through different versions of jquery, I'll commit this.
Comment #5
jaydub CreditAttribution: jaydub commentedUsing jQuery Update here to run with jQuery 1.7 and w/o this patch the add/edit links did not open a dialog. Applied patch and dialogs work again.
Comment #6
rogical CreditAttribution: rogical commentedissue can be solved here together
#1800806: Wrong arguments for .click()
Comment #7
rwilson0429 CreditAttribution: rwilson0429 commentedPatch in #2 works well for me.
Prior to patching, when using jQuery Update to run jQuery 1.7, could not select a reference from a View's Reference Dialog Display by clicking on it. Switching back to jQuery 1.5, clicking a reference from a View Reference Dialog display worked fine.
After applying the patch in #2, I reverted back to jQuery 1.7 and clicking on a reference from a View Reeference Dialog Display worked as expected (the clicked reference was placed on the input form). I also tested with jQuery 1.5 using this patch and it continued to function as expected.
Thanks for the patch.
Comment #8
MXTI can confirm that patch in #2 resolve issues with jQuery 1.7.
Thank you!
Comment #9
bennos CreditAttribution: bennos commentedWorks with jquery 1.7.
2 confirmations. think we can set it "RTBC"
Comment #10
MXTCan this be committed please?
Comment #11
rogical CreditAttribution: rogical commenteddone.