I hope my title is enough to understand what I mean, please help me on this problem guys.

When I tried this:
"" id_list = grade.objects.filter(Teacher=
m.id).values_list('Students_Enrollment_Records_id',flat=True).distinct() ""
I use `distinct()` to eliminates duplicate rows of Students Enrollment Record from the query results but I wonder why the result is like this:

What should I do to show the Students name not that QuerySet in my html?
This is my current **views.py**:
id_list = grade.objects.filter(Teacher=
m.id).values_list('Students_Enrollment_Records_id',flat=True).distinct()
print(id_list)
grades = grade.objects.filter(Students_Enrollment_Records_id__in=id_list)
print(grades)
This is my **models.py**:
class grade(models.Model):
Teacher = models.ForeignKey(EmployeeUser, related_name='+', on_delete=models.CASCADE,
null=True, blank=True)
Grading_Categories = models.ForeignKey(gradingCategories, related_name='+', on_delete=models.CASCADE,
null=True, blank=True)
Subjects = models.ForeignKey(Subject, related_name='+', on_delete=models.CASCADE, null=True)
Students_Enrollment_Records = models.ForeignKey(StudentsEnrolledSubject, related_name='+',
on_delete=models.CASCADE, null=True)
Average = models.FloatField(null=True, blank=True)
**UPDATE**
when I tried this
piste = grade.objects.filter(Teacher_id=
m.id).values_list('Students_Enrollment_Records').annotate(Average=Avg('Average')).order_by('Grading_Categories').distinct()
the computation is fix but the teacher name, Subject and Name of students didn't display but the ID is display just like this

this is my desire answer
