From 835c4e34964f77c3b75624a038ba153bfa58a44f Mon Sep 17 00:00:00 2001 From: pnshiralkar Date: Wed, 29 Apr 2020 21:14:18 +0530 Subject: Refractoring views backend done --- .../templates/workshop_app/my_workshops.html | 780 +++++++------- .../workshop_app/view_workshoptype_details.html | 24 - .../workshop_app/view_workshoptype_list.html | 123 --- .../workshop_app/workshop_type_details.html | 24 + .../templates/workshop_app/workshop_type_list.html | 123 +++ workshop_app/urls.py | 18 +- workshop_app/views.py | 1062 +++----------------- 7 files changed, 707 insertions(+), 1447 deletions(-) delete mode 100644 workshop_app/templates/workshop_app/view_workshoptype_details.html delete mode 100644 workshop_app/templates/workshop_app/view_workshoptype_list.html create mode 100644 workshop_app/templates/workshop_app/workshop_type_details.html create mode 100644 workshop_app/templates/workshop_app/workshop_type_list.html (limited to 'workshop_app') diff --git a/workshop_app/templates/workshop_app/my_workshops.html b/workshop_app/templates/workshop_app/my_workshops.html index ed79934..9d81c84 100644 --- a/workshop_app/templates/workshop_app/my_workshops.html +++ b/workshop_app/templates/workshop_app/my_workshops.html @@ -1,403 +1,419 @@ {% extends "workshop_app/base.html" %} {% block title %} - Workshop Status + Workshop Status {% endblock %} {% block extra %} - - - - - - - - - - + + + + + + + + + {% endblock %} {% block content %} -{% if workshops %} -
Coordinator Name | -Team Member | -Workshop Name | -Workshop Day | -
---|---|---|---|
- {{ workshop.coordinator.get_full_name }} - | -- {{ workshop.instructor.get_full_name }} - | -- {{ workshop.title }} - | -- {{ workshop.date | date }} - | -
Coordinator Name | - {% else %} -Instructor Name | - {% endif %} -Workshop Name | -Workshop Day | -Status | -||
---|---|---|---|---|---|---|
- {{ workshop.coordinator.get_full_name }} | - {% else %} -{{ workshop.instructor.get_full_name }} | - {% endif %} -{{ workshop.title }} | -{{ workshop.date | date }} | -{{ workshop.status }} | - {% endif %} - {% if request.user.profile.position == 'instructor' and workshop.status == 0 and workshop.instructor %} -- | - {% endif %} - |
Coordinator Name | -Institute | - {% else %} -Instructor Name | - {% endif %} -Workshop Name | -Workshop Day | -Status | -|||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
- {{ workshop.coordinator.get_full_name }} | -{{ workshop.coordinator.profile.institute }} | - {% else %} -{{ workshop.instructor.get_full_name }} | - {% endif %} -{{ workshop.title |capfirst }} | - {% if workshop.date > today %} -{{ workshop.date | date }}
-
+ {% if workshops %}
+ The status of your workshops++ + +
+ {% if request.user.profile.position == 'instructor' %}
+
+
+
+ Team Member Requests+ +
Requests for Me+ {% else %} +My Requests+ {% endif %} +
+
-
-
-
-Workshops Accepted+
- {% if request.user.profile.position == 'instructor' %}
-
-
-
-
-Workshops Proposed By Coordinators- {% else %} -Workshops Proposed By Me- {% endif %} -
-
-
-
-{% else %}
- {% if request.user.profile.position == 'instructor' %}
- Workshops Deleted/Rejected-
-
- {% else %}
-
-
- Welcome {{ user.first_name }}-Your workshop related information will be shown here, Please navigate to Workshop list and depending upon - your expertise and availability create a workshop by going to - Create Workshop. -
-
- {% endif %}
-{% endif %}
+
+
-
- Welcome {{ user.first_name }}-Information Related to your workshops will be shown here, you can also - propose a Workshop as per your available date in Workshops > Propose a Workshop tab . - |
+ {% else %}
+ {{ workshop.date | date }} | + {% endif %} +{{ workshop.status }} | + {% endif %} +
Coordinator Name | +Institute | + {% else %} + + {% endif %} +Workshop Name | +Workshop Day | +Status | +|
---|---|---|---|---|---|
+ + {{ workshop.coordinator.get_full_name }} | +{{ workshop.coordinator.profile.institute }} | + {% endif %} +{{ workshop.workshop_type }} | +{{ workshop.date | date }} | + +{{ workshop.get_status }} | + {% if request.user.profile.position == 'instructor' and workshop.status == 0 %} ++ + | + {% endif %} + {% endif %} +
Coordinator Name | + {% else %} +Instructor Name | + {% endif %} +Workshop Name | +Workshop Day | +Status | +
---|---|---|---|---|
{{ workshop.coordinator.get_full_name }} | + {% else %} +{{ workshop.instructor.get_full_name }} | + {% endif %} +{{ workshop.title | capfirst }} | +{{ workshop.date | date }} | + +{{ workshop.status }} | + {% endif %} +
Your workshop related information will be shown here, Please navigate to Workshop list and + depending upon + your expertise and availability create a workshop by going to + Create Workshop.
+Information Related to your workshops will be shown here, you can also + propose a Workshop as per your available date in Workshops > Propose a Workshop + tab .
+id | -Workshop Name | -Workshop Duration | -|
---|---|---|---|
{{ forloop.counter }} | -{{ w.workshoptype_name }} | -{{ w.workshoptype_duration }} | -View Workshop Details | -
id | +Workshop Name | +Workshop Duration | +|
---|---|---|---|
{{ forloop.counter }} | +{{ w.name }} | +{{ w.duration }} | +View Workshop Details | +