summaryrefslogtreecommitdiff
path: root/workshop_app/templates
diff options
context:
space:
mode:
authorpnshiralkar2020-05-19 00:56:02 +0530
committerpnshiralkar2020-05-19 00:56:02 +0530
commit1eb51c02c0cff072a27ce03be229679c6a42d629 (patch)
treee57517fc4e0ee850bcdca0e47ceec472881afb9b /workshop_app/templates
parentd26c6509865c38c9fcffff404786d381c97e8b0d (diff)
downloadworkshop_booking-1eb51c02c0cff072a27ce03be229679c6a42d629.tar.gz
workshop_booking-1eb51c02c0cff072a27ce03be229679c6a42d629.tar.bz2
workshop_booking-1eb51c02c0cff072a27ce03be229679c6a42d629.zip
Fixed view profile bug, closes #137
Diffstat (limited to 'workshop_app/templates')
-rw-r--r--workshop_app/templates/workshop_app/view_profile.html57
1 files changed, 30 insertions, 27 deletions
diff --git a/workshop_app/templates/workshop_app/view_profile.html b/workshop_app/templates/workshop_app/view_profile.html
index 9330cb0..f9d9ab2 100644
--- a/workshop_app/templates/workshop_app/view_profile.html
+++ b/workshop_app/templates/workshop_app/view_profile.html
@@ -50,35 +50,38 @@
</tr>
</table>
<br>
- <div class="container">
+
+ {% if Workshops %}
+ <div class="container">
<h2>Workshop Details</h2>
<table class="table table-bordered">
- <tr>
- <th><label for="id_instructor_name">Instructor name</label></th>
- <th><label for="id_workshop_date">Workshop date</label></th>
- <th><label for="id_workshop_type">Workshop type</label></th>
- </tr>
- {% for workshop in Workshops %}
- {% if workshop.instructor %}
- <tr>
- <td><label for="id_instructor_name">{{ workshop.instructor }}
- </label></td>
- <td><label for="id_workshop_date">{{ workshop.date }}</label>
- </td>
- <td><label for="id_workshop_type">{{ workshop.workshop_type }}</label>
- </td>
- </tr>
- {% else %}
- <tr>
- <td><span class="badge badge-warning">Pending</span></td>
- <td><label for="id_workshop_date">{{ workshop.date }}</label>
- </td>
- <td><label for="id_workshop_type">{{ workshop.workshop_type }}</label>
- </td>
- </tr>
- {% endif %}
- {% endfor %}
- </table>
+ <tr>
+ <th><label for="id_instructor_name">Instructor name</label></th>
+ <th><label for="id_workshop_date">Workshop date</label></th>
+ <th><label for="id_workshop_type">Workshop type</label></th>
+ </tr>
+ {% for workshop in Workshops %}
+ {% if workshop.instructor %}
+ <tr>
+ <td><label for="id_instructor_name">{{ workshop.instructor }}
+ </label></td>
+ <td><label for="id_workshop_date">{{ workshop.date }}</label>
+ </td>
+ <td><label for="id_workshop_type">{{ workshop.workshop_type }}</label>
+ </td>
+ </tr>
+ {% else %}
+ <tr>
+ <td><span class="badge badge-warning">Pending</span></td>
+ <td><label for="id_workshop_date">{{ workshop.date }}</label>
+ </td>
+ <td><label for="id_workshop_type">{{ workshop.workshop_type }}</label>
+ </td>
+ </tr>
+ {% endif %}
+ {% endfor %}
+ {% endif %}
+ </table>
</div>
</div>
{% endblock %}