Commit 7797ea9ccdeb0df7b2ee305bb17a25c705c63332

Authored by Geoffrey PREUD'HOMME
1 parent 5f2f48c7

[Connect] Ajout bouton afficher mot de passe

(flemme de me lancer dans un gros truc)
Showing 2 changed files with 13 additions and 6 deletions   Show diff stats
@@ -10,9 +10,14 @@ @@ -10,9 +10,14 @@
10 </div> 10 </div>
11 11
12 <div class="form-group"> 12 <div class="form-group">
13 - <label class="col-sm-2 control-label" for="entrer_mot_de_passe_3">Mot de passe</label> <!-- ajouter la posibilité d'afficher le mot de passe --> 13 + <label class="col-sm-2 control-label" for="entrer_mot_de_passe_3">Mot de passe</label>
14 <div class="col-sm-10"> 14 <div class="col-sm-10">
15 - <input type="password" class="form-control" id="entrer_mot_de_passe_3" placeholder="Votre mot de passe"> 15 + <div class="input-group">
  16 + <input type="password" class="form-control" id="entrer_mot_de_passe_3" placeholder="Votre mot de passe">
  17 + <span class="input-group-btn">
  18 + <button id="afficherMotDePasse" type="button" class="btn btn-default"><span class="glyphicon glyphicon glyphicon-eye-open"></span> Afficher</button>
  19 + </span>
  20 + </div>
16 </div> 21 </div>
17 </div> 22 </div>
18 23
@@ -20,7 +25,7 @@ @@ -20,7 +25,7 @@
20 <div class="col-sm-offset-2 col-sm-10"> 25 <div class="col-sm-offset-2 col-sm-10">
21 <div class="checkbox"> 26 <div class="checkbox">
22 <label> 27 <label>
23 - <input type="checkbox"> Rester connecter 28 + <input type="checkbox">Rester connecté
24 </label> 29 </label>
25 </div> 30 </div>
26 </div> 31 </div>
@@ -34,3 +39,8 @@ @@ -34,3 +39,8 @@
34 39
35 </form> 40 </form>
36 41
  42 +<script type="text/javascript">
  43 + // Affiche le mot de passe
  44 + document.getElementById('afficherMotDePasse').addEventListener('mousedown', function() {document.getElementById('entrer_mot_de_passe_3').type = 'text'})
  45 + document.addEventListener('mouseup', function() {document.getElementById('entrer_mot_de_passe_3').type = 'password'})
  46 +</script>
@@ -30,9 +30,6 @@ class Evenement @@ -30,9 +30,6 @@ class Evenement
30 30
31 # Titre 31 # Titre
32 $html .= '<h3 class="list-group-item-heading">'.$this->nom; 32 $html .= '<h3 class="list-group-item-heading">'.$this->nom;
33 - if ($this->annule) {  
34 - $html .= ' <span class="label label-danger">Annulé</span>';  
35 - }  
36 if ($this->p_annuler()) { 33 if ($this->p_annuler()) {
37 $html .= ' <button type="button" class="btn btn-danger"><span class="glyphicon glyphicon glyphicon-remove"></span></button>'; 34 $html .= ' <button type="button" class="btn btn-danger"><span class="glyphicon glyphicon glyphicon-remove"></span></button>';
38 } 35 }