是否可以通过“ GENDER”将其附加到QuestionFocus
,然后获取QuestionFocus.GENDER
后面的内容?我当然可以只通过QuestionFocus.GENDER
,但这会使它比(可能)必要的时间更长。
def get_answers(question_focus):
return Answer.objects.filter(
response_id__in=get_super_guests().values_list("id", flat=True),
question__focus=QuestionFocus.question_focus,
).order_by("-created")
context["genders"] = get_answers("GENDER")