@decorators.render('questions.html', 'unanswered', _('unanswered'), weight=400)
def unanswered(request):
return question_list(request,
- Question.objects.filter(extra_ref=None),
+ Question.objects.exclude(id__in=Question.objects.filter(children__marked=True).distinct()),
_('open questions without an accepted answer'),
None,
_("Unanswered Questions"))
if request.GET.get("q"):
keywords = request.GET.get("q").strip()
- answer_count = Answer.objects.filter_state(deleted=False).filter(parent__in=questions).count()
- answer_description = _("answers")
+ #answer_count = Answer.objects.filter_state(deleted=False).filter(parent__in=questions).count()
+ #answer_description = _("answers")
if not feed_url:
req_params = "&".join(["%s=%s" % (k, v) for k, v in request.GET.items() if not k in (_('page'), _('pagesize'), _('sort'))])
feed_url = mark_safe(request.path + "?type=rss" + req_params)
return pagination.paginated(request, ('questions', paginator_context or QuestionListPaginatorContext()), {
- "questions" : questions,
+ "questions" : questions.distinct(),
"questions_count" : questions.count(),
"keywords" : keywords,
"list_description": list_description,