]> git.openstreetmap.org Git - rails.git/blob - app/views/user_blocks/revoke.html.erb
Use user_path links. Fixes #1785
[rails.git] / app / views / user_blocks / revoke.html.erb
1 <% @title = t('user_block.revoke.title',
2               :block_on => h(@user_block.user.display_name),
3               :block_by => h(@user_block.creator.display_name)) %>
4
5 <% content_for :heading do %>
6   <h1><%= raw t('user_block.revoke.heading',
7                 :block_on => link_to(
8                                      h(@user_block.user.display_name),
9                                      user_path(@user_block.user)),
10                 :block_by => link_to(
11                                      h(@user_block.creator.display_name),
12                                      user_path(@user_block.creator))) %></h1>
13 <% end %>
14
15 <% if @user_block.ends_at > Time.now %>
16 <p><b>
17   <%= t('user_block.revoke.time_future', :time => distance_of_time_in_words_to_now(@user_block.ends_at)) %>
18 </b></p>
19
20 <%= form_for :revoke, :url => { :action => "revoke" } do |f| %>
21   <%= f.error_messages %>
22 <p>
23   <%= check_box_tag 'confirm', 'yes' %>
24   <%= label_tag 'confirm', t('user_block.revoke.confirm') %>
25 </p>
26 <p>
27   <%= submit_tag t('user_block.revoke.revoke') %>
28 </p>
29 <% end %>
30
31 <% else %>
32 <p>
33   <%= t('user_block.revoke.past', :time => distance_of_time_in_words_to_now(@user_block.ends_at)) %>
34 </p>
35 <% end %>