2
{% extends "wlscheduling/base.html" %}
10
<script type="text/javascript">
11
document.addEventListener('DOMContentLoaded', function(){
12
var calendar = createCalandar();
13
addTimeZoneWarningIfNeeded();
14
addPreviousDateFromUser(calendar);
15
addOtherUsersAvailabilities();
18
document.getElementById('validate-btn').onclick = function () {
19
sendDataAsForm(calendar);
26
<div class="blogEntry">
27
<h2>Select the dates you'll be available on</h2>
28
{% include "wlscheduling/timezone-msg.html" %}
29
<div id="scheduling-datepicker"></div>
31
<div id="second-step" hidden="hidden">
32
<h2>Select the hours you'll be available on these dates</h2>
33
<div id="days-wrapper"></div>
34
<h2>Players that are currently available at the same hours as you</h2>
35
<div id="other-users-wrapper"></div>
36
<div id="no-user-to-display" hidden="hidden">Sorry, there are currently no players available at these hours. But your availabilities are noted, and another user might want to play with you!</div>
37
<button id="validate-btn">Update</button>
41
<!-- Templates for the js script -->
42
<!-- Template for the days of avaibility of the current user -->
43
<div id="day-template" class="day" hidden="hidden">
44
<div class="day-title"></div>
45
<div class="hours-title-wrapper">
46
{% for i in "xxxxxxxxxxxxxxxxxxxxxxxxx" %}
47
<p>{{ forloop.counter0 }}</p>
50
<div class="hours-wrapper">
51
{% for i in "xxxxxxxxxxxxxxxxxxxxxxxx" %}
52
<div class="hours"></div>
54
<div class="hidden-hour"></div>
58
<!-- Template for the days of avaibility of the other users -->
59
<div id="other-day-template" hidden="hidden">
60
<div class="day-title"></div>
61
<div id="hours-wrapper" class="hours-wrapper" >
62
{% for i in "xxxxxxxxxxxxxxxxxxxxxxxx" %}
63
<div class="hours" title="{{ forloop.counter0 }} to {{ forloop.counter0|add:1 }} hour"></div>
68
<div id="other-user-template" class="other-user-div" hidden="hidden">
69
<div class="title"></div>
72
<!-- Div to send django data to js file -->
73
<div id="django-data" user-time-zone="{{user.wlprofile.time_zone}}" day-to-fill = "{{ current_user_availabilities }}" users-to-fill="{{other_users_availabilities}}" csrf-token = "{% csrf_token %}"></div>