Basic email sending

This commit is contained in:
2020-04-24 09:27:07 +02:00
parent d65a7248d1
commit 81778121fb
18 changed files with 757 additions and 36 deletions

View File

@ -5,6 +5,7 @@
<div class="container has-text-centered">
<div class="columns">
<div class="column is-4 is-offset-4">
{{template "flash" .}}
<p class="has-text-black title">
Connexion
</p>
@ -16,11 +17,12 @@
<div class="field">
<div class="control">
<input class="input is-large" type="email"
id="email"
id="email" value="{{ .Email }}"
name="email" placeholder="john.doe@email.com" />
</div>
</div>
{{ .csrfField }}
<input name="challenge" type="hidden" value="{{ .LoginChallenge }}" />
<button type="submit" class="button is-link is-medium is-block is-fullwidth">Envoyer</button>
</form>
</div>

View File

@ -0,0 +1,30 @@
{{define "content"}}
<tr>
<td class="wrapper">
<table border="0" cellpadding="0" cellspacing="0">
<tr>
<td>
<p>Bonjour {{ .Email }}</p>
<p>Vous avez demandé à accéder à l'application "{{ .AppTitle }}". Cliquez sur le lien ci dessous pour vous authentifier. </p>
<table border="0" cellpadding="0" cellspacing="0" class="btn btn-primary">
<tbody>
<tr>
<td align="left">
<table border="0" cellpadding="0" cellspacing="0">
<tbody>
<tr>
<td> <a href="{{ .VerificationLink }}" target="_blank">Accéder à l'application</a> </td>
</tr>
</tbody>
</table>
</td>
</tr>
</tbody>
</table>
</td>
</tr>
</table>
</td>
</tr>
{{end}}
{{template "email" .}}