From ebebc30a5ab8328c2330f0c03302ef7db8715365 Mon Sep 17 00:00:00 2001 From: Akshen Date: Wed, 6 Sep 2017 13:47:15 +0530 Subject: Adds Pie Chart - Adds Pie Chart to Workshop Stats - Corrects code format --- .../templates/workshop_app/propose_workshop.html | 2 +- .../templates/workshop_app/view_profile.html | 4 + .../templates/workshop_app/workshop_stats.html | 207 +++++++++++++-------- 3 files changed, 131 insertions(+), 82 deletions(-) (limited to 'workshop_app/templates') diff --git a/workshop_app/templates/workshop_app/propose_workshop.html b/workshop_app/templates/workshop_app/propose_workshop.html index 95a4008..ce90dc8 100644 --- a/workshop_app/templates/workshop_app/propose_workshop.html +++ b/workshop_app/templates/workshop_app/propose_workshop.html @@ -22,7 +22,7 @@ changeMonth: true, changeYear: true, minDate: dateToday, - maxDate: upto, + maxDate: upto // You can put more options here. }); }); diff --git a/workshop_app/templates/workshop_app/view_profile.html b/workshop_app/templates/workshop_app/view_profile.html index 91efdf1..8f1fbae 100644 --- a/workshop_app/templates/workshop_app/view_profile.html +++ b/workshop_app/templates/workshop_app/view_profile.html @@ -68,6 +68,10 @@ + + + + diff --git a/workshop_app/templates/workshop_app/workshop_stats.html b/workshop_app/templates/workshop_app/workshop_stats.html index 464c625..bc6387b 100644 --- a/workshop_app/templates/workshop_app/workshop_stats.html +++ b/workshop_app/templates/workshop_app/workshop_stats.html @@ -63,18 +63,17 @@ .on( "change", function() { from.datepicker( "option", "maxDate", getDate( this ) ); }); - - function getDate( element ) { - var date; - try { - date = $.datepicker.parseDate( dateFormat, element.value ); - } catch( error ) { - date = null; - } - - return date; - } - } ); + + function getDate( element ) { + var date; + try { + date = $.datepicker.parseDate( dateFormat, element.value ); + } catch( error ) { + date = null; + } + return date; + } + } ); @@ -82,22 +81,22 @@ {% block content %} -
+
{% if show_workshop_stats %}
- {% csrf_token %} -
- - - - - - -
+ {% csrf_token %} +
+ + + + + + +
- {% if messages %} + {% if messages %}
    {% for message in messages %}
    @@ -106,7 +105,8 @@
    {% endfor %}
- {% endif %} + {% endif %} +

@@ -177,69 +177,114 @@ {% else %}

Permission to View Upcoming Workshops is set to false, please set it to true in settings.py

-
+ {% endif %} - + +
-
+
+
+

-
-
- +
+
+ + + + +
+
+ + -
-
+

{% endblock %} -- cgit