When chossing 'unlimited' number of widgets the "Add another item" button is not working. This is due to the inflexible id transfer of the widget hooks and the js file.
| Comment | File | Size | Author |
|---|---|---|---|
| #3 | nodereference_explorer-get_item-added.patch | 1.44 KB | Anonymous (not verified) |
| #2 | nodereference_explorer-get_item-added.patch | 2.74 KB | Anonymous (not verified) |
Comments
Comment #1
andribas commentedI've got
warning: Illegal offset type in /var/www/drupal.uralpress.ru/sites/all/modules/nodereference_explorer/includes/nodereference_explorer.views.class.inc on line 53.
the same case - unlimited number. (Not required field)
Although, item appeared.
Comment #2
Anonymous (not verified) commentedThis is going to be a complex problem to solve, but the initial error (described by andribas in #1) is that get_item is getting an array but assumes it is a scalar. This patch fixes the function to take an array or a scalar.
Comment #3
Anonymous (not verified) commentedThat patch was more than I needed to give. It contained also the previous patches I've submitted today. Here's the patch for this issue by itself.
Comment #4
dags88 commentedsubscribe
Comment #5
gnindl commentedThe version 1.1-beta2 offers basic support for this. Playing around (adding and removing) is still under development.
Comment #6
gnindl commentedIn 1.1-beta2 a JavaScript behavior populated JS Drupal settings that created all buttons and their actions. When processing "add another item" setting values were assigned multiple times, i. e. transforming setting value from objects to arrays => JS s.url error.
The buttons are now prerendered server-side and JavaScript wrapper getSettings() function cares about this multiple assignment.
Comment #7
gnindl commentedCheck out the current development snapshot for testing.
Comment #8
gnindl commentedWorks for nodereference explorer widget, not for link field type (reengineer in next releases)