3312 |
idir |
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="<?php echo date('Y-m-d', time()); ?>" 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; ?>
|
3333 |
idir |
55 |
<option value="autre"><?php echo $general['autre-espece']; ?></option>
|
3312 |
idir |
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>
|
3333 |
idir |
64 |
<?php echo $general['autre-espece']; ?>
|
3312 |
idir |
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 |
<div id="bouton-saisir-lichens" class="btn btn-info mb-3" data-load="lichens">
|
|
|
128 |
<i class="far fa-snowflake"></i> <?php echo $resume['saisir-lichens']; ?>
|
|
|
129 |
</div>
|
|
|
130 |
<!-- Messages d'erreur du formulaire -->
|
|
|
131 |
<div class="row">
|
|
|
132 |
<div class="zone-alerte">
|
|
|
133 |
<div id="dialogue-bloquer-creer-obs" class="alert alert-warning alert-block hidden">
|
|
|
134 |
<a class="close">×</a>
|
|
|
135 |
<h4 class="alert-heading"><?php echo $resume['alert10max']; ?></h4>
|
|
|
136 |
<p><?php echo $resume['alert10max-desc']; ?></p>
|
|
|
137 |
</div>
|
|
|
138 |
<div id="dialogue-form-invalide" class="alert alert-warning alert-block hidden">
|
|
|
139 |
<a class="close">×</a>
|
|
|
140 |
<h4 class="alert-heading"><?php echo $resume['alertchp']; ?></h4>
|
|
|
141 |
<p><?php echo $resume['alertchp-desc']; ?></p>
|
|
|
142 |
</div>
|
|
|
143 |
<div id="dialogue-taxon-or-image" class="alert alert-warning alert-block hidden">
|
|
|
144 |
<a class="close">×</a>
|
|
|
145 |
<h4 class="alert-heading"><?php echo $observation['alert-img-tax-title']; ?></h4>
|
|
|
146 |
<p><?php echo $plantes['alert-img-tax']; ?></p>
|
|
|
147 |
</div>
|
|
|
148 |
</div>
|
|
|
149 |
</div>
|
|
|
150 |
|
|
|
151 |
<!-- Affiche le tableau récapitualif des observations ajoutées -->
|
|
|
152 |
<div id="zone-liste-obs" class="">
|
|
|
153 |
<div id="bloc-controle-liste-obs" class="alert alert-info">
|
|
|
154 |
<h2 class="transmission-title"><strong><?php echo $resume['titre']; ?> <span class="obs-nbre badge badge-info">0</span></strong></h2>
|
|
|
155 |
<button id="transmettre-obs" class="btn btn-primary has-tooltip" data-toggle="tooltip" disabled="disabled"
|
3313 |
idir |
156 |
title="<?php echo $resume['trans-title']; ?>" type="button">
|
3312 |
idir |
157 |
<?php echo $general['enregistrer']; ?>
|
|
|
158 |
</button>
|
|
|
159 |
</div>
|
|
|
160 |
<div id="liste-obs" ></div>
|
|
|
161 |
<div class="row">
|
|
|
162 |
<div class="zone-alerte">
|
|
|
163 |
<div id="dialogue-zero-obs" class="alert alert-block hidden">
|
|
|
164 |
<a class="close">×</a>
|
|
|
165 |
<h4 class="alert-heading"><?php echo $resume['alert0obs']; ?></h4>
|
|
|
166 |
<p><?php echo $resume['alert0obs-desc']; ?></p>
|
|
|
167 |
</div>
|
|
|
168 |
<div id="dialogue-obs-transaction-ok" class="alert alert-success alert-block hidden">
|
|
|
169 |
<a class="close">×</a>
|
|
|
170 |
<h4 class="alert-heading"><?php echo $resume['info-trans']; ?></h4>
|
|
|
171 |
<div class="alert-txt"></div>
|
|
|
172 |
</div>
|
|
|
173 |
<div id="dialogue-obs-transaction-ko" class="alert alert-error alert-block hidden">
|
|
|
174 |
<a class="close">×</a>
|
|
|
175 |
<h4 class="alert-heading"><?php echo $resume['alerttrans']; ?></h4>
|
|
|
176 |
<div class="alert-txt"></div>
|
|
|
177 |
</div>
|
|
|
178 |
</div>
|
|
|
179 |
</div>
|
|
|
180 |
</div>
|
|
|
181 |
|
|
|
182 |
<!-- Fenêtres modales -->
|
|
|
183 |
<div id="chargement" class="modal-fenetre hidden">
|
|
|
184 |
<div id="chargement-centrage" class="modal-contenu">
|
|
|
185 |
<div class="progress progress-striped active">
|
|
|
186 |
<div id="barre-progression-upload" class="progress-bar progress-bar-striped" role="progressbar" aria-valuenow="0" aria-valuemin="0" aria-valuemax="10" style="">
|
|
|
187 |
<span class="sr-only">0/10 <?php echo $resume['nbobs']; ?></span>
|
|
|
188 |
</div>
|
|
|
189 |
</div>
|
|
|
190 |
<p id="chargement-txt">
|
|
|
191 |
<?php echo $resume['transencours']; ?>
|
|
|
192 |
</p>
|
|
|
193 |
</div>
|
|
|
194 |
</div>
|
|
|
195 |
|
|
|
196 |
<!-- Templates HTML -->
|
|
|
197 |
<div id="tpl-transmission-ok" class="hidden">
|
|
|
198 |
<p class="msg"><?php echo $resume['transok']; ?></p>
|
|
|
199 |
</div>
|
|
|
200 |
<div id="tpl-transmission-ko" class="hidden">
|
|
|
201 |
<p class="msg"><?php echo $resume['transko']; ?></p>
|
|
|
202 |
</div>
|
|
|
203 |
</div><!-- fin plantes zone résumé obs ( =zone de droite ) -->
|
|
|
204 |
</div>
|
|
|
205 |
<script type="text/javascript">
|
|
|
206 |
//<![CDATA[
|
|
|
207 |
$( document ).ready( function() {
|
|
|
208 |
releve = null;
|
|
|
209 |
lichens = null;
|
|
|
210 |
plantes = null;
|
|
|
211 |
plantes = new PlantesApa();
|
|
|
212 |
|
|
|
213 |
// La présence du parametre 'debug' dans l'URL enclenche le débogage
|
|
|
214 |
plantes.debug = <?php echo isset( $_GET['debug'] ) ? 'true' : 'false'; ?>;
|
|
|
215 |
// La présence du parametre 'html5' dans l'URL enclenche les fonctions avancées HTML5
|
|
|
216 |
plantes.html5 = <?php echo isset($_GET['html5']) ? 'true' : 'false'; ?>;
|
|
|
217 |
// Mot-clé du widget/projet
|
|
|
218 |
plantes.tagProjet = "WidgetApa,plantes";
|
|
|
219 |
// Mots-clés à ajouter aux images
|
|
|
220 |
plantes.tagImg = "<?php echo isset($_GET['tag-img']) ? $_GET['tag-img'] : ''; ?>";
|
|
|
221 |
plantes.separationTagImg = "<?php echo isset($_GET['motcle']) && isset($_GET['tag-img']) ? ',' : ''; ?>";
|
|
|
222 |
plantes.tagImg = <?php echo isset($_GET['motcle']) ? "'".$_GET['motcle']."' + plantes.separationTagImg + plantes.tagImg" : 'plantes.tagImg'; ?>;
|
|
|
223 |
// Mots-clés à ajouter aux observations
|
|
|
224 |
plantes.tagObs = "<?php echo isset($_GET['tag-obs']) ? $_GET['tag-obs'] : ''; ?>";
|
|
|
225 |
plantes.separationTagObs = "<?php echo isset($_GET['projet']) && isset($_GET['tag-obs']) ? ',' : ''; ?>";
|
|
|
226 |
plantes.tagObs = <?php echo isset($_GET['projet']) ? "'".$_GET['projet']."' + plantes.separationTagObs + plantes.tagObs" : 'plantes.tagObs'; ?>;
|
|
|
227 |
// URL du web service réalisant l'insertion des données dans la base du CEL.
|
|
|
228 |
plantes.serviceSaisieUrl = "<?php echo $url_ws_apa; ?>";
|
|
|
229 |
|
|
|
230 |
// URL de l'icône du chargement en cours d'une image
|
|
|
231 |
plantes.chargementImageIconeUrl = "<?php echo $url_base; ?>img/icones/chargement-image.gif";
|
|
|
232 |
// URL de l'icône pour une photo manquante
|
|
|
233 |
plantes.pasDePhotoIconeUrl = "<?php echo $url_base; ?>img/icones/pasdephoto.png";
|
|
|
234 |
|
|
|
235 |
// Code du référentiel utilisé pour les nom scientifiques.
|
|
|
236 |
plantes.nomSciReferentiel = "<?php echo strtolower( $widget['referentiel'] ); ?>";
|
|
|
237 |
// Nombre d'élément dans les listes d'auto-complétion
|
|
|
238 |
plantes.autocompletionElementsNbre = 20;
|
|
|
239 |
// Indication de la présence d'un référentiel imposé
|
|
|
240 |
plantes.referentielImpose = "<?php echo $referentiel_impose; ?>";
|
|
|
241 |
|
|
|
242 |
// URL du web service permettant l'auto-complétion des noms scientifiques
|
|
|
243 |
plantes.serviceAutocompletionNomSciUrl = "<?php echo $widget['especes']['url_ws_autocompletion_ns']; ?>?"+
|
|
|
244 |
"masque={masque}&"+
|
|
|
245 |
"recherche=etendue&"+
|
|
|
246 |
"retour.champs=famille,nom_retenu,nom_retenu_complet,num_taxonomique,nom_retenu.id&"+
|
|
|
247 |
"ns.structure=au&"+
|
|
|
248 |
"navigation.limite=" + plantes.autocompletionElementsNbre;
|
|
|
249 |
// Squelette d'URL du web service permettant l'auto-complétion des noms scientifiques
|
|
|
250 |
plantes.serviceAutocompletionNomSciUrlTpl = "<?php echo $widget['especes']['url_ws_autocompletion_ns_tpl']; ?>?"+
|
|
|
251 |
"masque={masque}&"+
|
|
|
252 |
"recherche=etendue&"+
|
|
|
253 |
"retour.champs=famille,nom_retenu,nom_retenu_complet,num_taxonomique,nom_retenu.id&"+
|
|
|
254 |
"retour.tri=alpharet&"+ // tri "à la CeL"
|
|
|
255 |
"ns.structure=au&"+
|
|
|
256 |
"navigation.limite=" + plantes.autocompletionElementsNbre;
|
|
|
257 |
// Nombre d'observations max autorisé avant transmission
|
|
|
258 |
plantes.obsMaxNbre = 10;
|
|
|
259 |
// Durée d'affichage en milliseconde des messages d'informations
|
|
|
260 |
plantes.dureeMessage = 10000;
|
|
|
261 |
|
|
|
262 |
// Initialisation du bousin
|
|
|
263 |
plantes.init();
|
|
|
264 |
});
|
|
|
265 |
//]]>
|
|
|
266 |
</script>
|
|
|
267 |
</div>
|