Jump to:

5540 Posts in 1738 Topics by 1224 members

Customising the CMS

SilverStripe Forums » Customising the CMS » Modeladmin: Keep table sort order after popup close

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

Page: 1
Go to End
Author Topic: 1184 Views
  • Matze0681
    Avatar
    Community Member
    25 Posts

    Modeladmin: Keep table sort order after popup close Link to this post

    hi everybody,

    i need to keep the sort order from a complextablefield in modeladmin after i closed the Edit/Show/... Popup from the selected Dataobject.
    i have for example a real long list of dates in a complextablefield. and sort ASC. Now if i open the edit / show popup to edit or just see the object and close it again the complextablefield will be refreshed automaticly to the default sort order.

    Can i somehow override that ? (Keep the sortorder, but refresh the DataObjects if something changes)

    thanks in advance for any clue

    matze

  • swaiba
    Avatar
    Forum Moderator
    1792 Posts

    Re: Modeladmin: Keep table sort order after popup close Link to this post

    Hi best I could advise to to set a default sort for that dataobject... that will help a sort order persist...

    static $default_sort = 'ID DESC';

    1184 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.