Hr.FormController

The default implementation of FormController. If you want to override it, either direct your routes to your own implementation (if you want to just override a couple of actions), or implement YourApp.HrFormController with use Hr.BaseFormController.

Summary

Functions

Callback implementation for c:Plug.call/2

Confirms the email for the user

Reset the user's password

If the email exists, send a reset link

Check if the submitted credentials are valid, if they are, create a session

Create a new user if the email address isn't already taken

Destroy the session

Callback implementation for c:Plug.init/1

capture the requested new password from the user

Captures the email address to send a password reset link to

Display the login view and post the form to the next function

Display the signup form and post to the next function

redirect the user to the oauth provider's site so they can authenticate

Try to look a user up by identity, if none exists, create one and log them in

Functions

action(conn, opts)
call(conn, action)

Callback implementation for c:Plug.call/2.

confirmation(conn, map)

Confirms the email for the user

create_password_reset(conn, map)

Reset the user's password

create_password_reset_request(conn, map)

If the email exists, send a reset link

create_session(conn, map)

Check if the submitted credentials are valid, if they are, create a session

create_signup(conn, data)

Create a new user if the email address isn't already taken.

destroy_session(conn, )

Destroy the session

init(action)

Callback implementation for c:Plug.init/1.

new_password_reset(conn, map)

capture the requested new password from the user

new_password_reset_request(conn, )

Captures the email address to send a password reset link to

new_session(conn, )

Display the login view and post the form to the next function

new_signup(conn, )

Display the signup form and post to the next function

oauth_authorize(conn, map)

redirect the user to the oauth provider's site so they can authenticate

oauth_callback(conn, map)

Try to look a user up by identity, if none exists, create one and log them in.