Browse Source

FIx more styling

pull/624/head
Kat 3 years ago
parent
commit
edd9c2ec3e
  1. 20
      app/views/users/show.html.erb
  2. 2
      app/views/users/toggle-active.html.erb

20
app/views/users/show.html.erb

@ -5,17 +5,17 @@
<h1 class="govuk-heading-l"> <h1 class="govuk-heading-l">
<%= content_for(:title) %> <%= content_for(:title) %>
</h1> </h1>
<% if current_user.can_toggle_active?(@user) %> <p>
<% if @user.active? %> <% if current_user.can_toggle_active?(@user) %>
<%= govuk_link_to "Deactivate user", "/users/#{@user.id}/deactivate" %> <% if @user.active? %>
<% else %> <%= govuk_link_to "Deactivate user", "/users/#{@user.id}/deactivate" %>
<p> <% else %>
<span class="app-!-colour-muted govuk-!-margin-right-2"> <span class="app-!-colour-muted govuk-!-margin-right-2">
This user has been deactivated. <%= govuk_link_to "Reactivate user", "/users/#{@user.id}/reactivate" %> This user has been deactivated. <%= govuk_link_to "Reactivate user", "/users/#{@user.id}/reactivate" %>
</span> </span>
</p> <% end %>
<% end %> <% end %>
<% end %> </p>
<h2 class="govuk-heading-m"> <h2 class="govuk-heading-m">
Personal details Personal details

2
app/views/users/toggle-active.html.erb

@ -16,7 +16,7 @@
<%= f.govuk_text_field :active, <%= f.govuk_text_field :active,
value: active_value %> value: active_value %>
</div> </div>
<%= f.govuk_submit "I’m sure - #{action} this user" %> <%= f.govuk_submit "I’m sure - #{action} this user", warning: action == "deactivate" %>
<p class="govuk-body"> <p class="govuk-body">
<%= govuk_link_to("No - I’ve changed my mind", user_path(@user)) %> <%= govuk_link_to("No - I’ve changed my mind", user_path(@user)) %>
</p> </p>

Loading…
Cancel
Save