Asset list in tree order


(Anthony) #1

Normally for an asset listing I want a specific sort by date, or name etc. But for the first time in ages, today I wanted a list that stuck to the order items appear in the asset tree. There's no metadata or other attribute that can define the order, its something only the person managing those assets will know, and i figure its easy to tell them to just drag them into the order they want.

 

I assumed the "no sorting" option would do the job nicely. After some investigation it turns out that only works if the option to select only direct links is enabled. Set it and it works fine.

 

But does anyone know why? It seems an odd restriction - in this instance I was able to flatten out my structure and put all the items at one level but thats not always possible.

 

If handling multiple levels the only complexity I can think of is whether the list would do a pre-order or post-order traversal of the tree. In most cases I suspect pre-order would be the most useful (ie list the parent then its children)

 

Anyone got any thoughts / workaround? Or perhaps it deserves an enhancement request?


(Nic Hubbard) #2

Anyone got any thoughts / workaround? Or perhaps it deserves an enhancement request?

 

I think the reasoning was a performance issue. At least that is what I understood.

 

If you want to do multiple levels you can easily do so using the list_current_asset_id feature:

 


(Anthony) #3

Thanks Nic. Actually list_current_asset_id is already part of the workaround I've now put in place, so I'm good with that.

 

It would be handy to have an enahncement that offered an explicit "sort in asset map order" option on the sort screen, but I'd have to admit its pretty un-critical so I'll just leave the thought here in case anyone else wants to pick it up.

 

What might be helpful is a bit of static text on the asset sorting screen that says something like "To sort in asset map order you must set direct links only on the details screen" cos it's not something that many newbies would figure out quickly!


(Robin Shi) #4

have you tried sitemap asset?