mirror of
https://github.com/osmarks/mycorrhiza.git
synced 2024-12-04 18:19:54 +00:00
38 lines
1.3 KiB
HTML
38 lines
1.3 KiB
HTML
|
{{/* TODO: translate title? */}}
|
||
|
{{define "title"}}Change password{{end}}
|
||
|
{{define "body"}}
|
||
|
<main class="main-width form-wrap">
|
||
|
{{if .Form.HasError}}
|
||
|
<div class="notice notice--error">
|
||
|
<strong>{{template "error"}}:</strong>
|
||
|
{{.Form.Error}}
|
||
|
</div>
|
||
|
{{end}}
|
||
|
|
||
|
<h2>{{block "change password" .}}Change password{{end}}</h2>
|
||
|
|
||
|
{{if eq .U.Source "local"}}
|
||
|
<form action="/settings/change-password" method="post">
|
||
|
<div class="form-field">
|
||
|
<label for="current_pass">{{block "current password" .}}Current password{{end}}</label>
|
||
|
<input required type="password" autocomplete="current-password" id="current_pass" name="current_password">
|
||
|
<br>
|
||
|
<br>
|
||
|
<label for="pass">{{block "password" .}}Password{{end}}</label>
|
||
|
<input required type="password" autocomplete="new-password" id="pass" name="password">
|
||
|
<br>
|
||
|
<br>
|
||
|
<label for="pass_confirm">{{block "confirm password" .}}Confirm password{{end}}</label>
|
||
|
<input required type="password" autocomplete="new-password" id="pass_confirm" name="password_confirm">
|
||
|
</div>
|
||
|
|
||
|
<div class="form-field">
|
||
|
<input class="btn" type="submit" value='{{block "submit" .}}Submit{{end}}'>
|
||
|
</div>
|
||
|
</form>
|
||
|
{{else}}
|
||
|
<p>{{block "non local password change" .}}Non-local accounts cannot have their passwords changed.{{end}}</p>
|
||
|
{{end}}
|
||
|
</main>
|
||
|
{{end}}
|