gvguichet/templates/passwd.html

42 lines
1.3 KiB
HTML
Raw Permalink Normal View History

2020-02-09 17:45:22 +01:00
{{define "title"}}Mot de passe |{{end}}
{{define "body"}}
2020-02-09 19:56:01 +01:00
<div class="d-flex">
<h4>Modifier mon mot de passe</h4>
<a class="ml-auto btn btn-info" href="/">Retour</a>
</div>
2020-02-09 17:45:22 +01:00
{{if .ErrorMessage}}
2020-02-09 19:56:01 +01:00
<div class="alert alert-danger mt-4">Impossible d'effectuer la modification.
2020-02-09 17:45:22 +01:00
<div style="font-size: 0.8em">{{ .ErrorMessage }}</div>
</div>
{{end}}
{{if .Success}}
2020-02-09 19:56:01 +01:00
<div class="alert alert-success mt-4">
2020-02-09 17:45:22 +01:00
Nouveau mot de passe enregistré.
</div>
{{else}}
2020-02-09 19:56:01 +01:00
<form method="POST" class="mt-4">
2020-02-09 17:45:22 +01:00
<div class="form-group">
<label for="password">Nouveau mot de passe :</label>
<input type="password" id="password" name="password" class="form-control" />
</div>
2020-02-09 19:56:01 +01:00
{{if .TooShortError}}
<div class="alert alert-warning">
Le mot de passe choisi est trop court (minimum 8 caractères).
</div>
{{end}}
2020-02-09 17:45:22 +01:00
<div class="form-group">
<label for="password2">Répéter le mot de passe :</label>
<input type="password" id="password2" name="password2" class="form-control" />
</div>
{{if .NoMatchError}}
<div class="alert alert-warning">
Les deux mots de passe entrés ne correspondent pas.
</div>
{{end}}
2020-02-09 19:56:01 +01:00
<button type="submit" class="btn btn-primary">Changer de mot de passe</button>
2020-02-09 17:45:22 +01:00
</form>
{{end}}
{{end}}