1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
{% extends "members/base.html" %}
{% load static %}
{% block additionnal_css %}
<link rel="stylesheet" href="{% static "css/inscriptions.css" %}?v=">
<style>
.shift[data-place="{{mag_place_string}}"], [data-select="{{mag_place_string}}"] {background: #c8deff;}
.shift[data-place="{{office_place_string}}"], [data-select="{{office_place_string}}"] {background: #f9b2ff;}
</style>
{{ block.super }}
{% endblock %}
{% block additionnal_scripts %}
<script type="text/javascript">
var type = {{type}},
context = 'inscription',
force_fn_hyphen = {% if force_firstname_hyphen %}true{% else %}false{% endif%},
max_chq_nb = {{max_chq_nb}};
{% if open_on_sunday %}
let open_on_sunday = true
{% endif %}
</script>
{% endblock %}
{% block content %}
<nav class="col-6 clearfix nav">
<div id="process_state" class="fl"></div>
<button id="create_new_coop" class="btn--primary fr">Nouvelle inscription</button>
<button id="coop_list_btn" class="btn--info fr" style="display:none;">Liste</button>
<button id="shift_calendar" class="btn--inverse fr">Vue créneaux</button>
</nav>
<section class="center" id="new_coop">
<div class="grid-1">
<div class="item-center">
<h2 class="title">
NOUVEAU MEMBRE
</h2>
<form id="coop_create" lang="fr">
{% if ask_for_sex %}
<p>
{% include "members/sex_input.html" %}
</p>
{% endif %}
<p>
<input type="text" placeholder="Nom" name="lastname" autocomplete="off" required />
<input type="text" placeholder="Prénom" name="firstname" autocomplete="off" required />
<input type="text" placeholder="email" name="email" value="" pattern="(?:[a-z0-9!#$%&'*+/=?^_`{|}~-]+(?:\.[a-z0-9!#$%&'*+/=?^_`{|}~-]+)*|(?:[\x01-\x08\x0b\x0c\x0e-\x1f\x21\x23-\x5b\x5d-\x7f]|\\[\x01-\x09\x0b\x0c\x0e-\x7f])*)@(?:(?:[a-z0-9](?:[a-z0-9-]*[a-z0-9])?\.)+[a-z0-9](?:[a-z0-9-]*[a-z0-9])?|\[(?:(?:25[0-5]|2[0-4][0-9]|[01]?[0-9][0-9]?)\.){3}(?:25[0-5]|2[0-4][0-9]|[01]?[0-9][0-9]?|[a-z0-9-]*[a-z0-9]:(?:[\x01-\x08\x0b\x0c\x0e-\x1f\x21-\x5a\x53-\x7f]|\\[\x01-\x09\x0b\x0c\x0e-\x7f])+)\])" required autocomplete="off" />
(*)
</p>
<p>
<input type="number" step="10" min="10" placeholder="Montant souscription" name="subs_cap" id="subs_cap" required/>
<select name="payment_meaning" id="payment_meaning" autocomplete="off" required >
<!-- autocomplete="off" is here to fix firefox bug for selected="selected" -->
<option value="" selected>Moyen de paiement</option>
{% for pm in payment_meanings %}
<option value="{{pm.code}}">{{pm.title}}</option>
{% endfor %}
</select>
<input type="number" min="1" placeholder="Nb de chèques" name="ch_qty" id="ch_qty" style="display:none;"/>
</p>
{% if input_barcode %}
<p>
<input type="text" name="m_barcode" id="m_barcode" maxlength="13" size="13" placeholder="Code barre" autocomplete="off" required/>
</p>
{% endif %}
<button class="btn--primary">Valider</button>
</form>
</div>
<div id="mail_generation">
(*) L'adresse mail étant obligatoire, si le nouveau membre n'en a pas, veuillez en créer une en cliquant sur le bouton suivant : <a class="btn--info" id="generate_email">+</a>
</div>
</div>
</section>
{% include "members/shift_template_choice.html" %}
<section class="grid-6 has-gutter" id="coop_registration_details">
<div class="col-6 menu txtcenter">
RÉSUMÉ DE L'ENREGISTREMENT
</div>
<div class="col-6 main_content txtcenter">
<h3>Félicitation ! Informations enregistrées.</h3>
<!--
<div class="numbox badge"></div>
<p>Pensez à inscrire ce numéro temporaire de coopérateur au crayon de papier sur les deux formulaires papier.</p>
-->
<p>Créneau choisi : <span class="shift_template"></span></p>
<p>Prochain service : <span class="next_shift"></span></p>
<button class="btn--primary" id="next_coop">Coopérateur.rice suivant.e !</button>
</div>
</section>
<section class="grid-6 has-gutter" id="coop_list_view">
<div class="col-6 menu txtcenter">
LISTE DES ENREGISTREMENTS
</div>
<div class="col-6 main_content txtcenter">
<table class="table--zebra" summary="">
<thead>
<tr>
<th scope="col">Coop.</th>
<th scope="col">Créneaux</th>
</tr>
</thead>
<tbody>
</tbody>
</table>
</div>
</section>
<script src="{% static 'js/pouchdb.min'|add:POUCHDB_VERSION|add:'.js' %}"></script>
<script type="text/javascript">
var couchdb_dbname = '{{db}}';
var couchdb_server = '{{couchdb_server}}' + couchdb_dbname;
var dbc = new PouchDB(couchdb_dbname);
var sync = PouchDB.sync(couchdb_dbname, couchdb_server, {
live: true,
retry: true,
auto_compaction: false
});
var mag_place_string = '{{mag_place_string}}';
var office_place_string = '{{office_place_string}}'
var max_begin_hour = '{{max_begin_hour}}'
var email_domain = '{{email_domain}}'
</script>
<script src="{% static "js/all_common.js" %}?v="></script>
<script src="{% static "js/common.js" %}?v="></script>
<script src="{% static "js/inscriptions.js" %}?v="></script>
{% endblock %}