I'm use Embedded widget with two fields in my Field Collection. I'm create node and fill Field Collection fields. After save node, I'm click Node Edit button and see crashed form (JavaScript don't work properly)

P.S. Sorry for bad English


Interesting -- I just ran into exactly the same issue, using Field Collection 7.x-1.0-beta2. Any help here would be appreciated.

Javascript error I'm seeing in Chrome:

Uncaught TypeError: Cannot read property 'colSpan' of undefined. tabledrag.js:152

Anybody can help solve this problem?

I'm hitting the same problem (using the latest dev from Nov. 15th). In Chrome, I am getting these errors:
"Uncaught TypeError: Cannot read property 'colSpan' of undefined
Uncaught TypeError: Cannot read property 'className' of undefined"

From tabledrag.js:149

All other modules and core are updated and seem to be working fine.


Thanks for the lead here : http://drupal.org/node/1327066, I have a dirty hack for the tabledrag.js that seems to work. It basically just removes the table for the embedded field collection from inspection by JS. Replace line 128 from:

var cell = field.parents('td:first');

var cell = field.parents('td:first:not(.field-widget-field-collection-embed td)');

Obviously this is not a good fix, but it keeps me moving down the road while under a deadline!

Confirmed. Definitely a bug. Happens to me too. It breaks any entity form that employs Field Collections and collapsible fieldsets. It also happens if the widget type is Table.

Chrome 17, Drupal 7.10, FC 7.x-1.0-beta3

Is there a way to intercept tabledrag.js actions with jQuery and insert that exception other than hacking core?

Following up with #4, you also need to do this for the other FC edit methods:

var cell = field.parents('td:first:not(.field-widget-field-collection-hidden td)');
var cell = field.parents('td:first:not(.field-widget-field-collection-embed td)');
var cell = field.parents('td:first:not(.field-widget-field-collection-table td)');

But you can simplify it for Field Collection by just adding this instead:

var cell = field.parents('td:first:not(.field-type-field-collection td)');

There must be some way to affect this with an external jQuery script without touching core.

The other problem here too, is that row weights are shown without having to click 'Show Row Weights'- which has no effect on FC tables edits.

Priority:Critical» Normal
Status:Active» Postponed (maintainer needs more info)

Can someone provide an export of their content type with Features and attach it here?

Is this something that was never resolved or committed?

I'm still having this issue as well. Focus Field Crop, expanding javascript widgets, etc are all broken. It seems any javascript held inside of the Field Collection is disabled....anyone?


comment this lines in file:

          if (cell[0].colSpan && cell[0].colSpan > 1) {
            // If this cell has a colspan, mark it so we can reduce the colspan.
          else {
            // Mark this cell so we can hide it.

sorry for hacking core... very sorry...

DIRTY HACK #4 (2011) not working for me now