Birth of a comment 12.28.2006
I’ve started the initial framework for my own commenting system. I have the models set up, with the correct
ForeignKey relations between my Entry and Comment classes.
Here’s a shot of the current admin front page:
And in the admin section for comments, with the ForeignKey relation correctly retrieving parent post title:
I had to wrap the ForeignKey information retrieval in another function to tel Django to not allow sorting based on that column. Otherwise, even though Django pulls in the str method for the ForeignKey object in the model, it doesn’t know that it can’t sort on it. When you try, it’ll return an error.
But in any case, all of this took less than half an hour.
Now, I just need to read up on how the recently added/currently developing newforms class works. The documentation is sketchy in most parts, so I’ve been resorting to looking at the regression tests and source to see what it can do.
On the better hand, it looks promising: really flexible, and allowing for easy validation.