- 🇯🇴Jordan mqanneh Amman
doesn't work with v2.9 which is a security release.
- Status changed to Needs review
almost 2 years ago 11:37pm 23 January 2023 - 🇯🇴Jordan mqanneh Amman
Rerolled the patch in #182 to work with v2.9
Update: PHP error after applying the patch in #185
TypeError: Cannot access offset of type string on string in Drupal\entity_browser\Plugin\Field\FieldWidget\ListBuilder\TableListBuilder->buildRow() (line 299 of /app/docroot/modules/contrib/entity_browser/src/Plugin/Field/FieldWidget/ListBuilder/TableListBuilder.php)
- 🇳🇱Netherlands idebr
Attached patch implements the following changes:
- Reverted the incorrect changes in #176
- Updated the JavaScript after #3110133: Convert jQuery UI Sortable to new SortableJS library → was committed
- Fixed a few test failures
The last submitted patch, 187: 2973457-187.patch, failed testing. View results →
- Status changed to Needs work
over 1 year ago 10:46pm 20 March 2023 - 🇺🇸United States dabblela
Fixing incompatible method declaration in TableWidget in #187
- Status changed to Needs review
over 1 year ago 1:47pm 21 March 2023 The last submitted patch, 189: 2973457-table_widget-189.patch, failed testing. View results →
- Status changed to Needs work
over 1 year ago 4:59pm 4 April 2023 - 🇺🇸United States agentrickard Georgia (US)
In our testing, the drag and drop functionality works correctly, but turning on "show row weights" and sorting manually does not update the sort order.
I wonder if that is why the patch is failing tests.
- 🇺🇸United States agentrickard Georgia (US)
The wrapping of the delete call inside
$(context).find(".field--widget-entity-browser-table").each(function () {
also breaks the non-table implementation of this form widget. - 🇺🇸United States agentrickard Georgia (US)
Revised patch that corrects comment 193 but not 192.
I do not have patch utils for an interdiff. Here's the change:
// Special handling for the table widget. $(context).find(".field--widget-entity-browser-table").each(function () { var $entitiesList = $(this).find('.entities-list'); $(once('entity-browser-table-widget-drag', $(this).find('table.entities-list .tabledrag-handle'))).on('mouseup pointerup', function () { Drupal.entityBrowserEntityReference.updateTargetId($entitiesList); }); }); // Normal element handling. $(context).find('[data-entity-browser-entities-list] .remove-button').each(function () { $(once('entity-browser-remove', $(this))).on('mousedown', function () { var $currentItems = $(this).parents('[data-entity-browser-entities-list]:first'); $(this).parents('.item-container:first').fadeOut(360, function () { $(this).remove(); Drupal.entityBrowserEntityReference.updateTargetId($currentItems); }); }); // Prevent remove button from triggering a form submit. $(once('entity-browser-remove-mouseup', $(this))).on('click', function (e) { e.preventDefault(); }); });
- last update
over 1 year ago 53 pass, 3 fail - Status changed to Needs review
over 1 year ago 9:08pm 26 April 2023 - 🇺🇸United States agentrickard Georgia (US)
I did some more digging on this patch and found a few things:
* The initial "drag" column should be hidden
* The current dragabble listener isn't standard and does not account for all cases of "dropped"
** It was only letting you drop in the tabledrag cell
** It would not detect a drop if the cursor went beyond the table boundsThe attached fixes this problem (with an interdiff this time).
There may be a better approach to this. What I ended up doing is setting and reading a data attribute in order to target the correct form element.
- last update
over 1 year ago 53 pass, 3 fail - 🇺🇸United States agentrickard Georgia (US)
And the server didn't load the patch file.
The last submitted patch, 196: 2973457-table_widget-195.patch, failed testing. View results →
- last update
over 1 year ago 50 pass, 5 fail - 🇺🇸United States agentrickard Georgia (US)
Fixes an issue where manual weighting fails.
The last submitted patch, 198: 2973457-table_widget-198.patch, failed testing. View results →
- last update
over 1 year ago 53 pass, 3 fail - 🇺🇸United States agentrickard Georgia (US)
Fixes a logic error that is likely also present in FileBrowserWidget.php concerning the delta / weighting of items.
The last submitted patch, 200: 2973457-table_widget-200.patch, failed testing. View results →
- last update
over 1 year ago 53 pass, 3 fail - 🇺🇸United States agentrickard Georgia (US)
Sorting by drag and dop is slightly different than by row weight, so it is much easier to key our rows by entity id rather than using a positional array.
Also catches that the JS uses _weight as a key, not weight.
The last submitted patch, 202: 2973457-table_widget-202.patch, failed testing. View results →
- Status changed to Needs work
over 1 year ago 7:49pm 4 May 2023 - 🇺🇸United States jesss
I just tried to apply patch #202 and while the patch applied cleanly, it didn't seem to do anything -- I still don't have the option to display the selected entities as a table. I believe that's because the updated schema that has the new widget settings isn't imported if the module has already been enabled. I saw there was some discussion upthread about removing an update hook -- that probably needs to be revisited.
- 🇫🇮Finland miikamakarainen
I used the patch in #202 and noticed that displaing the "Published" status as a column was always displayed as "published" regardless of the actual state (Tested on multilingual Drupal 9.5.9).
The check if an entity is published was done against a FieldItemList instead of the boolean value of said key.
- last update
over 1 year ago 50 pass, 5 fail - Status changed to Needs review
8 months ago 9:32am 7 March 2024