refactor: refactored the course page

- simplified the portal page for course
- added mentods to LMS Course and Community Member to reduce custom code
  in portal pages
- included lessons in the ChapterTeaser
This commit is contained in:
Anand Chitipothu
2021-05-03 12:05:17 +05:30
parent 9e103af8b5
commit b9d94df4d8
7 changed files with 157 additions and 150 deletions

View File

@@ -2,7 +2,7 @@
<h3>Instructor</h3>
<div class="instructor">
<div class="instructor-title">{{instructor.full_name}}</div>
<div class="instructor-subtitle">Created {{instructor.course_count}} courses</div>
<div class="instructor-subtitle">Created {{instructor.get_course_count()}} courses</div>
</div>
{% endmacro %}
@@ -11,7 +11,7 @@
{% for m in mentors %}
<div class="instructor">
<div class="instructor-title">{{m.full_name}}</div>
<div class="instructor-subtitle">Mentored {{m.batch_count}} batches</div>
<div class="instructor-subtitle">Mentored {{m.get_batch_count()}} batches</div>
</div>
{% endfor %}
{% if not is_mentor %}
@@ -29,4 +29,4 @@
<h3>{{course_name}}</h3>
<div class="text-muted">{{member_count}} members</div>
</div>
{% endmacro %}
{% endmacro %}