3402 |
delphine |
1 |
<div id="zone-plantes" class="bloc-top">
|
|
|
2 |
<h2><?php echo $plantes['titre']; ?></h2>
|
|
|
3 |
<div id="bouton-poursuivre" class="btn btn-success hidden mb-3" data-load="plantes">
|
|
|
4 |
<i class="far fa-plus-square"></i> <?php echo $plantes['poursuivre-plantes']; ?>
|
|
|
5 |
</div>
|
|
|
6 |
<div class="row">
|
|
|
7 |
<div id="bloc-gauche" class="col-md-6">
|
|
|
8 |
<div id="bloc-form-plantes" class="">
|
|
|
9 |
<form id="form-plantes" role="form" autocomplete="off">
|
|
|
10 |
<div class="control-group">
|
|
|
11 |
<label for="choisir-arbre" class="col-sm-8 obligatoire" title="<?php echo $plantes['arbre-title']; ?>">
|
|
|
12 |
<i class="fas fa-tree" aria-hidden="true"></i>
|
|
|
13 |
<?php echo $general['arbre']; ?>
|
|
|
14 |
</label>
|
|
|
15 |
<div class="col-sm-8 mb-3">
|
|
|
16 |
<select id="choisir-arbre" name="choisir-arbre" class="choisir-arbre form-control custom-select has-tooltip" data-toggle="tooltip" title="<?php echo $plantes['arbre-title']; ?>" required>
|
|
|
17 |
<option value="" selected hidden><?php echo $general['numero-arbre']; ?></option>
|
|
|
18 |
</select>
|
|
|
19 |
</div>
|
|
|
20 |
</div>
|
|
|
21 |
|
|
|
22 |
<div class="control-group">
|
|
|
23 |
<label for="obs-date" class="col-sm-8 obligatoire">
|
|
|
24 |
<i class="fa fa-calendar" aria-hidden="true"></i>
|
|
|
25 |
<?php echo $general['date']; ?>
|
|
|
26 |
</label>
|
|
|
27 |
<div class="col-sm-8 mb-3">
|
|
|
28 |
<input type="date" id="obs-date" name="obs-date" class="form-control" max="" placeholder="jj/mm/aaaa" required>
|
|
|
29 |
</div>
|
|
|
30 |
</div>
|
|
|
31 |
|
|
|
32 |
<input id="referentiel" name="referentiel" value="<?php echo $widget['referentiel']; ?>" type="hidden">
|
|
|
33 |
|
|
|
34 |
<div id="bloc-taxon" class="control-group">
|
|
|
35 |
<label for="taxon-liste" class="col-sm-8 obligatoire" title="">
|
|
|
36 |
<i class="fa fa-leaf" aria-hidden="true"></i>
|
|
|
37 |
<?php echo $general['espece']; ?> (<?php echo $widget['referentiel']; ?>)
|
|
|
38 |
</label>
|
|
|
39 |
<div class="col-sm-8 mb-3">
|
|
|
40 |
<?php ksort( $widget['especes']['taxons'] ); ?>
|
|
|
41 |
<select id="taxon-liste" name="taxon-liste" class="form-control custom-select taxon-validation has-tooltip" data-toggle="tooltip" title="<?php echo $observation['liste-espece-title']; ?>">
|
|
|
42 |
<option class="choisir" value="inconnue" selected hidden><?php echo $general['choisir']; ?></option>
|
|
|
43 |
<?php foreach ($widget['especes']['taxons'] as $taxon) : ?>
|
|
|
44 |
<option
|
|
|
45 |
class="nom-sci"
|
|
|
46 |
value="<?php echo $taxon['nom_sel'];?>"
|
|
|
47 |
title="<?php echo $taxon['nom_fr'];?>"
|
|
|
48 |
data-num-nom-sel="<?php echo $taxon['num_nom_sel'];?>"
|
|
|
49 |
data-nom-ret="<?php echo $taxon['nom_ret'];?>"
|
|
|
50 |
data-num-nom-ret="<?php echo $taxon['num_nom_ret'];?>"
|
|
|
51 |
data-nt="<?php echo $taxon['num_taxon'];?>"
|
|
|
52 |
data-famille="<?php echo $taxon['famille'];?>"
|
|
|
53 |
><?php echo $taxon['nom_sel'];?></option>
|
|
|
54 |
<?php endforeach; ?>
|
|
|
55 |
<option value="autre"><?php echo $plantes['autre-espece']; ?></option>
|
|
|
56 |
</select>
|
|
|
57 |
<span for="taxon-liste" class="error" style="display: none;"><?php echo $observation['error-taxon'];?></span>
|
|
|
58 |
<input id="taxon" name="taxon" type="hidden" />
|
|
|
59 |
</div>
|
|
|
60 |
</div>
|
|
|
61 |
<div id="taxon-input-groupe" class="control-group hidden">
|
|
|
62 |
<label for="taxon-autre" class="col-sm-8" title="">
|
|
|
63 |
<i class="fab fa-pagelines" aria-hidden="true"></i>
|
|
|
64 |
<?php echo $plantes['autre-espece']; ?>
|
|
|
65 |
</label>
|
|
|
66 |
<div class="col-sm-8 mb-3">
|
|
|
67 |
<input id="taxon-autre" name="taxon-autre" class="form-control has-tooltip" type="text" data-toggle="tooltip" title="<?php echo $observation['espece-title']; ?>">
|
|
|
68 |
</div>
|
|
|
69 |
</div>
|
|
|
70 |
|
|
|
71 |
<div class="control-group">
|
|
|
72 |
<label for="certitude" class="col-sm-8 obligatoire">
|
|
|
73 |
<i class="fa fa-question" aria-hidden="true"></i>
|
|
|
74 |
<?php echo $general['certitude']; ?>
|
|
|
75 |
</label>
|
|
|
76 |
<div class="col-sm-8 mb-3">
|
|
|
77 |
<select id="certitude" name="certitude" class="form-control custom-select" required>
|
|
|
78 |
<option value="" hidden selected><?php echo $general['choisir']; ?></option>
|
|
|
79 |
<option class="aDeterminer" value="à determiner"><?php echo $general['certADet']; ?></option>
|
|
|
80 |
<option class="douteuse" value="douteuse"><?php echo $general['certDout']; ?></option>
|
|
|
81 |
<option class="certaine" value="certaine"><?php echo $general['certCert']; ?></option>
|
|
|
82 |
</select>
|
|
|
83 |
</div>
|
|
|
84 |
</div>
|
|
|
85 |
|
|
|
86 |
<div class="">
|
|
|
87 |
<label for="commentaire" class="col-sm-8">
|
|
|
88 |
<i class="fa fa-pen" aria-hidden="true"></i>
|
|
|
89 |
<?php echo $general['commentaires']; ?>
|
|
|
90 |
</label>
|
|
|
91 |
<div class="col-sm-8 mb-3">
|
|
|
92 |
<textarea id="commentaire" class="col-md-12" rows="7" name="commentaire"></textarea>
|
|
|
93 |
</div>
|
|
|
94 |
</div>
|
|
|
95 |
</form>
|
|
|
96 |
<form id="form-upload" class="form-horizontal" action="<?php echo $url_ws_upload ?>" method="post" enctype="multipart/form-data">
|
|
|
97 |
<div class="col-sm-8 mb-2 list-label and-help">
|
|
|
98 |
<i class="fa fa-images" aria-hidden="true"></i>
|
|
|
99 |
<?php echo $plantes['titre-photos']; ?>
|
|
|
100 |
</div>
|
|
|
101 |
<p id="miniature-plantes-info" class="col-sm-8">
|
|
|
102 |
<?php echo $image['aide']; ?>
|
|
|
103 |
</p>
|
|
|
104 |
<div id ="photos-conteneur" class="control-group col-sm-8">
|
|
|
105 |
<div id="bouton-fichier">
|
|
|
106 |
<label for="fichier" class="label-file btn btn-large btn-info mb-3" title="<?php echo $image['photos-title']; ?>">
|
|
|
107 |
<span class="label-text"><i class="fas fa-download"></i> <?php echo $image['ajouter']; ?></span>
|
|
|
108 |
<input type="file" id="fichier" name="fichier" class="input-file" accept="image/jpeg" multiple>
|
|
|
109 |
<input type="hidden" name="MAX_FILE_SIZE" value="5242880">
|
|
|
110 |
</label>
|
|
|
111 |
</div>
|
|
|
112 |
|
|
|
113 |
<div id="miniatures"></div>
|
|
|
114 |
<p class="miniature-msg" class="span12"> </p>
|
|
|
115 |
</div>
|
|
|
116 |
</form>
|
|
|
117 |
<!-- Bouton création d'une obs -->
|
|
|
118 |
<div class="col-sm-8 mb-3">
|
|
|
119 |
<div title="<?php echo $resume['creer-title']; ?>">
|
|
|
120 |
<button id="ajouter-obs" class="btn btn-primary"><i class="fas fa-step-forward"></i> <?php echo $general['suivant']; ?></button>
|
|
|
121 |
</div>
|
|
|
122 |
</div>
|
|
|
123 |
</div>
|
|
|
124 |
</div><!-- fin formulaire plantes -->
|
|
|
125 |
<!-- zone résumé obs plantes ( =zone de droite) -->
|
|
|
126 |
<div id="bloc-droite" class="col-md-6">
|
|
|
127 |
<!-- Messages d'erreur du formulaire -->
|
|
|
128 |
<div class="row">
|
|
|
129 |
<div class="zone-alerte">
|
|
|
130 |
<div id="dialogue-bloquer-creer-obs" class="alert alert-warning alert-block hidden">
|
|
|
131 |
<a class="close">×</a>
|
|
|
132 |
<h4 class="alert-heading"><?php echo $resume['alert10max']; ?></h4>
|
|
|
133 |
<p><?php echo $resume['alert10max-desc']; ?></p>
|
|
|
134 |
</div>
|
|
|
135 |
<div id="dialogue-form-invalide" class="alert alert-warning alert-block hidden">
|
|
|
136 |
<a class="close">×</a>
|
|
|
137 |
<h4 class="alert-heading"><?php echo $resume['alertchp']; ?></h4>
|
|
|
138 |
<p><?php echo $resume['alertchp-desc']; ?></p>
|
|
|
139 |
</div>
|
|
|
140 |
<div id="dialogue-taxon-or-image" class="alert alert-warning alert-block hidden">
|
|
|
141 |
<a class="close">×</a>
|
|
|
142 |
<h4 class="alert-heading"><?php echo $observation['alert-img-tax-title']; ?></h4>
|
|
|
143 |
<p><?php echo $plantes['alert-img-tax']; ?></p>
|
|
|
144 |
</div>
|
|
|
145 |
</div>
|
|
|
146 |
</div>
|
|
|
147 |
|
|
|
148 |
<!-- Affiche le tableau récapitualif des observations ajoutées -->
|
|
|
149 |
<div id="zone-liste-obs" class="">
|
|
|
150 |
<div id="bloc-controle-liste-obs" class="alert alert-info">
|
|
|
151 |
<h2 class="transmission-title"><strong><?php echo $resume['titre']; ?> <span class="obs-nbre badge badge-info">0</span></strong></h2>
|
|
|
152 |
<button id="transmettre-obs" class="btn btn-primary has-tooltip" data-toggle="tooltip" disabled="disabled"
|
|
|
153 |
title="<?php echo $resume['trans-title']; ?>" type="button">
|
|
|
154 |
<?php echo $general['enregistrer']; ?>
|
|
|
155 |
</button>
|
|
|
156 |
</div>
|
|
|
157 |
<div id="liste-obs" ></div>
|
|
|
158 |
<div class="row">
|
|
|
159 |
<div class="zone-alerte">
|
|
|
160 |
<div id="dialogue-zero-obs" class="alert alert-block hidden">
|
|
|
161 |
<a class="close">×</a>
|
|
|
162 |
<h4 class="alert-heading"><?php echo $resume['alert0obs']; ?></h4>
|
|
|
163 |
<p><?php echo $resume['alert0obs-desc']; ?></p>
|
|
|
164 |
</div>
|
|
|
165 |
<div id="dialogue-obs-transaction-ok" class="alert alert-success alert-block hidden">
|
|
|
166 |
<a class="close">×</a>
|
|
|
167 |
<h4 class="alert-heading"><?php echo $resume['info-trans']; ?></h4>
|
|
|
168 |
<div class="alert-txt"></div>
|
|
|
169 |
</div>
|
|
|
170 |
<div id="dialogue-obs-transaction-ko" class="alert alert-error alert-block hidden">
|
|
|
171 |
<a class="close">×</a>
|
|
|
172 |
<h4 class="alert-heading"><?php echo $resume['alerttrans']; ?></h4>
|
|
|
173 |
<div class="alert-txt"></div>
|
|
|
174 |
</div>
|
|
|
175 |
</div>
|
|
|
176 |
</div>
|
|
|
177 |
</div>
|
|
|
178 |
|
|
|
179 |
<!-- Fenêtres modales -->
|
|
|
180 |
<div id="chargement" class="modal-fenetre hidden">
|
|
|
181 |
<div id="chargement-centrage" class="modal-contenu">
|
|
|
182 |
<div class="progress progress-striped active">
|
|
|
183 |
<div id="barre-progression-upload" class="progress-bar progress-bar-striped" role="progressbar" aria-valuenow="0" aria-valuemin="0" aria-valuemax="10" style="">
|
|
|
184 |
<span class="sr-only">0/10 <?php echo $resume['nbobs']; ?></span>
|
|
|
185 |
</div>
|
|
|
186 |
</div>
|
|
|
187 |
<p id="chargement-txt">
|
|
|
188 |
<?php echo $resume['transencours']; ?>
|
|
|
189 |
</p>
|
|
|
190 |
</div>
|
|
|
191 |
</div>
|
|
|
192 |
|
|
|
193 |
<!-- Templates HTML -->
|
|
|
194 |
<div id="tpl-transmission-ok" class="hidden">
|
|
|
195 |
<p class="msg"><?php echo $resume['transok']; ?></p>
|
|
|
196 |
</div>
|
|
|
197 |
<div id="tpl-transmission-ko" class="hidden">
|
|
|
198 |
<p class="msg"><?php echo $resume['transko']; ?></p>
|
|
|
199 |
</div>
|
|
|
200 |
</div><!-- fin plantes zone résumé obs ( =zone de droite ) -->
|
|
|
201 |
</div>
|
|
|
202 |
<script type="text/javascript">
|
|
|
203 |
//<![CDATA[
|
|
|
204 |
$( document ).ready( function() {
|
|
|
205 |
releve = null;
|
|
|
206 |
plantes = null;
|
|
|
207 |
plantes = new PlantesStreets();
|
|
|
208 |
|
|
|
209 |
// La présence du parametre 'debug' dans l'URL enclenche le débogage
|
|
|
210 |
plantes.debug = <?php echo isset( $_GET['debug'] ) ? 'true' : 'false'; ?>;
|
|
|
211 |
// La présence du parametre 'html5' dans l'URL enclenche les fonctions avancées HTML5
|
|
|
212 |
plantes.html5 = <?php echo isset($_GET['html5']) ? 'true' : 'false'; ?>;
|
|
|
213 |
// Mot-clé du widget/projet
|
3409 |
idir |
214 |
plantes.tagProjet = "WidgetSaisie,streets,plantes";
|
3402 |
delphine |
215 |
// Mots-clés à ajouter aux images
|
|
|
216 |
plantes.tagImg = "<?php echo isset($_GET['tag-img']) ? $_GET['tag-img'] : ''; ?>";
|
|
|
217 |
plantes.separationTagImg = "<?php echo isset($_GET['motcle']) && isset($_GET['tag-img']) ? ',' : ''; ?>";
|
|
|
218 |
plantes.tagImg = <?php echo isset($_GET['motcle']) ? "'".$_GET['motcle']."' + plantes.separationTagImg + plantes.tagImg" : 'plantes.tagImg'; ?>;
|
|
|
219 |
// Mots-clés à ajouter aux observations
|
|
|
220 |
plantes.tagObs = "<?php echo isset($_GET['tag-obs']) ? $_GET['tag-obs'] : ''; ?>";
|
|
|
221 |
plantes.separationTagObs = "<?php echo isset($_GET['projet']) && isset($_GET['tag-obs']) ? ',' : ''; ?>";
|
|
|
222 |
plantes.tagObs = <?php echo isset($_GET['projet']) ? "'".$_GET['projet']."' + plantes.separationTagObs + plantes.tagObs" : 'plantes.tagObs'; ?>;
|
|
|
223 |
// URL du web service réalisant l'insertion des données dans la base du CEL.
|
|
|
224 |
plantes.serviceSaisieUrl = "<?php echo $url_ws_streets; ?>";
|
|
|
225 |
|
|
|
226 |
// URL de l'icône du chargement en cours d'une image
|
|
|
227 |
plantes.chargementImageIconeUrl = "<?php echo $url_base; ?>img/icones/chargement-image.gif";
|
|
|
228 |
// URL de l'icône pour une photo manquante
|
|
|
229 |
plantes.pasDePhotoIconeUrl = "<?php echo $url_base; ?>img/icones/pasdephoto.png";
|
|
|
230 |
|
|
|
231 |
// Code du référentiel utilisé pour les nom scientifiques.
|
|
|
232 |
plantes.nomSciReferentiel = "<?php echo strtolower( $widget['referentiel'] ); ?>";
|
|
|
233 |
// Nombre d'élément dans les listes d'auto-complétion
|
|
|
234 |
plantes.autocompletionElementsNbre = 20;
|
|
|
235 |
// Indication de la présence d'un référentiel imposé
|
|
|
236 |
plantes.referentielImpose = "<?php echo $referentiel_impose; ?>";
|
|
|
237 |
|
|
|
238 |
// URL du web service permettant l'auto-complétion des noms scientifiques
|
|
|
239 |
plantes.serviceAutocompletionNomSciUrl = "<?php echo $widget['especes']['url_ws_autocompletion_ns']; ?>?"+
|
|
|
240 |
"masque={masque}&"+
|
|
|
241 |
"recherche=etendue&"+
|
|
|
242 |
"retour.champs=famille,nom_retenu,nom_retenu_complet,num_taxonomique,nom_retenu.id&"+
|
|
|
243 |
"ns.structure=au&"+
|
|
|
244 |
"navigation.limite=" + plantes.autocompletionElementsNbre;
|
|
|
245 |
// Squelette d'URL du web service permettant l'auto-complétion des noms scientifiques
|
|
|
246 |
plantes.serviceAutocompletionNomSciUrlTpl = "<?php echo $widget['especes']['url_ws_autocompletion_ns_tpl']; ?>?"+
|
|
|
247 |
"masque={masque}&"+
|
|
|
248 |
"recherche=etendue&"+
|
|
|
249 |
"retour.champs=famille,nom_retenu,nom_retenu_complet,num_taxonomique,nom_retenu.id&"+
|
|
|
250 |
"retour.tri=alpharet&"+ // tri "à la CeL"
|
|
|
251 |
"ns.structure=au&"+
|
|
|
252 |
"navigation.limite=" + plantes.autocompletionElementsNbre;
|
|
|
253 |
// Nombre d'observations max autorisé avant transmission
|
|
|
254 |
plantes.obsMaxNbre = 10;
|
|
|
255 |
// Durée d'affichage en milliseconde des messages d'informations
|
|
|
256 |
plantes.dureeMessage = 10000;
|
|
|
257 |
|
|
|
258 |
// Initialisation du bousin
|
|
|
259 |
plantes.init();
|
|
|
260 |
});
|
|
|
261 |
//]]>
|
|
|
262 |
</script>
|
|
|
263 |
</div>
|