summaryrefslogtreecommitdiff
path: root/workshop_app/templates
diff options
context:
space:
mode:
authorAkshen Doke2017-03-30 10:54:05 +0530
committerAkshen2017-05-19 15:30:31 +0530
commit55585b6864e128dfd4fae5ae391373abf96c5ce5 (patch)
tree4fe8d974fd3ffd35246c1c16a192eb6b82db5d23 /workshop_app/templates
parentf751cd3c07619d8ee1e5b96c23b19cfae2005c0f (diff)
downloadworkshop_booking-55585b6864e128dfd4fae5ae391373abf96c5ce5.tar.gz
workshop_booking-55585b6864e128dfd4fae5ae391373abf96c5ce5.tar.bz2
workshop_booking-55585b6864e128dfd4fae5ae391373abf96c5ce5.zip
Recurrence done
Booking ToDo
Diffstat (limited to 'workshop_app/templates')
-rw-r--r--workshop_app/templates/workshop_app/base.html1
-rw-r--r--workshop_app/templates/workshop_app/booking.html57
-rw-r--r--workshop_app/templates/workshop_app/create_workshop.html4
-rw-r--r--workshop_app/templates/workshop_app/manage.html73
4 files changed, 125 insertions, 10 deletions
diff --git a/workshop_app/templates/workshop_app/base.html b/workshop_app/templates/workshop_app/base.html
index cebab31..9971dd4 100644
--- a/workshop_app/templates/workshop_app/base.html
+++ b/workshop_app/templates/workshop_app/base.html
@@ -17,6 +17,7 @@
<link rel="stylesheet" href="{{ URL_ROOT }}/static/workshop_app/css/sticky-footer.css" type="text/css" />
</head>
+ <!-- For js/ajax and other related scripts -->
{% block extra %}
{% endblock %}
diff --git a/workshop_app/templates/workshop_app/booking.html b/workshop_app/templates/workshop_app/booking.html
index 01cd609..4657b4a 100644
--- a/workshop_app/templates/workshop_app/booking.html
+++ b/workshop_app/templates/workshop_app/booking.html
@@ -4,6 +4,10 @@
Booking
{% endblock %}
+{% block extra %}
+
+{% endblock %}
+
{% block header %}
<nav class="navbar navbar-inverse">
<div class="container-fluid">
@@ -19,4 +23,57 @@
</ul>
</div>
</nav>
+{% endblock %}
+
+{% block content %}
+ <div class="container">
+ <table class="table table-hover">
+ <thead>
+ <tr>
+ <th>Instructor Name</th>
+ <th>Course Name</th>
+ <th>Course Day</th>
+ <th>Booking</th>
+ </tr>
+ </thead>
+ {% csrf_token %}
+ {% for workshop in workshop_details %}
+ <tbody>
+ <tr>
+ <td>{{ workshop.1.0 }}</td>
+ <td>{{ workshop.1.1 }}</td>
+ <td>{{ workshop.0 }}</td>
+ <td><button id="book-btn" class="btn btn-primary btn-sm">Book</button></td>
+ </tr>
+ </tbody>
+ {% endfor %}
+ </table>
+ </div>
+
+ <div class="container">
+ <div class="Page-Nav" align="center">
+ <nav aria-label="Page navigation">
+ <ul class="pagination pagination-sm">
+ <li class="page-item">
+ {% if workshop_details.has_previous %}
+ <a class="page-link" tabindex="-1"
+ href="?page={{ workshop_details.previous_page_number }}">Previous</a>
+ {% endif %}
+ </li>
+ <li class="page-item">
+ <span class="current">
+ Page {{ workshop_details.number }} of {{ workshop_details.paginator.num_pages }}
+ </span>
+ </li>
+ <li class="page-item">
+ {% if workshop_details.has_next %}
+ <a class="page-link" href="?page={{ workshop_details.next_page_number }}">Next
+ </a>
+ {% endif %}
+ </li>
+ </ul>
+ </nav>
+ </div>
+ </div>
+
{% endblock %} \ No newline at end of file
diff --git a/workshop_app/templates/workshop_app/create_workshop.html b/workshop_app/templates/workshop_app/create_workshop.html
index 93de011..e643594 100644
--- a/workshop_app/templates/workshop_app/create_workshop.html
+++ b/workshop_app/templates/workshop_app/create_workshop.html
@@ -40,7 +40,11 @@
<div class="container">
<form method="post">
{% csrf_token %}
+ <br/>
+ {{ form.media }}
{{ form.as_p }}
+
+
<br>
<button class="btn btn-success" type="submit">Save</button>
</form>
diff --git a/workshop_app/templates/workshop_app/manage.html b/workshop_app/templates/workshop_app/manage.html
index b2404ed..3afca6b 100644
--- a/workshop_app/templates/workshop_app/manage.html
+++ b/workshop_app/templates/workshop_app/manage.html
@@ -20,15 +20,68 @@
{% block content %}
-<div class="container">
- {% csrf_token %}
- {% for w in workshop_details %}
- {{ w.date }}<br>
- {{ w.start_time }}<br>
- {{ w.end_time }}<br>
- {{ w.workshop_creator }}<br>
- {{ w.workshop_title }}
- {% endfor %}
-</div>
+ {% if workshop_occurence_list %}
+ <div class="container">
+ <table class="table table-hover">
+ <thead>
+ <tr>
+ <th>Instructor Name</th>
+ <th>Course Name</th>
+ <th>Course Day</th>
+ <th>Booking</th>
+ </tr>
+ </thead>
+ {% csrf_token %}
+ {% for workshop in workshop_occurence_list %}
+ {% for w in workshop %}
+ <tbody>
+ <tr>
+ <td>{{ w.user }}</td>
+ <td>{{ w.workshop }}</td>
+ <td>{{ w.date }}</td>
+ </tr>
+ </tbody>
+ {% endfor %}
+ {% endfor %}
+ </table>
+ </div>
+
+ <div class="container">
+ <div class="Page-Nav" align="center">
+ <nav aria-label="Page navigation">
+ <ul class="pagination pagination-sm">
+ <li class="page-item">
+ {% if workshop_occurence_list.has_previous %}
+ <a class="page-link" tabindex="-1"
+ href="?page={{ workshop_occurence_list.previous_page_number }}">Previous</a>
+ {% endif %}
+ </li>
+ <li class="page-item">
+ <span class="current">
+ Page {{ workshop_occurence_list.number }} of {{ workshop_occurence_list.paginator.num_pages }}
+ </span>
+ </li>
+ <li class="page-item">
+ {% if workshop_occurence_list.has_next %}
+ <a class="page-link" href="?page={{ workshop_occurence_list.next_page_number }}">Next
+ </a>
+ {% endif %}
+ </li>
+ </ul>
+ </nav>
+ </div>
+ </div>
+
+ {% else %}
+ <div class="container">
+ <div class="jumbotron">
+ <h1>Welcome Instructor</h1>
+ <p>Please navigate to <b>View Course list</b> and depending upon
+ your expertise and availability create a workshop by going to
+ <b>Create Event</b>.</p>
+
+ </div>
+ </div>
+ {% endif %}
{% endblock %} \ No newline at end of file