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.

Customising the CMS

ModelAdmin & Hierarchy, possible?


2 Posts   483 Views


5 January 2012 at 12:32am (Last edited: 5 January 2012 12:43am), Community Member, 11 Posts


I have a query about implementing SiteTree-like hierarchy in ModelAdmin.

First of all, is it possible? I need to manage my objects, with categories (and an indefinite number of sub categories) in ModelAdmin. Ideally, I'd like basically another SiteTree in another tab, to avoid the clutter of the other pages.



5 January 2012 at 1:02am Forum Moderator, 1796 Posts

It is possible, I used to have a systen that used the sitetreeasUL functions and created one from data objects. But I replaced it with modeladmin (as it was hacky and tons of code).

SS3 will be using jstree and it looks very simple to create a tree from a dataobject set...

This could show the dataobjects found by the search as the root nodes,
clicking on the icon brings up the normal edit form and clicking on
the pluss opens up the "child" or relating objects.
It would need...
*icon (as you say)
*function getTreeNodeName
*a way to indicate relationships not to follow (in other words "sink"