Implement basic login & registration forms
Some checks failed
continuous-integration/drone/push Build is failing

This commit is contained in:
2021-09-21 22:25:51 -05:00
parent 5940b6e2b3
commit a1d04d652e
22 changed files with 294 additions and 64 deletions

View File

@@ -8,5 +8,9 @@ block content
each error in errors
p.form-error-message #{error}
form(method='post' enctype='multipart/form-data')
block form
if formAction
form(method='post' enctype='multipart/form-data' action=formAction)
block form
else
form(method='post' enctype='multipart/form-data')
block form

View File

@@ -8,11 +8,11 @@ block heading
block form
.form-label-group
input#inputUsername.form-control(type='text' name='username' value=(formData ? formData.username : '') required placeholder='Username' autofocus)
input#inputUsername.form-control(type='text' name='identifier' value=(formData ? formData.username : '') required placeholder='Username' autofocus)
label(for='inputUsername') Username
.form-label-group
input#inputPassword.form-control(type='password' name='password' required placeholder='Password')
input#inputPassword.form-control(type='password' name='credential' required placeholder='Password')
label(for='inputPassword') Password
@@ -21,4 +21,4 @@ block form
.text-center
span.small Need an account? 
a(href='./register') Register here.
a(href=named('@auth.register')) Register here.

View File

@@ -0,0 +1,26 @@
extends ./form
block head
title Register | #{config('app.name', 'Extollo')}
block heading
| Register to continue
block form
.form-label-group
input#inputUsername.form-control(type='text' name='identifier' value=(formData ? formData.username : '') required placeholder='Username' autofocus)
label(for='inputUsername') Username
.form-label-group
input#inputPassword.form-control(type='password' name='credential' required placeholder='Password')
label(for='inputPassword') Password
.form-label-group
input#inputPasswordConfirm.form-control(type='password' name='credentialConfirm' required placeholder='Confirm Password')
label(for='inputPassword') Confirm Password
button.btn.btn-lg.btn-primary.btn-block.btn-login.text-uppercase.font-weight-bold.mb-2.form-submit-button(type='submit') Login
.text-center
span.small Have an account? 
a(href=named('@auth.login')) Login here.