blob: c8a89ed3a3632b71ae68785a2e475da7a6c72bdf (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
|
<div id="body_sidebar">
<h1><%=_('Show only...')%></h1>
<h2><%=_('Alphabet') %></h2>
<ul><li>
<%= render :partial => 'alphabet' %>
</li></ul>
<% first_row = true %>
<% for row in PublicBodyCategories::CATEGORIES_WITH_HEADINGS %>
<% if row.instance_of?(Array) %>
<li>
<%= link_to_unless (@tag == row[0]), row[1], list_public_bodies_url(:tag => row[0]) %>
</li>
<% else %>
<% if not first_row %>
</ul>
<% else %>
<% first_row = false %>
<% end %>
<h2><%=h row%></h2>
<ul>
<% end %>
<% end %>
</ul>
<p>
<%= _('<a href="%s">Are we missing a public authority?</a>.') % [help_requesting_path + '#missing_body'] %>
</p>
<p>
<%= link_to _('List of all authorities (CSV)'), all_public_bodies_csv_url() %>
</p>
</div>
<% @title = _("Public authorities - {{description}}", :description => @description) %>
<h1><%=@title%></h1>
<% form_tag(request.url, :method => "get") do %>
<div>
<%= label_tag(:public_body_query, _("Search:")) %>
<%= text_field_tag(:public_body_query, params[:public_body_query]) %>
<%= submit_tag(_("Search")) %>
</div>
<% end %>
<p class="subtitle">
<%= @public_bodies.size %> <%= _('in total') %>
(<%= _('<a href="%s">can\'t find the one you want?</a>') % [help_requesting_path + '#missing_body'] %>)
</p>
<%= render :partial => 'body_listing', :locals => { :public_bodies => @public_bodies } %>
<% if @tag.size == 1 && @public_bodies.size > 0 %>
<p><%= render :partial => 'alphabet' %></p>
<% end %>
<%= will_paginate(@public_bodies) %>
|