lhuang / cnprog

Automatically exported from code.google.com/p/cnprog
Other
0 stars 0 forks source link

number of unanswered questions incorrect? #41

Open GoogleCodeExporter opened 8 years ago

GoogleCodeExporter commented 8 years ago
wouldn't you want to count questions as unaswered when there is no accepted
answer?

currently it looks like question is answered if there is at least one
answer regardless of its acceptance status.

Version: beta2, English.

Original issue reported on code.google.com by evgeny.f...@gmail.com on 23 Jun 2009 at 4:49

GoogleCodeExporter commented 8 years ago
adding filter "answer_accepted"=False in views.question() solves this

        #check if request is from unanswered questions
        template_file = "unanswered.html"
        objects = Question.objects.filter(deleted=False,
answer_accepted=False).order_by(orderby)

Original comment by evgeny.f...@gmail.com on 29 Jun 2009 at 7:13