aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--app/views/admin_public_body/_form.rhtml29
-rw-r--r--public/stylesheets/admin.css8
2 files changed, 29 insertions, 8 deletions
diff --git a/app/views/admin_public_body/_form.rhtml b/app/views/admin_public_body/_form.rhtml
index d5da64603..fdcf3e972 100644
--- a/app/views/admin_public_body/_form.rhtml
+++ b/app/views/admin_public_body/_form.rhtml
@@ -2,6 +2,25 @@
<!--[form:public_body]-->
+<div id="tag_help">
+ <h2>List of tags</h2>
+ <% first_row = true %>
+ <% for row in PublicBody.categories_with_headings %>
+ <% if row.instance_of?(Array) %>
+ <% if row[0] != 'other' %>
+ <strong><%= row[0] %></strong>=<%= row[1] %>
+ <br/>
+ <% end %>
+ <% elsif row != 'Miscellaneous' %>
+ <% if not first_row %>
+ <% else %>
+ <% first_row = false %>
+ <% end %>
+ <h3><%=h row%></h3>
+ <% end %>
+ <% end %>
+</div>
+
<p><label for="public_body_name">Name</label><br/>
<%= text_field 'public_body', 'name', :size => 60 %></p>
@@ -17,14 +36,8 @@
<p><label for="public_body_notes">Notes</label> (for users to consider when making FOI requests to the authority)<br/>
<%= text_area 'public_body', 'notes', :rows => 3, :cols => 60 %></p>
-<p><label for="public_body_tag_string">Tags (space separated:
- <% for category, description in PublicBody.categories_by_tag %>
- <% if category != "other" %>
- <strong><%= category %></strong>=<%= description %>;
- <% end %>
- <% end %>
-)</label><br/>
-<%= text_field 'public_body', 'tag_string', :size => 80 %></p>
+<p><label for="public_body_tag_string">Tags (space separated; see list of tags on the right)</label><br/>
+<%= text_field 'public_body', 'tag_string', :size => 60 %></p>
<p><label for="public_body_last_edit_comment">Comment for this edit</label> (put URL or other source of new info)<br/>
<%= text_area 'public_body', 'last_edit_comment', :rows => 2, :cols => 60 %></p>
diff --git a/public/stylesheets/admin.css b/public/stylesheets/admin.css
index 3123818c7..d35851b3b 100644
--- a/public/stylesheets/admin.css
+++ b/public/stylesheets/admin.css
@@ -37,4 +37,12 @@ form {
border: solid 1px red;
padding: 1em;
}
+#tag_help {
+ float: right;
+ width: 25%;
+}
+#tag_help, h2 {
+ margin-top: 0;
+}
+