fix: show mentors section even when there are no mentors

Previously, the mentors heading was not shown when there were no
mentors, but the link to apply to become mentor was shown and that
appears in the Instructors section.

Fixed it by showing a message to indicate that there are no mentors for
this course.
This commit is contained in:
Anand Chitipothu
2021-04-21 15:15:55 +05:30
parent 22448a8a7b
commit 153bb925d8

View File

@@ -210,10 +210,13 @@
</div>
</div>
</div>
{% if mentors %}
<div class="margin-bottom">
<h4 class="margin-bottom">Mentors</h4>
<div class="d-flex">
{% if not mentors %}
<em>There are no active mentors for this course.</em>
{% endif %}
{% for mentor in mentors %}
<div class="d-flex align-items-center mr-5">
<div>
@@ -232,7 +235,6 @@
{% endfor %}
</div>
</div>
{% endif %}
{% if not is_mentor %}
<div class="pt-5 mentor-request">
Interested to mentor this course? <span class="apply-now" data-course={{course.name | urlencode}}