Merged the topics and items in topic_view.html into a single list

As requested, the descendant topics and direct items will now appear in the same list in topic_view.html, with the outer level (of both topics and items) sorted according to order_index.
As part of these changes, I moved the two functions in utils.py that work on models, into methods on the models.