Closed (fixed)
Project:
Weight
Version:
7.x-2.2
Component:
Code
Priority:
Normal
Category:
Bug report
Assigned:
Unassigned
Reporter:
Created:
10 Feb 2013 at 20:21 UTC
Updated:
25 Feb 2013 at 22:30 UTC
Displaying a Weight field in a table view allows users to arrange the rows using Drupal's tableDrag JavaScript plugin. However, if the view is configured with a grouping field, the view is split into multiple tables, and the Weight module incorrectly gives each table the same DOM ID.
This causes at least two issues:
The problem appears to be caused by weight_preprocess_views_view_table(), which uses the same DOM ID every time it is called.
The attached patch changes weight_preprocess_views_view_table() to append the view's "id" variable to each DOM ID, making them unique. With this patch in place, draggable table views work as expected even when jQuery Update is enabled.
| Comment | File | Size | Author |
|---|---|---|---|
| weight-duplicate_dom_ids.patch | 627 bytes | eromba |
Comments
Comment #1
davisbenCommitted, thanks for the patch!