With some tables more then one fields is need for the key, otherwise, there is collision on the exported data. I have attached a patch that adds a function ctools_export_key which test if the key is an array and if so generates a key from it instead of just a simple string.
I have also replace the instances of $object->{$export['key']} with ctools_export_key($object,$export['key']).
I have attached the patch please let me know if there area any issue with adding this functionality, or anything you would want changed.
Thanks
| Comment | File | Size | Author |
|---|---|---|---|
| #2 | 660786.patch | 4.44 KB | e2thex |
| export_key_as_array.patch | 4.7 KB | e2thex |
Comments
Comment #1
merlinofchaos commentedSetting proper status so this shows up in the needs review queue (making it much more likely to be seen by people who want to review patches! =)
Comment #2
e2thex commentedI clean up the patch a bit
Comment #3
e2thex commentedI would now recommend not doing this, as other modules have started to use that data. And it complicates this some.
Comment #4
merlinofchaos commentedCan you explain a little more? I'm having a little trouble following.
Comment #5
raphael waeselynck commentedHI everybody, I'm looking for using ctool export intergration patch to export noderelationships with feature... but it uses this patch, so if you recommend not to use it now, it's a bit confusing.
Could you be more precise ?
Comment #6
e2thex commentedWe have a new patch for noderelationships look at the #660958: ctools export intergration (features support). That works with out this patch to ctools.
Comment #7
merlinofchaos commentede2thex: Ok, based on your retraction, switching to won't fix. Feel free to tell me I'm wrong. =)