diff options
11 files changed, 243 insertions, 431 deletions
diff --git a/static/workshop_app/css/slick-theme.css b/static/workshop_app/css/slick-theme.css new file mode 100644 index 0000000..46c87bf --- /dev/null +++ b/static/workshop_app/css/slick-theme.css @@ -0,0 +1,202 @@ +@charset 'UTF-8'; +/* Slider */ +.slick-loading .slick-list +{ + background: #fff url('./ajax-loader.gif') center center no-repeat; +} + +/* Icons */ +@font-face +{ + font-family: 'slick'; + font-weight: normal; + font-style: normal; + + src: url('./fonts/slick.eot'); + src: url('./fonts/slick.eot?#iefix') format('embedded-opentype'), url('./fonts/slick.woff') format('woff'), url('./fonts/slick.ttf') format('truetype'), url('./fonts/slick.svg#slick') format('svg'); +} +/* Arrows */ +.slick-prev, +.slick-next +{ + font-size: 0; + line-height: 0; + + position: absolute; + top: 50%; + + display: block; + + width: 30px; + height: 35px; + padding: 0; + -webkit-transform: translate(0, -50%); + -ms-transform: translate(0, -50%); + transform: translate(0, -50%); + + cursor: pointer; + border: none; + outline: none; + +} +.slick-prev:hover, +.slick-prev:focus, +.slick-next:hover, +.slick-next:focus +{ + color: orange; + outline: none; + background: white; +} +.slick-prev:hover:before, +.slick-prev:focus:before, +.slick-next:hover:before, +.slick-next:focus:before +{ + opacity: 1; +} +.slick-prev.slick-disabled:before, +.slick-next.slick-disabled:before +{ + opacity: .25; +} + +.slick-prev:before, +.slick-next:before +{ + font-family: 'slick'; + font-size: 40px; + line-height: 1; + + opacity: 3; + color: ; + + -webkit-font-smoothing: antialiased; + -moz-osx-font-smoothing: grayscale; +} + +.slick-prev +{ + left: -25px; +} +[dir='rtl'] .slick-prev +{ + right: -25px; + left: auto; +} +.slick-prev:before +{ + content: '<'; +} +[dir='rtl'] .slick-prev:before +{ + content: '>'; +} + +.slick-next +{ + right: -25px; +} +[dir='rtl'] .slick-next +{ + right: auto; + left: -25px; +} +.slick-next:before +{ + content: '>'; +} +[dir='rtl'] .slick-next:before +{ + content: '<'; +} + +/* Dots */ +.slick-dotted.slick-slider +{ + margin-bottom: 30px; +} + +.slick-dots +{ + position: absolute; + bottom: -25px; + + display: block; + + width: 100%; + padding: 0; + margin: 0; + + list-style: none; + + text-align: center; +} +.slick-dots li +{ + position: relative; + + display: inline-block; + + width: 20px; + height: 20px; + margin: 0 5px; + padding: 0; + + cursor: pointer; +} +.slick-dots li button +{ + font-size: 0; + line-height: 0; + + display: block; + + width: 20px; + height: 20px; + padding: 5px; + + cursor: pointer; + + color: transparent; + border: 0; + outline: none; + background: transparent; +} +.slick-dots li button:hover, +.slick-dots li button:focus +{ + outline: none; +} +.slick-dots li button:hover:before, +.slick-dots li button:focus:before +{ + opacity: 1; +} +.slick-dots li button:before +{ + font-family: 'slick'; + font-size: 6px; + line-height: 20px; + + position: absolute; + top: 0; + left: 0; + + width: 20px; + height: 20px; + + content: '•'; + text-align: center; + + opacity: .25; + color: black; + + -webkit-font-smoothing: antialiased; + -moz-osx-font-smoothing: grayscale; +} +.slick-dots li.slick-active button:before +{ + opacity: .75; + color: black; +} diff --git a/statistics_app/templates/statistics_app/workshop_public_stats.html b/statistics_app/templates/statistics_app/workshop_public_stats.html index 486c154..78f965a 100644 --- a/statistics_app/templates/statistics_app/workshop_public_stats.html +++ b/statistics_app/templates/statistics_app/workshop_public_stats.html @@ -323,7 +323,8 @@ domain: 'IN', displayMode: 'regions', resolution: 'provinces', - colorAxis: {colors: ['lightyellow','orange']}, + datalessRegionColor: 'transparent', + colorAxis: {colors: ['#e6e6e6','#ff8b3e']}, }; @@ -347,7 +348,8 @@ <style> #visualization path { stroke-width:1; /* control the countries borders width */ - stroke:#6699cc; /* choose a color for the border */ + stroke:white; + /* choose a color for the border */ } </style> <div id="visualization" style="width: 400px; height: 300px; display: block; margin: 0 auto;" ></div> diff --git a/statistics_app/templates/statistics_app/workshop_stats.html b/statistics_app/templates/statistics_app/workshop_stats.html index 3bfce07..f52a0e0 100644 --- a/statistics_app/templates/statistics_app/workshop_stats.html +++ b/statistics_app/templates/statistics_app/workshop_stats.html @@ -335,7 +335,8 @@ domain: 'IN', displayMode: 'regions', resolution: 'provinces', - colorAxis: {colors: ['lightyellow', 'orange']}, + datalessRegionColor: 'transparent', + colorAxis: {colors: ['#e6e6e6', '#ff8b3e']}, legend: {position: 'top'}, }; @@ -358,7 +359,7 @@ <style> #visualization path { stroke-width:1; /* control the countries borders width */ - stroke:#6699cc; /* choose a color for the border */ + stroke:white; /* choose a color for the border */ } </style> <div id="visualization" style="width: 400px; height: 300px; display: block; margin: 0 auto;" ></div> diff --git a/statistics_app/views.py b/statistics_app/views.py index 0f3af78..1c13d60 100644 --- a/statistics_app/views.py +++ b/statistics_app/views.py @@ -443,11 +443,31 @@ def workshop_public_stats(request): except BaseException: messages.info(request, 'Please enter Valid Dates') + else: + '''Default Data''' + workshop_list = [] + + proposed_workshops = ProposeWorkshopDate.objects.filter( + status='ACCEPTED') + + # Fetches Accepted workshops which were Accepted by + # Instructors based on their Availability + requested_workshops = RequestedWorkshop.objects.filter( + status='ACCEPTED') + + for workshop in proposed_workshops: + workshop_list.append(workshop) + + for workshop in requested_workshops: + workshop_list.append(workshop) + + return render(request, 'statistics_app/workshop_public_stats.html', { "workshoptype_list": workshoptype_list[::-1], "workshoptype_count": workshoptype_count, + "workshop_list": workshop_list, "india_map": states}) diff --git a/workshop_app/static/workshop_app/css/new_index.css b/workshop_app/static/workshop_app/css/new_index.css deleted file mode 100644 index f194ec2..0000000 --- a/workshop_app/static/workshop_app/css/new_index.css +++ /dev/null @@ -1,250 +0,0 @@ -/* Responsive layout - when the screen is less than 800px wide, make the two columns stack on top of each other instead of next to each other */ -@media screen and (max-width: 800px) { - .leftcolumn, .rightcolumn { - width: 100%; - padding: 0; - - }, - -} - -ul.topnav { - list-style-type: none; - margin: 20px; - padding: 0; - overflow: hidden; -} - -ul.topnav li {float: right;} - -ul.topnav li a { - display: block; - color: black; - text-align: center; - padding: 14px 16px; - text-decoration: none; -} - -ul.topnav li a:hover:not(.active) { - background-color: #3bb1d1; - color:white; - padding: 14px 16px; -} - -ul.topnav li.right {float: right;} - -@media screen and (max-width: 600px){ - ul.topnav li.right, - ul.topnav li {float: none;} -} - -/**/ -.container { - width: 100%; - box-shadow: 0 4px 8px 0 rgba(0, 0, 0, 0.2), 0 6px 20px 0 rgba(0, 0, 0, 0.19); - align-content: center; -} - -.row { - width: 100%; - margin: auto; - align-content: center; - -} - -@font-face { - font-family: aaragh; - src: url("../font/Aaargh.ttf"); - -} - - -#r1_c1 -{ - font-family: aaragh, Helvetica, Arial, sans-serif; - font-size: 30px; - background-image: url("../img/hd_bg.png"); - background-repeat: no-repeat; - background-position: bottom; - padding-top: 15px; - padding-bottom: 15px; - padding-left: 10%; -} - - -.rslides { - position: relative; - list-style: none; - overflow: hidden; - padding: 0; - margin: 0; - width: 10px; - } - -.rslides li { - -webkit-backface-visibility: hidden; - position: absolute; - display: none; - left: 0; - top: 0; - } - -.rslides li:first-child { - position: relative; - display: block; - float: left; - } - -.rslides img { - display: block; - float: left; - border: 0; - width: 100%; - } - -#r2_c1 { - margin: auto; - width: 100%; -} - -#r2_c2 { - padding-top: 15px; - width: 100%; -} - -#r3 { - text-align: center; - color: white; - background: linear-gradient(135deg , #2c5aa0,#2c5aa0 30%, #3bb1d1 ); - padding-bottom: 25px; - margin-top: 15px; - font-family: aaragh, Arial, sans-serif; -} - - - -#r5 { - width: 100%; -} - -#r5_c1 { - text-align: center; - font-size: 2vw; - font-family: aaragh, Arial, sans-serif; - margin-top: 10px; - -} - -#r5_c2 { - font-family: aaragh, Arial, sans-serif; - -} - -#r5_c3 { - padding-top: 15px; -} - -#r6 { - padding: 35px; - margin-top: 15px; - width: 100%; - background: linear-gradient(135deg , #2c5aa0,#2c5aa0 30%, #3bb1d1 ); - -} - -#r6_c2 { - text-align: center; - font-family: aaragh; - color: white; -} - -.tslides { - position: relative; - list-style: none; - overflow: hidden; - padding: 0; - margin: 0; - width: 10px; - } - -.tslides li { - -webkit-backface-visibility: hidden; - position: absolute; - display: none; - left: 0; - top: 0; - text-align: center; - } - -.tslides li:first-child { - position: relative; - display: block; - text-align: center; - } - - -#r8 { - background: #c8c5b6; - margin-top: 15px; - padding-right: 20px; - padding-left: 20px; - width: 100%; -} - - - -#r8_c2 { - font-size: 16px; - font-family: aaragh; - text-align: center; -} - -#social { - float: right; - -} -#r8_c4 { - text-align: center; - font-size: 12px; - width: 100%; - font-family: aaragh; -} - -hr { - background-color: black; -} - -/* Style all font awesome icons */ -.fa { - padding: 6px; - font-size: 30px; - width: 30px; - text-align: center; - text-decoration: none; -} - -/* Add a hover effect if you want */ -.fa:hover { - opacity: 0.7; -} - -/* Facebook */ -.fa-facebook { - background: #3B5998; - color: white; - -} -/* Google */ -.fa-google { - background: #dd4b39; - color: white; -} -/* Youtube */ -.fa-youtube { - background: #bb0000; - color: white; -} - -#social a{ - color: white; -} diff --git a/workshop_app/templates/workshop_app/index.html b/workshop_app/templates/workshop_app/index.html index d5e95c3..a2e8966 100644 --- a/workshop_app/templates/workshop_app/index.html +++ b/workshop_app/templates/workshop_app/index.html @@ -67,7 +67,7 @@ $(document).ready(function(){ <div class="col-md-6" > <ul class="topnav"> <li><a href="{{URL_ROOT}}/statistics/public_stats/">Stats</a></li> - <li ><a href="https://python.fossee.in/about">About Us</a></li> + <li ><a href="https://python.fossee.in/about" target="_blank">About Us</a></li> <li><a href="{{URL_ROOT}}/how_to_participate">How to Participate</a></li> <li><a href="{{URL_ROOT}}/login">Login</a></li> <li><a href="{{URL_ROOT}}/register">Sign Up</a></li> diff --git a/workshop_app/templates/workshop_app/login.html b/workshop_app/templates/workshop_app/login.html index c30f9db..e069cd9 100644 --- a/workshop_app/templates/workshop_app/login.html +++ b/workshop_app/templates/workshop_app/login.html @@ -23,12 +23,13 @@ <div class="container" align="center"> <br> <form method="post"> - {% csrf_token %} - {{ form.as_p }} - <br> - <br> - <button class="btn btn-default" type="submit">Login</button> - <br> + {% csrf_token %} + {{ form.as_p }} + <br> + <br> + <button class="btn btn-info btn-sm" type="submit">Login</button> + <a href="{{URL_ROOT}}/forgotpassword/" class="btn btn-default btn-sm" style="color:#3693C0;">Forgot Password</a> + <br> </form> <br> </div> diff --git a/workshop_app/templates/workshop_app/my_workshops.html b/workshop_app/templates/workshop_app/my_workshops.html index 2a17b8d..80ab7f1 100644 --- a/workshop_app/templates/workshop_app/my_workshops.html +++ b/workshop_app/templates/workshop_app/my_workshops.html @@ -129,7 +129,7 @@ <li><a href="{{ URL_ROOT }}/create_workshop/">Create Workshop</a></li> <li><a href="{{ URL_ROOT }}/view_workshoptype_list/">Workshop List</a></li> <li class="active"><a href="{{ URL_ROOT }}/my_workshops/">My Workshops</a></li> - <li><a href="{{ URL_ROOT }}/workshop_stats/">Workshop Stats</a></li> + <li><a href="{{ URL_ROOT }}/statistics/">Workshop Stats</a></li> <li><a href="{{ URL_ROOT }}/statistics/profile_stats/" >Profile Stats</a></li> </ul> {% else %} @@ -213,7 +213,7 @@ <tr> {% if request.user.profile.position == 'instructor' %} <th>Coordinator Name</th> - <th>Coordinator Institute Name</th> + <th>Institute</th> {% else %} <th>Instructor Name</th> {% endif %} @@ -296,6 +296,7 @@ <tr> {% if request.user.profile.position == 'instructor' %} <th>Coordinator Name</th> + <th>Institute</th> {% else %} {% endif %} @@ -311,6 +312,7 @@ {% if workshop.status == 'Pending' and workshop.condition_one %} {% if request.user.profile.position == 'instructor' %} <td>{{ workshop.proposed_workshop_coordinator.get_full_name }}</td> + <td>{{ workshop.proposed_workshop_coordinator.profile.institute }}</td> {% endif %} <td>{{ workshop.proposed_workshop_title }}</td> <td>{{ workshop.proposed_workshop_date | date }}</td> diff --git a/workshop_app/templates/workshop_app/new_index.html b/workshop_app/templates/workshop_app/new_index.html deleted file mode 100644 index 4603ac7..0000000 --- a/workshop_app/templates/workshop_app/new_index.html +++ /dev/null @@ -1,166 +0,0 @@ -<!DOCTYPE html> -<html> -<head> - <meta charset="utf-8"> - <meta http-equiv="X-UA-Compatible" content="IE=edge"> - <meta name="viewport" content="width=device-width, initial-scale=1"> - <meta name="Akshen Doke" content=""> - - <link rel="stylesheet" href="https://maxcdn.bootstrapcdn.com/bootstrap/4.0.0/css/bootstrap.min.css" integrity="sha384-Gn5384xqQ1aoWXA+058RXPxPg6fy4IWvTNh0E263XmFcJlSAwiGgFAW/dAiS6JXm" crossorigin="anonymous"> - <script src="https://maxcdn.bootstrapcdn.com/bootstrap/4.0.0/js/bootstrap.min.js" integrity="sha384-JZR6Spejh4U02d8jOt6vLEHfe/JQGiRRSQQxSfFWpi1MquVdAyjUar5+76PVCmYl" crossorigin="anonymous"></script> - - <!-- Custom CSS --> - <link rel="stylesheet" href="{{ URL_ROOT }}/static/workshop_app/css/new_index.css" type="text/css" /> - - <!-- Add icon library --> - <link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/font-awesome/4.7.0/css/font-awesome.min.css"> - - <script src="http://ajax.googleapis.com/ajax/libs/jquery/1.8.3/jquery.min.js"></script> - - <!-- Custom JS --> - <script src="{{ URL_ROOT }}/static/workshop_app/js/new_index.js"></script> - - - <title>Welcome</title> - - <script> - $(function() { - $(".rslides").responsiveSlides({ - speed: "3000", - }); - }); - - $(function() { - $(".tslides").responsiveSlides({ - speed: "1000", - }); - }); - </script> - - -</head> -<body class="container"> - -<div class="row" id="r1"> - <div class="col-md-6" id="r1_c1"> - FOSSEE Python Workshop - </div> - <div class="col-md-6"> - <ul class="topnav"> - <li><a href="{{URL_ROOT}}/login">Login</a></li> - <li><a href="{{URL_ROOT}}/register">Sign Up</a></li> - <li ><a href="https://python.fossee.in/about">About Us</a></li> - </ul> - </div> -</div> - -<div class="row" id="r2"> - <div class="col-md-6 rslides" id="r2_c1"> - - <img src="{{ URL_ROOT}}/static/workshop_app/img/intro_img_1.png" > - <img src="{{ URL_ROOT}}/static/workshop_app/img/intro_img_2.png" > - <img src="{{ URL_ROOT}}/static/workshop_app/img/intro_img_3.png" > - <img src="{{ URL_ROOT}}/static/workshop_app/img/intro_img_4.png" > - <img src="{{ URL_ROOT}}/static/workshop_app/img/intro_img_5.png" > - - </div> - - <div class="col-md-6" id="r2_c2"> - <video style="width: 100%;" controls> - <source src="https://static.fossee.in/python/1-day-workshop/1_Introduction_to_Python.mp4" type="video/mp4"> - </video> - </div> -</div> - -<div class="row" id="r3"> - <div class="col-md-4" id="r3_c1"> <br>6000+ <br>Students Trained</div> - <div class="col-md-4" id="r3_c2"><br>100+ <br> Colleges - </div> - <div class="col-md-4" id="r3_c3"><br> 27 hours of <br>Workshop Material</div> -</div> - - -<div class="row" id="r4"> - <div class="col-md-4"> - <br> - <a href="{{URL_ROOT}}/view_workshoptype_details/5"><img src="{{ URL_ROOT}}/static/workshop_app/img/Crs_1.png" style="width: 100%;"></a> - </div> - <div class="col-md-4"> - <br> - <a href="{{URL_ROOT}}/view_workshoptype_details/4"><img src="{{ URL_ROOT}}/static/workshop_app/img/Crs_2.png" style="width: 100%;"></a> - </div> - <div class="col-md-4"> - <br> - <a href="{{URL_ROOT}}/self_workshop"><img src="{{ URL_ROOT}}/static/workshop_app/img/Crs_3.png" style="width: 100%;"></a> - </div> -</div> - -<div class="row" id="r5"> - <div class="col-md-12" id="r5_c1">FOSSEE Python Workshop <span style="font-size: 3.5vw; color: #3bb1d1;">Advantage</span> - </div> - - <div class="col-md-6" id="r5_c2"><img src="{{ URL_ROOT}}/static/workshop_app/img/icon_1.png"><br><br> - <h5 style="color: #3bb1d1;">Learn Python for Free,</h5> - <h5 style="color: #3bb1d1;">Many exercises/practice problems</h5> <br> - <h5 style="color: #3bb1d1;"> Instructor support for your queries during workshop(s)</h5> <br> - <h5 style="color: #3bb1d1;">Get e-certificate</h5> - - </div> - - <div class="col-md-6" id="r5_c3"><img src="{{ URL_ROOT}}/static/workshop_app/img/adv_img.png" style="width: 100%;"></div> -</div> - -<div class="row" id="r6"> - - <div class="col-md-12 tslides" id="r6_c2" > - <li>{{ testimonials.0.message }} <br> <br> - <span>~ {{testimonials.0.name}} ~<br> - {{testimonials.0.institute}} </span></li> - <li>{{testimonials.4.message}} <br><br> - <span>~ {{testimonials.4.name}} ~ <br> - {{testimonials.4.institute}}</span></li> - <li>{{testimonials.3.message}} <br><br> - <span>~ {{testimonials.3.name}} ~ <br> - {{testimonials.3.institute}}</span></li> - </div> - -</div> - -<div class="row" id="r7"> - -</div> - -<div class="row" id="r8"> - - <div class="col-md-4" id="r8_c1" > - <br> <br> - <img src="{{ URL_ROOT}}/static/workshop_app/img/fossee_logo_iitb.png" > - </div> - - <div class="col-md-4" id="r8_c2" > - <br> <br> - FOSSEE, - IIT-Bombay <br>Mumbai, India <br> - Phone: (+91) 22 2576 4133 <br> - Email: workshops[at]fossee[dot]in - </div> - - <div class="col-md-4" id="r8_c3" > - <div id="social"> - <br> <br> - <a href="https://www.facebook.com/FOSSEENMEICT/" target="_blank" class="fa fa-facebook"></a> - <a href="https://plus.google.com/u/0/104012350840765676803" target="_blank" class="fa fa-google"></a> - <a href="https://www.youtube.com/channel/UCMtt6exSCmZI7JU73S6Wz_A" target="_blank" class="fa fa-youtube"></a> - </div> - </div> - - <div class="col-md-12" id="r8_c4"> - <hr> - The FOSSEE project is funded by the National Mission on Education through ICT, MHRD, Government of India. <br> - This work is licensed under a Creative Commons Attribution-ShareAlike 4.0 International License - - </div> -</div> - -</body> -</html> diff --git a/workshop_app/templates/workshop_app/view_workshoptype_details.html b/workshop_app/templates/workshop_app/view_workshoptype_details.html index 337595a..e488561 100644 --- a/workshop_app/templates/workshop_app/view_workshoptype_details.html +++ b/workshop_app/templates/workshop_app/view_workshoptype_details.html @@ -17,7 +17,7 @@ <li><a href="{{ URL_ROOT }}/create_workshop/">Create Workshop</a></li> <li><a href="{{ URL_ROOT }}/view_workshoptype_list/">Workshop List</a></li> <li><a href="{{ URL_ROOT }}/my_workshops/">My Workshops</a></li> - <li><a href="{{ URL_ROOT }}/workshop_stats/">Workshop Stats</a></li> + <li><a href="{{ URL_ROOT }}/statistics/">Workshop Stats</a></li> <li><a href="{{ URL_ROOT }}/statistics/profile_stats/" >Profile Stats</a></li> </ul> diff --git a/workshop_app/templates/workshop_app/view_workshoptype_list.html b/workshop_app/templates/workshop_app/view_workshoptype_list.html index 019fa8b..10d4351 100644 --- a/workshop_app/templates/workshop_app/view_workshoptype_list.html +++ b/workshop_app/templates/workshop_app/view_workshoptype_list.html @@ -81,7 +81,7 @@ <li><a href="{{ URL_ROOT }}/create_workshop/">Create Workshop</a></li> <li class="active"><a href="{{ URL_ROOT }}/view_workshoptype_list/">Workshop List</a></li> <li><a href="{{ URL_ROOT }}/my_workshops/">My Workshops</a></li> - <li><a href="{{ URL_ROOT }}/workshop_stats/">Workshop Stats</a></li> + <li><a href="{{ URL_ROOT }}/statistics/">Workshop Stats</a></li> <li><a href="{{ URL_ROOT }}/statistics/profile_stats/" >Profile Stats</a></li> </ul> |