What are the links? Are they related to the category, the document,
neither or both?
I would create category. I'd establish a relationship between category
and document. I'd pass my category list to the template, then loop
through the categories and each categories documents with something
like (note: just pseudo-code):
{% for category in category_list %}
{{category }}
{% for document in category.document_set.all() %}
{{document}}
{% endfor %}
{% endfor %}
Now, if the links are related to the category, I'd establish a
relationship there, too, and you should be able to get them much like
the documents. If they're not, then you've probably got one of two
situations
Either category AND links are related to some unnamed super-topic. In
that case, everything I said goes out the window, cause you'd probably
want to start at the super-topic and drill down from there.
OR
They're wholly unrelated, in which case I'd probably make them a
template tag I could use all over the place.
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups
"Django users" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to [EMAIL PROTECTED]
For more options, visit this group at
http://groups.google.com/group/django-users?hl=en
-~----------~----~----~----~------~----~------~--~---