Skip to main content

This site requires you to update your browser. Your browsing experience maybe affected by not having the most up to date version.

DataObjectManager Module

Discuss the DataObjectManager module, and the related ImageGallery module.

Moderators: martimiz, UncleCheese, Sean, biapar, Willr, Ingo, swaiba, simon_w

Sorting in NestedDataObjectManager


Reply

5 Posts   991 Views

Avatar
NickJacobs

9 November 2009 at 4:31pm Community Member, 144 Posts

Hi, I've got an ImageDataObjectManager nested in a DOM, but just can't get the images to display in created order (or any specified order for that matter) and cannot get drag&drop on those images either....any ideas out there?

Avatar
UncleCheese

9 November 2009 at 4:52pm 4085 Posts

Can you post the code you're using? What do you mean when you say drag-and-drop isn't working?

Avatar
NickJacobs

9 November 2009 at 4:55pm Community Member, 144 Posts

sorry, sorted it out just after I posted that one. Stupid mistake in my _config file that was stuffing it up.

For the record tho....what is the correct way to specify mulitple sortable classes in _config??

Avatar
UncleCheese

9 November 2009 at 5:34pm 4085 Posts

SortableDataObject::add_sortable_classes(array('Class1','Class2'));

Avatar
NickJacobs

9 November 2009 at 5:42pm Community Member, 144 Posts

Yep, that explains it, thanks UC :)

I was trying to do:
SortableDataObject::add_sortable_class('Class1','Class2');
and then dropped back to :

SortableDataObject::add_sortable_class('Class1');
SortableDataObject::add_sortable_class('Class2');

which worked....but not as elegant a solution