Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- <%= form_for(resource, as: resource_name, url: session_path(resource_name)) do |f| %>
- <div><%= f.label :email %><br />
- <%= f.email_field :email, autofocus: true %></div>
- <div><%= f.label :password %><br />
- <%= f.password_field :password, autocomplete: "off" %></div>
- <div><%= f.submit "Sign in" %></div>
- <% end %>
- module ApplicationHelper
- def resource_name
- :user
- end
- def resource
- @resource ||= User.new
- end
- def devise_mapping
- @devise_mapping ||= Devise.mappings[:user]
- end
- end
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement