From b50a8653c902bf9433255322440e9e36a6737101 Mon Sep 17 00:00:00 2001 From: Guillaume Pellerin Date: Wed, 10 Feb 2021 14:21:44 +0100 Subject: [PATCH] fix bbb records qs --- teleforma/templates/teleforma/inc/media_list.html | 2 +- teleforma/views/core.py | 3 ++- 2 files changed, 3 insertions(+), 2 deletions(-) diff --git a/teleforma/templates/teleforma/inc/media_list.html b/teleforma/templates/teleforma/inc/media_list.html index 1bc531c9..16e06d07 100644 --- a/teleforma/templates/teleforma/inc/media_list.html +++ b/teleforma/templates/teleforma/inc/media_list.html @@ -66,7 +66,7 @@ {% endif %} {% endif %} {% endfor %} - {% for record in webclass_records|from_course_type:type %} + {% for record in other_records|from_course_type:type %} {% include 'webclass/inc/webclass_card.html' %} {% endfor %} diff --git a/teleforma/views/core.py b/teleforma/views/core.py index ce49dddd..8229b321 100644 --- a/teleforma/views/core.py +++ b/teleforma/views/core.py @@ -481,7 +481,8 @@ class CourseView(CourseAccessMixin, DetailView): context['webclass_slot'] = webclass_slot try: - context['webclass_records'] = WebclassRecord.get_records(context['period'], course) + context['webclass_records'] = WebclassRecord.get_records(context['period'], course, course_type=None) + context['other_records'] = WebclassRecord.get_records(context['period'], course).exclude(course_type=None) except Exception, e: print(e) context['webclass_error'] = True -- 2.39.5