views:

587

answers:

1

Why is there no built-in tree view in the Python Django framework? Isn't there an easy way to visualize a model when a class has an 1:n relation to itself?

I know about some fancy google code projects to achieve that but I think there must be some common sense among the Django community to handle this common case. Any ideas?

+1  A: 

The core devs are pretty strongly against adding extra stuff to Django unless there's a clear universal requirement - especially if there are perfectly good third-party projects that provide this functionality.

This is absolutely the case with tree views. It's very far from something that everyone wants to do, and there are at least three projects that provide trees, including the relevant tools to build representations of the trees in views and the admin.

I suggest you look into them - my favourite is django-mptt.

Daniel Roseman