Jump to:

23001 Posts in 11702 Topics by 2827 members

General Questions

SilverStripe Forums » General Questions » 2.4 Many_Many Sort Order + Drag and Drop

General questions about getting started with SilverStripe that don't fit in any of the categories above.

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

Page: 1
Go to End
Author Topic: 220 Views
  • lozhowlett
    Avatar
    Community Member
    140 Posts

    2.4 Many_Many Sort Order + Drag and Drop Link to this post

    Hi All

    We have a site on 2.4 and the client requires the ability to sort order products within categories using drag and drop.

    Products....

    //Relate to the category pages
       static $belongs_many_many = array(
          'Categories' => 'CategoryPage'
       );

    Category....

    static $many_many = array(
    'Products' => 'Product'
    );

    I cant think of a way to add in drag and drop sort order on this, fine with one-to-many, but not sure there is a way to do this in 2.4?

    Any help would be great, thanks.

  • Devlin
    Avatar
    Community Member
    186 Posts

    Re: 2.4 Many_Many Sort Order + Drag and Drop Link to this post

    I think Uncle Cheese's ManyManyDataObjectManager has a dynamic sort method with a drag and drop feature. Dunno how well it works, but maybe you give it try.

    220 Views
Page: 1
Go to Top

Want to know more about the company that brought you SilverStripe? Then check out SilverStripe.com

Comments on this website? Please give feedback.