7913 Posts in 1355 Topics by 930 members
DataObjectManager Module
SilverStripe Forums » DataObjectManager Module » add_sortable_classes not having any effect
Discuss the DataObjectManager module, and the related ImageGallery module.
Moderators: martimiz, UncleCheese, Howard, Sean, Ryan M., biapar, Willr, Ingo, swaiba, simon_w
| Go to End | Next > | |
| Author | Topic: | 1723 Views |
-
add_sortable_classes not having any effect

27 February 2010 at 3:52pm
Hi Guys
I'm upgrading one of my client sites from 2.3.2 to 2.3.6 and while I have sortable classes declared in my _config.php, the ManyManyDataObjectManagers that I have in the CMS no longer display "Allow drag & drop reordering" checkbox in the bottom left, rather just a "Show related records" checkbox instead.
I can see in the template a check for <% if Sortable %> but it appears to not eval to true - hence my missing checkbox.
This was one of the issues I was also having with implementing DOM in a 2.4b site, which until now I had written off to 2.4 incompatibility. For this site though it has been a straight upgrade from 2.3.2 to 2.3.6, I've not changed a line of any of my code.
I've given the forums a good once/twice over but couldn't find threads dealing with a similar issue. Please help!
FYI the snippet from _config.php looks like this:
SortableDataObject::add_sortable_classes(array('PodItem','FeatureItem','TeamMember'));
-
Re: add_sortable_classes not having any effect

27 February 2010 at 5:21pm
Ah. Bugger. I just realised I did upgrade DOM too. The download of DOM I'm having this issue with is the current download on the modules page, r374.
-
Re: add_sortable_classes not having any effect

27 February 2010 at 5:59pm
The demo site http://dataobjectmanager.carlinowebdesign.com is always running the latest DOM on the latest version of SS. I'm not seeing the issue there.
-
Re: add_sortable_classes not having any effect

27 February 2010 at 6:13pm
Dang.
Should the 'New MMFDOMTest', 'Random' or 'Glossary' pages ManyManyDOMs have sorting? If so, they're not showing, for me at least, I can attach sshots.. If not, would you mind adding one of them to the sortable classes? I can see it working on the Image Gallery though.
-
Re: add_sortable_classes not having any effect

28 February 2010 at 3:03am
Oh, I hadn't noticed you were using an MMDOM. The many_many sorting will not be available until 2.4. It worked in 2.3.3, but then changes to Object.php broke it. See ticket here:
-
Re: add_sortable_classes not having any effect

1 March 2010 at 4:57pm
Ah - righteo then. Thanks for getting back to me UC. Looks like I'm really looking forward to / hanging out for 2.4 and it's associated DOM update!!
-
Re: add_sortable_classes not having any effect

15 April 2010 at 12:41pm
Any news about the fix for this bug?
I think I'm experiencing the same problem with ss2.4rc1 and the trunk version of DOM.With the older ss (2.3.5) and DOM, I was able to use simple add_sortable_class in order to allow a user to drag&drop with ManyManyDataObjectManager. Now as I see, there's a new feature add_sortable_many_many_relation which works fine, but it's not what I need. With add_sortable_class I was able to make one sorting order for my DataObject items, referenced in all Pages allowing to select from those items (sorry for the lack of terminology but I'm still not used to SS names).
Sorting with drag&drop was quite useful feature, now my users have to manually set up SortOrder for each item...
-
Re: add_sortable_classes not having any effect

15 April 2010 at 12:51pm
I'm not aware of this bug. You're saying standard (non-many_many) sortable objects are not sorting? Does the drag and drop appear and does it work? Or is it just not updating the record in the database?
| 1723 Views | ||
| Go to Top | Next > |


