Skip to content
This repository was archived by the owner on Nov 6, 2021. It is now read-only.

Commit bf31bae

Browse files
committed
It was pointed out by a diaper bank that we do not have any styling on the invitation page. This fixes that.
1 parent f55e970 commit bf31bae

File tree

3 files changed

+22
-14
lines changed

3 files changed

+22
-14
lines changed
Lines changed: 20 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -1,16 +1,24 @@
1-
<h2><%= t 'devise.invitations.edit.header' %></h2>
1+
<div class="login-form">
2+
<h3 class="login-head"><i class="fa fa-lg fa-fw fa-user"></i>Set Your Password</h3>
3+
<%= form_for resource, :as => resource_name, :url => invitation_path(resource_name), :html => {:method => :put} do |f| %>
4+
<%= devise_error_messages! %>
5+
<%= f.hidden_field :invitation_token, readonly: true %>
6+
<div class="form-group">
27

3-
<%= form_for resource, :as => resource_name, :url => invitation_path(resource_name), :html => { :method => :put } do |f| %>
4-
<%= devise_error_messages! %>
5-
<%= f.hidden_field :invitation_token, readonly: true %>
8+
<% if f.object.class.require_password_on_accepting %>
9+
<p><%= f.label :password %><br/>
10+
<%= f.password_field :password, class: 'form-control' %></p>
611

7-
<% if f.object.class.require_password_on_accepting %>
8-
<p><%= f.label :password %><br />
9-
<%= f.password_field :password %></p>
12+
<p><%= f.label :password_confirmation %><br/>
13+
<%= f.password_field :password_confirmation, class: 'form-control' %></p>
14+
<% end %>
15+
</div>
1016

11-
<p><%= f.label :password_confirmation %><br />
12-
<%= f.password_field :password_confirmation %></p>
17+
<div class="form-group btn-container">
18+
<%= button_tag type: 'submit', class: "btn btn-primary btn-block" do %>
19+
<i class="fa fa-sign-in fa-lg fa-fw"></i>Create Account</button>
20+
<% end %>
21+
</div>
22+
<p>
1323
<% end %>
14-
15-
<p><%= f.submit t("devise.invitations.edit.submit_button") %></p>
16-
<% end %>
24+
</div>

config/environments/development.rb

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -33,7 +33,7 @@
3333
# Don't care if the mailer can't send.
3434
# Devise mailer
3535
config.action_mailer.raise_delivery_errors = true
36-
config.action_mailer.default_url_options = { host: "localhost", port: 3000 }
36+
config.action_mailer.default_url_options = { host: "partner.test" }
3737
config.action_mailer.delivery_method = :letter_opener
3838
config.action_mailer.perform_deliveries = true
3939

config/routes.rb

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
Rails.application.routes.draw do
2-
devise_for :users, controllers: { sessions: "users/sessions"}
2+
devise_for :users, controllers: { sessions: "users/sessions" }
33
# TODO: remove these two
44
resources :children do
55
post :active

0 commit comments

Comments
 (0)