def collections(self): """ Returns all collection content with subcollections. """ collections = [ {"id": topic.getId(), "title": topic.Title(), "content": topic.queryCatalog()} for topic in self.sub_topics() if topic.queryCatalog() ] # add main collection collections.append({"id": "main", "title": _("All"), "content": self.results()}) return collections
def title(self): return self.header or _(u"Portlet Shelf")