A question though:
I noticed the comments retreived by {% get_comment_list ... %} are
ordered by pk. Is there any plan to include custom ordering? I believe
the default ordering should include replies to old comments after the
objet it refers since I dont see any case in which it would make sense
to have the replies away from the objects being replied upon.
I'll try to play around with your project when I get the time :)
good luck,
--
Nicolas Lara
Linux user #380134
Public key id: 0x152e7713 at http://keyserver.noreply.org/
# Anti-Spam e-mail addresses:
python -c "print '@'.join(['nicolaslara', '.'.join([x for x in
reversed( 'com|gmail'.split('|') )])])"
python -c "print '@'.join(['nicolas', '.'.join([x for x in reversed(
've|usb|labf|ac'.split('|') )])])"
You can do both :-)
Have a FlagType model with a string as a primary key, so you only need
to set flag_id if you already know what string you want. I have to
say, I don't usually mess with custom primary keys in django, and have
no idea if there are downsides in using them. Feel free to correct me
if this isn't a good idea for whatever reason.
Having said that I like the flexible approach of just having a string;
unless you need to store other attributes, there are no great
benefits. Bad data could be seen as more of a usability problem than a
technical one.
Cheers,
--
Will Hardy
w: http://www.willhardy.com.au
Isn't it cleaner to look at the threaded comments in another way, e.g.,
if comment B is a reply to comment A, then the content_object of B is
simply A instead of the original content object a comment is attached
to? That way you can get rid of the 'parent', because 'content_object'
is the 'parent'. You may calculate the 'level' by recursively looking at
the content_object's content_type. If it's not a comment then you've
reached the top of the thread. In this way, a non-threaded comment is
just a threaded comment with maximum level 1, and the post_comment and
reply_comment can be merged.
Also a 'modify_date' may be useful for the abstract comment model. One
of the benefits you might want to provide to the authenticated users is
to modify their comments.
Thanks,
Zhiwu Xie
Zhiwu