fix issue with empty suggest item - it was the count of all objects that do _not_ have a term (facet.missing) in the text field.  ultimately the request made to Solr should not request for missing values on suggest lookups

git-svn-id: 3b1ff1236863b4d63a22e4dae568675c2e247730@511705 13f79535-47bb-0310-9956-ffa450edef68

<%
@values.each do |value|
  if value[1] > 0
-%>

 <%=value[0]%> (<%=value[1]%>)

<%
  end
end
-%>

<%
@values.each do |value|
%>

 <%=value[0]%> (<%=value[1]%>)

<%
end
%>


Use :method => :post instead of :post => true, as per deprecation.

<%
@body_class = 'change-form'
@content_class = 'colM'
@title = @object.new_record? ? "Add #{human_model.downcase}" : "Change #{human_model.downcase}"
@tools = []
@tools << link_to( "History", { :model => params[:model], :action => 'history', :id => params[:id] } ) if has_history?

admin_form_for params[:model], @object,
  :url => { :action => 'save', :model => params[:model], :id => @object.id } do |builder|

  builder.outer do
    builder.prologue do
    end
    model.active_admin_fieldsets.each do |set|
      set.build builder
    end

%>

<% unless @object.new_record? %>

<%= link_to 'Delete', { :action => 'delete', :model => params[:model], :id => @object.id }, { :class => 'deletelink', :method => :post, :confirm => "Are you sure you want to delete \"#{@object.to_label}\"?" } %>

<% end %>
<input type="submit" value="Save and add another" name="_addanother"  />
<input type="submit" value="Save and continue editing" name="_continue" />
<input type="submit" value="Save" class="default" />

<%

    builder.epilogue do
    end
  end
end
%>

<%
@body_class = 'change-form'
@content_class = 'colM'
@title = @object.new_record? ? "Add #{human_model.downcase}" : "Change #{human_model.downcase}"
@tools = []
@tools << link_to( "History", { :model => params[:model], :action => 'history', :id => params[:id] } ) if has_history?

admin_form_for params[:model], @object,
  :url => { :action => 'save', :model => params[:model], :id => @object.id } do |builder|

  builder.outer do
    builder.prologue do
    end
    model.active_admin_fieldsets.each do |set|
      set.build builder
    end

%>

<% unless @object.new_record? %>

<%= link_to 'Delete', { :action => 'delete', :model => params[:model], :id => @object.id }, { :class => 'deletelink', :post => true, :confirm => "Are you sure you want to delete \"#{@object.to_label}\"?" } %>

<% end %>
<input type="submit" value="Save and add another" name="_addanother"  />
<input type="submit" value="Save and continue editing" name="_continue" />
<input type="submit" value="Save" class="default" />

<%

    builder.epilogue do
    end
  end
end
%>


Prevent spiders from hitting the combination tool

<%= render( :partial => '/shared/article_tabs',
            :locals => { :selected => 1,
                         :article_id => @article.id }) %>

	      <%= link_to("articles",
	                  {:controller => 'article',
	                   :action => 'list',
                                :collection_id => @article.collection_id,
 		                 :ol => 'a_art_articles' }) %>

<%= @article.title %>

		  <% if @article.xml_text != nil && !@article.xml_text.empty? %>
		    <%= xml_to_html(@article.xml_text) %>
		  <% else %>
		    No Contents Provided
		  <% end %>

	<% if logged_in? %>

Possible Duplicates

				<% @article.possible_duplicates.each do |dup| %>
					<%= link_to(dup.title, :article_id => dup.id) %>
					<%= button_to("Combine",
									{ :action => 'combine',
									  :from_article_id => dup.id,
									  :article_id => @article.id},
									{ :title => "Combines #{dup.title} into #{@article.title}",
										:confirm => "Are you sure you want to delete #{dup.title} and change all links to point to #{@article.title}?"})%>

				<% end %>

	<% end %>

    <%= render :partial => 'article_links' %>

<%= render( :partial => '/shared/article_tabs',
            :locals => { :selected => 1,
                         :article_id => @article.id }) %>

	      <%= link_to("articles",
	                  {:controller => 'article',
	                   :action => 'list',
                                :collection_id => @article.collection_id,
 		                 :ol => 'a_art_articles' }) %>

<%= @article.title %>

		  <% if @article.xml_text != nil && !@article.xml_text.empty? %>
		    <%= xml_to_html(@article.xml_text) %>
		  <% else %>
		    No Contents Provided
		  <% end %>

Possible Duplicates

			<% @article.possible_duplicates.each do |dup| %>
				<%= link_to(dup.title, :article_id => dup.id) %>
				(<%= link_to("combine into #{@article.title}",
								{ :action => 'combine',
								  :from_article_id => dup.id,
								  :article_id => @article.id},
								{ :confirm => "Are you sure you want to delete #{dup.title} and change all links to point to #{@article.title}?"})%>)

			<% end %>

    <%= render :partial => 'article_links' %>


reverted, the patch before last was a mistake

<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01//EN" "http://www.w3.org/TR/html4/strict.dtd">

  <%= stylesheet_link_tag 'main' %>

free library

  <% if current_user %>

hello, <%= user_link current_user %>

<%= link_to 'edit your account', :controller => 'account' %>

<%= link_to 'log out', :controller => 'account', :action => 'logout' %>

  <% else %>

<%= link_to 'log in', :controller => 'account', :action => 'login' %>

<%= link_to 'new account', :controller => 'account', :action => 'signup' %>

  <% end %>

<%= link_to 'books', books_path %>

<%= link_to 'videos', videos_path %>

    <% if flash[:notice] %>

<%= flash[:notice].untaint %>

    <% elsif flash[:error] %>

<%= flash[:error].untaint %>

    <% end %>

    <%= yield  %>

<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01//EN" "http://www.w3.org/TR/html4/strict.dtd">

  <%= stylesheet_link_tag 'main' %>

free library

  <% if current_user %>

hello, <%= user_link current_user %>

<%= link_to 'edit your account', :controller => 'account' %>

  <% else %>

<%= link_to 'log in', :controller => 'account', :action => 'login' %>

  <% end %>

<%= link_to 'books', books_path %>

<%= link_to 'videos', videos_path %>

    <% if flash[:notice] %>

<%= flash[:notice].untaint %>

    <% elsif flash[:error] %>

<%= flash[:error].untaint %>

    <% end %>

    <%= yield  %>


Patch from Chris Anderton to fix comments approve/delete from Overview

git-svn-id: 4158f9403e16ea83fe8a6e07a45f1f3b56a747ab@3079 567b1171-46fb-0310-a4c9-b4bef9110e78

<% with_options :controller => 'articles', :id => event.article_id do |article| -%>
<li id="event-<%= event.id %>" class="event-comment<%= " shade" if shaded %>">
  <div id="comment-<%= event.comment_id %>">
  <%= link_to event.article.title, :controller => 'articles', :action => 'comments', :id => event.article_id, :anchor => "comment-#{event.comment_id}" %> received a comment.

  <%= event_time_for event, later %>
  <% unless event.body.blank? -%>

"<%= truncate strip_tags(event.body), 100 %>"

  <% end -%>

    — <%=h event.author %>

  <% if event.comment %>
  <% if event.comment.approved? -%>
      <%= link_to_remote 'Unapprove', :url => { :controller => 'admin/articles', :action => 'unapprove',       :id => event.article_id, :comment => event.comment_id } %> |
    <% else -%>
      <%= link_to_remote 'Approve',   :url => { :controller => 'admin/articles', :action => 'approve',         :id => event.article_id, :comment => event.comment_id } %> |
    <% end -%>
      <%= link_to_remote 'Delete',    :url => { :controller => 'admin/articles', :action => 'destroy_comment', :id => event.article_id, :comment => event.comment_id } %>
  <% end %>

<% end -%>

<% with_options :controller => 'articles', :id => event.article_id do |article| -%>
<li id="event-<%= event.id %>" class="event-comment<%= " shade" if shaded %>">
  <div id="comment-<%= event.comment_id %>">
  <%= link_to event.article.title, :controller => 'articles', :action => 'comments', :id => event.article_id, :anchor => "comment-#{event.comment_id}" %> received a comment.

  <%= event_time_for event, later %>
  <% unless event.body.blank? -%>

"<%= truncate strip_tags(event.body), 100 %>"

  <% end -%>

    — <%=h event.author %>

  <% if event.comment %>
  <% if event.comment.approved? -%>
      <%= link_to_remote 'Unapprove', :url => { :controller => 'admin/articles', :action => 'unapprove',       :id => event.article_id, :comment => event.comment_id } %> |
    <% else -%>
      <%= link_to_remote 'Approve',   :url => { :controller => 'admin/articles', :action => 'approve',         :id => @article, :comment => event.comment_id } %> |
    <% end -%>
      <%= link_to_remote 'Delete',    :url => { :controller => 'admin/articles', :action => 'destroy_comment', :id => @article, :comment => event.comment_id } %>
  <% end %>

<% end -%>


Add alt text

Add alt text

    <%  if not attachments.nil? and attachments.size > 0 %>

 <% attachments.each do |a| %>
                <% if ['application/pdf', 'application/msword', 'text/plain'].include?(a.content_type) %>
                    <img alt="Attachment" src="/images/icon_<%=a.content_type.sub('/', '_')%>_large.png" align="absmiddle">
                <% else %>
                    Attachment:
                <% end %>
                <%= link_to (TMail::Mail.get_part_file_name(a) || "download.bin"), get_attachment_url(:id => incoming_message.info_request_id,
                    :incoming_message_id => incoming_message.id, :part => a.url_part_number, :file_name =>
                    (TMail::Mail.get_part_file_name(a) || "download.bin")) %>

            <% end %>

    <% end %>

<%= body %>

    <%  if not attachments.nil? and attachments.size > 0 %>

 <% attachments.each do |a| %>
                <% if ['application/pdf', 'application/msword', 'text/plain'].include?(a.content_type) %>
                    <img src="/images/icon_<%=a.content_type.sub('/', '_')%>_large.png" align="absmiddle">
                <% else %>
                    Attachment:
                <% end %>
                <%= link_to (TMail::Mail.get_part_file_name(a) || "download.bin"), get_attachment_url(:id => incoming_message.info_request_id,
                    :incoming_message_id => incoming_message.id, :part => a.url_part_number, :file_name =>
                    (TMail::Mail.get_part_file_name(a) || "download.bin")) %>

            <% end %>

    <% end %>

<%= body %>


fixed up list views to not use dynamic column lists

Listing <%= plural_name %>

<% for column in model_instance.class.content_columns -%>
    <%= column.human_name %>
<% end -%>

<%% for <%= singular_name %> in @<%= plural_name %> %>

<% for column in model_instance.class.content_columns -%>
    <%%=h <%= singular_name %>.<%= column.name %> %>
<% end -%>
    <%%= link_to 'Show', :action => 'show<%= suffix %>', :id => <%= singular_name %> %>
    <%%= link_to 'Edit', :action => 'edit<%= suffix %>', :id => <%= singular_name %> %>
    <%%= link_to 'Destroy', { :action => 'destroy<%= suffix %>', :id => <%= singular_name %> }, :confirm => 'Are you sure?', :post => true %>

<%% end %>

<%%= link_to 'Previous page', { :page => @<%= singular_name %>_pages.current.previous } if @<%= singular_name %>_pages.current.previous %>
<%%= link_to 'Next page', { :page => @<%= singular_name %>_pages.current.next } if @<%= singular_name %>_pages.current.next %>

<%%= link_to 'New <%= singular_name %>', :action => 'new<%= suffix %>' %>

Listing <%= plural_name %>

  <%% for column in <%= model_name %>.content_columns %>
    <%%= column.human_name %>
  <%% end %>

<%% for <%= singular_name %> in @<%= plural_name %> %>

  <%% for column in <%= model_name %>.content_columns %>
    <%%=h <%= singular_name %>.send(column.name) %>
  <%% end %>
    <%%= link_to 'Show', :action => 'show<%= suffix %>', :id => <%= singular_name %> %>
    <%%= link_to 'Edit', :action => 'edit<%= suffix %>', :id => <%= singular_name %> %>
    <%%= link_to 'Destroy', { :action => 'destroy<%= suffix %>', :id => <%= singular_name %> }, :confirm => 'Are you sure?', :post => true %>

<%% end %>

<%%= link_to 'Previous page', { :page => @<%= singular_name %>_pages.current.previous } if @<%= singular_name %>_pages.current.previous %>
<%%= link_to 'Next page', { :page => @<%= singular_name %>_pages.current.next } if @<%= singular_name %>_pages.current.next %>

<%%= link_to 'New <%= singular_name %>', :action => 'new<%= suffix %>' %>


Bugfix to the diary entry comment notifier with the missing closing %>


Fix tiny mistake in rss log display.

Fix tiny mistake in rss log display.

<%
  target_type = target ? target.type_tag : rss_log.target_type
  target_name = target ? target.unique_format_name.t : rss_log.unique_format_name.t
  tag, args, time = rss_log.parse_log.first rescue []
  if not target_type
    title = :rss_destroyed.t(:type => :object)
    detail = nil
  elsif not target or
        tag.to_s.match(/^log_[a-z]+_(merged|destroyed)/)
    title = :rss_destroyed.t(:type => target_type)
    detail = tag.t(args) rescue nil
  elsif not time or time < target.created + 1.minute
    title = :rss_created.t(:type => target_type)
    if target_type == :observation || target_type == :species_list
      detail = nil
    else
      detail = :rss_by.t(:user => target.user.legal_name) rescue nil
    end
  else
    title = :rss_changed.t(:type => target_type)
    detail = nil
    if (target_type == :observation ||
        target_type == :species_list) and
      (args[:user] == target.user.login ||
       args[:user] == target.user.name ||
       args[:user] == target.user.legal_name)
      # This will remove redundant user from observation logs.
      tag2 = :"#{tag}0"
      if tag2.has_translation?
        detail = tag2.t(args)
      end
    end
    if !detail
      tag2 = tag.to_s.sub(/^log/,'rss').to_sym
      if tag2.has_translation?
        detail = tag2.t(args)
      end
    end
    detail ||= tag.t(args) rescue nil
  end
  time ||= rss_log.modified rescue nil
%>

      <%= if target and target_type == :species_list
        link_to(image_tag('splist.png', :border => 0),
                :controller => :species_list, :action => :show_species_list,
                :id => target.id, :params => query_params) + '
'
      elsif target and target_type == :observation and target.thumb_image
        thumbnail(target.thumb_image, :border => 0, :votes => true,
                  :link => :show_observation, :obs => target.id) + '
'
      else
        done_title = true
        content_tag(:span, title, :class => 'ListRssHeader')
      end %>

<% if @layout['vertical_layout'] %>

<% else %>

<% end %>

      <% unless done_title %>

          <%= title %>

      <% end %>

      <% unless target_name.blank? %>

          <%= if target
            link_to(target_name, :controller => target.show_controller,
                    :action => target.show_action, :id => target.id, :params => query_params)
          else
            link_to(target_name, :controller => :observer, :action => :show_rss_log,
                    :id => rss_log.id, :params => query_params)
          end %>

      <% end %>
      <% if target and (target_type == :observation || target_type == :species_list) %>

          <%= location_link(target.place_name, target.location) %>

          <%= target.when.web_date %>:

          <%= user_link(target.user) %>

      <% end %>

      <% if not detail.blank? %>

          <%= detail %>

      <% end %>
      <% if not time.blank? %>

          <%= time.fancy_time %>

      <% end %>

<%
  target_type = target ? target.type_tag : rss_log.target_type
  target_name = target ? target.unique_format_name.t : rss_log.unique_format_name.t
  tag, args, time = rss_log.parse_log.first rescue []
  if not target_type
    title = :rss_destroyed.t(:type => :object)
    detail = nil
  elsif not target or
        tag.to_s.match(/^log_[a-z]+_(merged|destroyed)/)
    title = :rss_destroyed.t(:type => target_type)
    detail = tag.t(args) rescue nil
  elsif not time or time < target.created + 1.minute
    title = :rss_created.t(:type => target_type)
    if target_type == :observation || target_type == :species_list
      detail = nil
    else
      detail = :rss_by.t(:user => target.user.legal_name) rescue nil
    end
  else
    title = :rss_changed.t(:type => target_type)
    detail = nil
    if (target_type == :observation ||
        target_type == :species_list) and
      (args[:user] == target.user.login ||
       args[:user] == target.user.name ||
       args[:user] == target.user.legal_name)
      # This will remove redundant user from observation logs.
      tag2 = :"#{tag}0"
      if tag2.has_translation?
        detail = tag2.t(args)
      end
    end
    if !detail
      tag2 = tag.to_s.sub(/^log/,'rss').to_sym
      if tag2.has_translation?
        detail = tag2.t(args)
      end
    end
    detail ||= tag.t(args) rescue nil
  end
  time ||= rss_log.modified rescue nil
%>

      <%= if target and target_type == :species_list
        link_to(image_tag('splist.png', :border => 0),
                :controller => :species_list, :action => :show_species_list,
                :id => target.id, :params => query_params) + '
'
      elsif target and target_type == :observation and target.thumb_image
        thumbnail(target.thumb_image, :border => 0, :votes => true,
                  :link => :show_observation, :obs => target.id) + '
'
      end %>

        <%= title %>

<% if @layout['vertical_layout'] %>

<% else %>

<% end %>

      <% unless target_name.blank? %>

          <%= if target
            link_to(target_name, :controller => target.show_controller,
                    :action => target.show_action, :id => target.id, :params => query_params)
          else
            link_to(target_name, :controller => :observer, :action => :show_rss_log,
                    :id => rss_log.id, :params => query_params)
          end %>

      <% end %>
      <% if target and (target_type == :observation || target_type == :species_list) %>

          <%= location_link(target.place_name, target.location) %>

          <%= target.when.web_date %>:

          <%= user_link(target.user) %>

      <% end %>

      <% if not detail.blank? %>

          <%= detail %>

      <% end %>
      <% if not time.blank? %>

          <%= time.fancy_time %>

      <% end %>


r91: plug security ...for now

r91: plug security ...for now

<% project_settings_page_breadcrumb %>

<%= @project.name %> Settings

<fieldset>

Project Settings

<% form_for :project, @project, :url => { :action => 'update', :id => @project.url_name } do |f| %>

  <%= setting_row('Rake Task', f.text_field(:rake_task), %{
                  e.g. "selenium_tests"

                  cruise has good defaults, but you can override them here by typing they task you want cruise to run,
                  read more #{link_to 'here', 'http://cruisecontrolrb.rubyforge.org/rake_tasks.html'}})%>
  <%=
#  setting_row('Build Command', f.text_field(:build_command), %{
#                  e.g. "ant build test"

#                  if you'd rather just replace rake altogether, you can specify the build command of your choice here})
%>
  <%= setting_row('Polling Interval',
                  "<input id='project_scheduler_polling_interval' name='project[scheduler][polling_interval]'
                          size='10' type='text' value='#{@project.scheduler.polling_interval}'/>",
                  "in seconds") %>

<%= submit_tag "Save Settings"%>

<% end %>
</fieldset>

<fieldset>

Email Notification

When the build fails, send an e-mail to :

  <%= render :partial => 'list' %>

Configure how email is sent from <%= link_to "Email Settings", :controller => 'admin', :action => 'email_settings' %>

</fieldset>

<% project_settings_page_breadcrumb %>

<%= @project.name %> Settings

<fieldset>

Project Settings

<% form_for :project, @project, :url => { :action => 'update', :id => @project.url_name } do |f| %>

  <%= setting_row('Rake Task', f.text_field(:rake_task), %{
                  e.g. "selenium_tests"

                  cruise has good defaults, but you can override them here by typing they task you want cruise to run,
                  read more #{link_to 'here', 'http://cruisecontrolrb.rubyforge.org/rake_tasks.html'}})%>
  <%= setting_row('Build Command', f.text_field(:build_command), %{
                  e.g. "ant build test"

                  if you'd rather just replace rake altogether, you can specify the build command of your choice here})%>
  <%= setting_row('Polling Interval',
                  "<input id='project_scheduler_polling_interval' name='project[scheduler][polling_interval]'
                          size='10' type='text' value='#{@project.scheduler.polling_interval}'/>",
                  "in seconds") %>

<%= submit_tag "Save Settings"%>

<% end %>
</fieldset>

<fieldset>

Email Notification

When the build fails, send an e-mail to :

  <%= render :partial => 'list' %>

Configure how email is sent from <%= link_to "Email Settings", :controller => 'admin', :action => 'email_settings' %>

</fieldset>


Give slightly more room for contact messages.

<% @title = "Contact us" %>

<%= foi_error_messages_for :contact %>

Make a request for public, official information

        Go here to make your request, in public, for information
        from UK public authorities.

Request information about yourself

        Our help page about data protection
        explains how to request information about yourself from UK public authorities.

Contact the WhatDoTheyKnow team

        We'd love to hear how you have found using this site.

        Please read the  about page first, as it may
        answer your question quicker. Then fill in this form, or send
        an email to <a href="mailto:<%=@contact_email%>"><%=@contact_email%>

<% form_for :contact do |f| %>

    <% if not @user %>

            Your name:
            <%= f.text_field :name, :size => 20 %>
            (or <%= link_to "sign in", signin_url(:r => request.request_uri) %>)

            Your email:
            <%= f.text_field :email, :size => 20 %>

    <% end %>

        Subject:
        <%= f.text_field :subject, :size => 50 %>

        Message:
        <%= f.text_area :message, :rows => 10, :cols => 60 %>

        <%= hidden_field_tag(:submitted_contact_form, 1) %>
        <%= submit_tag "Send message to the WhatDoTheyKnow team" %>

<% end %>

<% @title = "Contact us" %>

<%= foi_error_messages_for :contact %>

Make a request for public, official information

        Go here to make your request, in public, for information
        from UK public authorities.

Request information about yourself

        Our help page about data protection
        explains how to request information about yourself from UK public authorities.

Contact the WhatDoTheyKnow team

        We'd love to hear how you have found using this site.

        Please read the  about page first, as it may
        answer your question quicker. Then fill in this form, or send
        an email to <a href="mailto:<%=@contact_email%>"><%=@contact_email%>

<% form_for :contact do |f| %>

    <% if not @user %>

            Your name:
            <%= f.text_field :name, :size => 20 %>
            (or <%= link_to "sign in", signin_url(:r => request.request_uri) %>)

            Your email:
            <%= f.text_field :email, :size => 20 %>

    <% end %>

        Subject:
        <%= f.text_field :subject, :size => 50 %>

        Message:
        <%= f.text_area :message, :rows => 5, :cols => 50 %>

        <%= hidden_field_tag(:submitted_contact_form, 1) %>
        <%= submit_tag "Send message to the WhatDoTheyKnow team" %>

<% end %>


Added a password field.

Added a password field.

<%content_for("left") do-%>

Login:

  <%if @login_failed_user-%>
Invalid username or password.
<%end-%>
  <% form_tag :action => 'login'do -%>

Username

  <%= text_field 'person', 'username', :size => 30, :value => @login_failed_user  %>

Password

  <%= password_field 'person', 'password', :size => 30  %>

  <%= submit_tag 'Login' %>
  <% end -%>

Register

Forgot password?

Privacy policy

<%end-%>

<%content_for("right") do-%>

<%end-%>

<%content_for("left") do-%>

Login:

  <% form_tag :action => 'login'do -%>

Username

  <%= text_field 'person', 'username', :size => 30  %>

Password

  <%= password_field 'person', 'password', :size => 30  %>

  <%= submit_tag 'Login' %>
  <% end -%>

Register

Forgot password?

Privacy policy

<%end-%>

<%content_for("right") do-%>

<%end-%>


dont say anything, if no archived articles

<%= @path %>

  <% if archives.length > 0 %>
    <% for entry in archives %>

        <a href="<%= entry.path %>"><%= entry.title %>

    <% end %>
  <% end %>

<%= @path %>

  <% if archives.length > 0 %>
    <% for entry in archives %>

        <a href="<%= entry.path %>"><%= entry.title %>

    <% end %>
  <% else %>
    There are no articles for this date.
  <% end %>


[Mezuro] Added span to show range comment on mouse hover.

<%= _('Metric results for: ') + @module_label %>

      Metric
      Value
      Weight
      Threshold

    <% @module_result.metric_results.each do |metric_result|  %>
      <% range = metric_result.range %>
      <% if !range.nil? %>

          <a href="#" show-metric-history="<%= MezuroPlugin::Helpers::ContentViewerHelper.format_name(metric_result) %>" data-module-name="<%= @module.name %>"><%= metric_result.metric.name %>
          <%= MezuroPlugin::Helpers::ContentViewerHelper.format_grade(metric_result.value) %>
          <%= metric_result.weight %>
          <td style="background-color: #<%= range.color[2..-1] %>">
            <span title="<%= range.comments %>" >
              <%= range.label %>

        <tr class="<%= MezuroPlugin::Helpers::ContentViewerHelper.format_name(metric_result) %>" style="display: none;">

            <div id='historical-<%= MezuroPlugin::Helpers::ContentViewerHelper.format_name(metric_result) %>'>

            <%= range.comments.nil? ? '' : range.comments %>

      <% end %>
    <% end %>

        <a href="#" show-grade-history="<%= @module_result.module.name %>" data-module-name="<%= @module.name%>" >

            <%= _('Grade:') %>
            <%= "%.02f" % @module_result.grade %>

<%= _('Metric results for: ') + @module_label %>

      Metric
      Value
      Weight
      Threshold

    <% @module_result.metric_results.each do |metric_result|  %>
      <% range = metric_result.range %>
      <% if !range.nil? %>

          <a href="#" show-metric-history="<%= MezuroPlugin::Helpers::ContentViewerHelper.format_name(metric_result) %>" data-module-name="<%= @module.name %>"><%= metric_result.metric.name %>
          <%= MezuroPlugin::Helpers::ContentViewerHelper.format_grade(metric_result.value) %>
          <%= metric_result.weight %>
          <td style="background-color: #<%= range.color[2..-1] %>"><%= range.label %>

        <tr class="<%= MezuroPlugin::Helpers::ContentViewerHelper.format_name(metric_result) %>" style="display: none;">

            <div id='historical-<%= MezuroPlugin::Helpers::ContentViewerHelper.format_name(metric_result) %>'>

            <%= range.comments.nil? ? '' : range.comments %>

      <% end %>
    <% end %>

        <a href="#" show-grade-history="<%= @module_result.module.name %>" data-module-name="<%= @module.name%>" >

            <%= _('Grade:') %>
            <%= "%.02f" % @module_result.grade %>


Added collections selector

Added collections selector

<% @form_fields.each do |field| %>

<%= field[0].humanize %> <%= error_message_on :item, field[0] %>
	<% if field[1] == "string" %>
		<%= text_field :item, field[0], :class => "big" %>
	<% elsif field[1] == "text" %>
		<%= text_area :item, field[0], :rows => "#{field[2]}" %>
	<% elsif field[1] == "datetime" %>
		<%= datetime_select :item, field[0] %>
	<% elsif field[1] == "password" %>
		<%= password_field :item, field[0], :class => "big" %>
	<% elsif field[1] == "boolean" %>
		<%= check_box :item, field[0] %> Checked if active.
	<% elsif field[1] == "file" %>
		<%= file_field :item, field[0], :style => "border: 0px;" %>
	<% elsif field[1] == "tags" %>
		<%= text_field :item, field[0], :value => @item.tags.join(", "), :class => "big" %>
	<% elsif field[1] == "collection" %>
		<% @collection = field[0].singularize.capitalize.inject(Object){ |klass, part| klass.const_get(part) } %>
		<%= collection_select :item, "#{field[0]}_id", @collection.find(:all), :id, :name %>
	<% end %>

<% end %>

<% @form_fields.each do |field| %>

<%= field[0].humanize %> <%= error_message_on :item, field[0] %>
	<% if field[1] == "string" %>
		<%= text_field :item, field[0], :class => "big" %>
	<% elsif field[1] == "text" %>
		<%= text_area :item, field[0], :rows => "#{field[2]}" %>
	<% elsif field[1] == "datetime" %>
		<%= datetime_select :item, field[0] %>
	<% elsif field[1] == "password" %>
		<%= password_field :item, field[0], :class => "big" %>
	<% elsif field[1] == "boolean" %>
		<%= check_box :item, field[0] %> Checked if active.
	<% elsif field[1] == "file" %>
		<%= file_field :item, field[0], :style => "border: 0px;" %>
	<% elsif field[1] == "tags" %>
		<%= text_field :item, field[0], :value => @item.tags.join(", "), :class => "big" %>
	<% end %>

<% end %>


better error messge for students

better error messge for students

Automatic Grading Failed.

Error Message:  <%= @queue.message.to_html %>

<% if @user.id == @queue.user_turnin.user_id %>

<%= image_tag 'flag_red' %> You must do 1 of the following

<%= link_to 'Leave the turn-in set finalized and let instructor run autograder.', :controller => '/turnins', :course => @queue.assignment.course, :assignment => @queue.assignment %>

	<% if ! @queue.assignment.closed? %>

<%= link_to 'Reopen turn-in set for resubmission.', :action => 'retry', :id => @queue %>

	  Final submissions are due in <%= distance_of_time_in_words_to_now( @queue.assignment.due_date, true ) %> (<%= @queue.assignment.due_date.to_formatted_s(:friendly_date) %>)

	<% end %>

<% else %>

<%= link_to "Return to grading of this assignment.", :controller => 'instructor/turnins', :course => @queue.assignment.course, :assignment => @queue.assignment, :student => @queue.user_turnin.user_id, :action => 'view_io_tests' %>
<% end %>

Automatic Grading Failed.

Error Message:  <%= @queue.message %>

<% if @user.id == @queue.user_turnin.user_id %>

<%= image_tag 'flag_red' %> You must do 1 of the following

<%= link_to 'Leave the turn-in set finalized and let instructor run autograder.', :controller => '/turnins', :course => @queue.assignment.course, :assignment => @queue.assignment %>

	<% if ! @queue.assignment.closed? %>

<%= link_to 'Reopen turn-in set for resubmission.', :action => 'retry', :id => @queue %>

	  Final submissions are due in <%= distance_of_time_in_words_to_now( @queue.assignment.due_date, true ) %> (<%= @queue.assignment.due_date.to_formatted_s(:friendly_date) %>)

	<% end %>

<% else %>

<%= link_to "Return to grading of this assignment.", :controller => 'instructor/turnins', :course => @queue.assignment.course, :assignment => @queue.assignment, :student => @queue.user_turnin.user_id, :action => 'view_io_tests' %>
<% end %>


group#edit_tools now working again. (fixes #792)

<% @title_box = capture do -%>

<%= 'Select Page Types'.t %>

<% end %>

<%- form_tag(:controller => '/group', :action => 'edit_tools', :id => @group) do -%>

  <% @available_tools.each do |klass| -%>
    <% page_class = Page.class_name_to_class(klass) -%>
    <% if ! page_class.nil?%>

        <input type="checkbox" name="<%= klass %>" <%= @allowed_tools.index( klass ) ? "CHECKED" : "" %> />
        <%= "#{page_class.class_display_name}: #{page_class.class_description}" %>

    <% else %>

        <input type="checkbox" name="<%= klass %>" <%= @allowed_tools.index( klass ) ? "CHECKED" : "" %> />
        <%= "#{klass}:" %>

    <% end %>
  <% end -%>

  <input type="submit" value="Save Changes">
<%- end %>

<% @title_box = capture do -%>

<%= 'Select Page Types'.t %>

<% end %>

<%- form_tag(:controller => '/group', :action => 'edit_tools', :id => @group) do -%>

  <% @available_tools.each do |klass| -%>
    <% page_class = Page.class_name_to_class(klass) -%>
    <% if ! page_class.nil? %>

        <input type="checkbox" name="<%= page_class.short_class_name %>" <%= @allowed_tools.index( page_class.short_class_name ) ? "CHECKED" : "" %> />
        <%= "#{page_class.class_display_name}: #{page_class.class_description}" %>

    <% else %>

        <input type="checkbox" name="<%= klass %>" <%= @allowed_tools.index( klass ) ? "CHECKED" : "" %> />
        <%= "#{klass}:" %>

    <% end %>
  <% end -%>

  <input type="submit" value="Save Changes">
<%- end %>


Improved how prioritize option of blocks is displayed

(ActionItem1908)

  <%= labelled_form_field _('Limit of items'), text_field(:block, :limit, :size => 3) %>
  <%= check_box(:block, :prioritize_profiles_with_image) %>
  <%= _('Prioritize profiles with image') %>

  <%= labelled_form_field _('Limit of items'), text_field(:block, :limit, :size => 3) %>
  <%= labelled_form_field _('Prioritize profiles with image'), check_box(:block, :prioritize_profiles_with_image) %>


don't count committees, since this might be priviledged information and it isn't that useful

    <% if @group.publicly_visible_members or may_admin_group? %>

Members <%= @group.users.count %> members

      <%= render :partial => 'groups/widgets/members' %>
    <% end -%>

Group Information

<%= render :partial => 'groups/widgets/info' %>

    <% if not @group.committee? and
         (@group.publicly_visible_committees or may_admin_group?) -%>

Committees

<%= render :partial => 'groups/widgets/committees' %>
    <% end -%>

    <% if @group.publicly_visible_members or may_admin_group? %>

Members <%= @group.users.count %> members

      <%= render :partial => 'groups/widgets/members' %>
    <% end -%>

Group Information

<%= render :partial => 'groups/widgets/info' %>

    <% if not @group.committee? and
         (@group.publicly_visible_committees or may_admin_group?) -%>

Committees <%= @group.committees.count %> committees

<%= render :partial => 'groups/widgets/committees' %>
    <% end -%>


Remove redundant image param of track at edition form

  <%= required_fields_message %>

  <%= render :file => 'shared/tiny_mce' %>

    <%= required labelled_form_field(_('Title'), text_field(:article, 'name', :size => '64', :maxlength => 150)) %>

  <%= render :partial => 'shared/lead_and_body', :locals => {:tiny_mce => true, :body_label => 'Description:'} %>

    <%= labelled_form_field(_('Goals:'), text_area(:article, :goals, :rows => 3, :cols => 64)) %>
    <%= labelled_form_field(_('Expected Results:'), text_area(:article, :expected_results, :rows => 3, :cols => 64)) %>

  <%= required_fields_message %>

  <%= render :file => 'shared/tiny_mce' %>

    <%= required labelled_form_field(_('Title'), text_field(:article, 'name', :size => '64', :maxlength => 150)) %>

  <%= render :partial => 'shared/lead_and_body', :locals => {:tiny_mce => true, :body_label => 'Description:'} %>

    <% f.fields_for :image_builder, @article.image do |i| %>
      <%= file_field_or_thumbnail(_('Image:'), @article.image, i) %>
    <% end %>

    <%= labelled_form_field(_('Goals:'), text_area(:article, :goals, :rows => 3, :cols => 64)) %>
    <%= labelled_form_field(_('Expected Results:'), text_area(:article, :expected_results, :rows => 3, :cols => 64)) %>


More HTML formatting fixes for Safari

More HTML formatting fixes for Safari

git-svn-id: 96bd6241e080dd4199045f7177cf3384e2eaed71@845 2d86388d-c40f-0410-ad6a-a69da6a65d20

<% @page_title = "Results: #{@event.date.year}: #{@event.name}" %>

<%= @event.name %>

<%= @event.city_state %>

<%- if @event.respond_to?(:events) && !@event.is_a?(OregonCup) -%>
<%= @event.date_range_long_s %>
<%- else -%>
<%= @event.date.to_formatted_s(:long) %>
<%- end -%>

<%- if !@event.notes.blank? -%>

<%= @event.notes -%>

<%- end -%>

<%- if @event.respond_to?(:parent) and @event.parent -%>

  Part of the <%= link_to @event.parent.name, :id => @event.parent.to_param %>

<%- end -%>

<%- if @event.respond_to?(:events) -%>

  <%- for single_day_event in @event.events -%>
    <%- for standings in single_day_event.standings -%>

      <%= link_to standings.date.strftime('%A, %B %d'), :id => standings.event.to_param %>
      <%= link_to standings.name, :id => standings.event.to_param %>

    <%- end -%>
  <%- end -%>

<%- end -%>

<%- @event.standings.each_with_index do |standings, standings_index| -%>
    <%- if @event.standings.size > 1 -%>

<%= link_to(standings.name, :anchor => "standings_#{standings.id}") -%>

    <%- end -%>

    <%- if !standings.is_a?(CombinedStandings) -%>
      <%- if !standings.notes.blank? -%>

<%= standings.notes -%>

      <%- end -%>

	  <%# Rails 1.1.6 bug prevents us from just using date != date %>
      <%- if standings.date.strftime('%B %d, %Y') != @event.date.strftime('%B %d, %Y') -%>

<%= standings.date.strftime('%B %d, %Y') -%> <%= standings.date.class %> <%= @event.date.class %>

      <%- end -%>
    <%- end -%>

  <%# TODO Encapsulate in a helper method %>

    <%- results_in_first_column = standings.races_with_results.size / 2 -%>
    <%- standings.races_with_results.each_row_with_index do |row, row_index| -%>

      <a href="#race_<%= row.first.id %>" class="underlined"><%= row.first.name %>

      <%- if row.size == 2 -%><a href="#race_<%= row.last.id %>" class="underlined"><%= row.last.name %><%- end -%>

  <%- end -%>

<%- end -%>

<% @event.standings.each_with_index do |standings, standings_index| %>
  <%- if @event.standings.size > 1 -%>

<%= standings.name -%>

  <%- end -%>

Updated <%= standings.updated_at.to_formatted_s(:long) %>

  <% if !standings.is_a?(CombinedStandings) %>

<a href="http://<%= STATIC_HOST %>/results/questions.html" class="obvious">Results questions?

  <%- end -%>

  <% standings.races_with_results.each_with_index do |race, index| %>
  <a name="race_<%= race.id %>" id="race_<%= race.id %>" class="anchor" />

<%= race.name %>

  <%= results_grid(race) -%>

<%- end -%>
<%- end -%>

<% @page_title = "Results: #{@event.date.year}: #{@event.name}" %>

<%= @event.name %>

<%= @event.city_state %>

<%- if @event.respond_to?(:events) && !@event.is_a?(OregonCup) -%>
<%= @event.date_range_long_s %>
<%- else -%>
<%= @event.date.to_formatted_s(:long) %>
<%- end -%>

<%- if !@event.notes.blank? -%>

<%= @event.notes -%>

<%- end -%>

<%- if @event.respond_to?(:parent) and @event.parent -%>

  Part of the <%= link_to @event.parent.name, :id => @event.parent.to_param %>

<%- end -%>

<%- if @event.respond_to?(:events) -%>

  <%- for single_day_event in @event.events -%>
    <%- for standings in single_day_event.standings -%>

      <%= link_to standings.date.strftime('%A, %B %d'), :id => standings.event.to_param %>
      <%= link_to standings.name, :id => standings.event.to_param %>

    <%- end -%>
  <%- end -%>

<%- end -%>

<%- @event.standings.each_with_index do |standings, standings_index| -%>
    <%- if @event.standings.size > 1 -%>

<%= link_to(standings.name, :anchor => "standings_#{standings.id}") -%>

    <%- end -%>

    <%- if !standings.is_a?(CombinedStandings) -%>
      <%- if !standings.notes.blank? -%>

<%= standings.notes -%>

      <%- end -%>

	  <%# Rails 1.1.6 bug prevents us from just using date != date %>
      <%- if standings.date.strftime('%B %d, %Y') != @event.date.strftime('%B %d, %Y') -%>

<%= standings.date.strftime('%B %d, %Y') -%> <%= standings.date.class %> <%= @event.date.class %>

      <%- end -%>
    <%- end -%>

  <%# TODO Encapsulate in a helper method %>

    <%- results_in_first_column = standings.races_with_results.size / 2 -%>
    <%- standings.races_with_results.each_row_with_index do |row, row_index| -%>

      <a href="#race_<%= row.first.id %>" class="underlined"><%= row.first.name %>

      <%- if row.size == 2 -%><a href="#race_<%= row.last.id %>" class="underlined"><%= row.last.name %><%- end -%>

  <%- end -%>

<%- end -%>

<% @event.standings.each_with_index do |standings, standings_index| %>
  <%- if @event.standings.size > 1 -%>

<%= standings.name -%>

  <%- end -%>

Updated <%= standings.updated_at.to_formatted_s(:long) %>

  <% if !standings.is_a?(CombinedStandings) %>

<a href="http://<%= STATIC_HOST %>/results/questions.html" class="obvious">Results questions?

  <%- end -%>

  <% standings.races_with_results.each_with_index do |race, index| %>
  <a name="race_<%= race.id %>" id="race_<%= race.id %>" />

<%= race.name %>

  <%= results_grid(race) -%>

<%- end -%>
<%- end -%>


Add a datepicker to the DOB field

Add a datepicker to the DOB field

<% form_tag({:action => "signup"}, {:id => "signup_form"}) do %>
    <%= foi_error_messages_for :user_signup %>

        <%= _('Your e-mail:')%>
        <%= text_field 'user_signup', 'email', { :size => 20 } %>

        <%= _('We will not reveal your email address to anybody unless you or
        the law tell us to (details). ') %[help_privacy_path] %>

         <%= _('Your name:')%>
        <%= text_field 'user_signup', 'name', { :size => 20 } %>

         <%= _('Your name will appear publicly
        (why?)
        on this website and in search engines. If you
        are thinking of using a pseudonym, please
        read this first.') % [help_privacy_path+"#public_request", help_privacy_path+"#real_name"] %>

        <%= _('Your address:')%>
        <%= text_area 'user_signup', 'address', { :cols => 20, :rows => 6 } %>

        <%= _('Your address will be sent to authorities when you make a request.  We will not reveal your address on the website.') %>

        <%= _('Your DOB:')%>
        <%= text_field 'user_signup', 'dob', { :size => 20, :class => 'dob-datepicker' } %>

        <%= _('Your DOB will also be sent to authorities when you make a request.  We will not reveal your DOB on the website.') %>

         <%= _('Password:')%>
        <%= password_field 'user_signup', 'password', { :size => 15 } %>

         <%= _('Password: (again)')%>
        <%= password_field 'user_signup', 'password_confirmation', { :size => 15 } %>

    <% if @request_from_foreign_country %>
    <%= recaptcha_tags %>
    <% end %>

        <%= hidden_field_tag 'token', params[:token], {:id => 'signup_token' } %>
        <%= hidden_field_tag :modal, params[:modal], {:id => 'signup_modal' } %>
        <%= submit_tag _('Sign up') %>

<% end %>

<% form_tag({:action => "signup"}, {:id => "signup_form"}) do %>
    <%= foi_error_messages_for :user_signup %>

        <%= _('Your e-mail:')%>
        <%= text_field 'user_signup', 'email', { :size => 20 } %>

        <%= _('We will not reveal your email address to anybody unless you or
        the law tell us to (details). ') %[help_privacy_path] %>

         <%= _('Your name:')%>
        <%= text_field 'user_signup', 'name', { :size => 20 } %>

         <%= _('Your name will appear publicly
        (why?)
        on this website and in search engines. If you
        are thinking of using a pseudonym, please
        read this first.') % [help_privacy_path+"#public_request", help_privacy_path+"#real_name"] %>

        <%= _('Your address:')%>
        <%= text_area 'user_signup', 'address', { :cols => 20, :rows => 6 } %>

        <%= _('Your address will be sent to authorities when you make a request.  We will not reveal your address on the website.') %>

        <%= _('Your DOB:')%>
        <%= text_field 'user_signup', 'dob', { :size => 20 } %>

        <%= _('Your DOB will also be sent to authorities when you make a request.  We will not reveal your DOB on the website.') %>

         <%= _('Password:')%>
        <%= password_field 'user_signup', 'password', { :size => 15 } %>

         <%= _('Password: (again)')%>
        <%= password_field 'user_signup', 'password_confirmation', { :size => 15 } %>

    <% if @request_from_foreign_country %>
    <%= recaptcha_tags %>
    <% end %>

        <%= hidden_field_tag 'token', params[:token], {:id => 'signup_token' } %>
        <%= hidden_field_tag :modal, params[:modal], {:id => 'signup_modal' } %>
        <%= submit_tag _('Sign up') %>

<% end %>


Tidy up display of incoming message actions

<formset class="form-horizontal">
 <legend>Actions</legend>
 <% form_tag '../redeliver_incoming', :class => "form form-inline" do %>

  Redeliver message to another request (id or url_title)

      <% if @info_requests && @info_requests.size == 1 %>
        <%= text_field_tag 'url_title', @info_requests[0].url_title, { :size => 20 } %>
      <% else %>
        <%= text_field_tag 'url_title', "", { :size => 20 } %>
      <% end %>
      <%= hidden_field_tag 'redeliver_incoming_message_id', incoming_message.id %>
      <%= submit_tag "Redeliver to another request", :class => "btn" %>

 <% end %>

  Generate FOI officer upload URL

   <%= link_to 'Generate and take me there', "../generate_upload_url/#{incoming_message.info_request.id}?incoming_message_id=#{incoming_message.id}", :class => "btn", :id => "generate_upload_url" %>

 <% form_tag '../destroy_incoming', :class => "form form-inline" do %>

   Destroy message

    <%= hidden_field_tag 'incoming_message_id', incoming_message.id %>
    <%= submit_tag "Destroy message", :class => "btn btn-danger", :confirm => "This is permanent! Are you sure?" %>

 <% end %>

 <% form_tag '../copy_incoming', :class => "form form-inline" do %>

  Clone message to another request (id or url_title)

      <% if @info_requests && @info_requests.size == 1 %>
        <%= text_field_tag 'clone_url_title', @info_requests[0].url_title, { :size => 20 } %>
      <% else %>
        <%= text_field_tag 'clone_url_title', "", { :size => 20 } %>
      <% end %>
      <%= submit_tag "Clone to another request", :class => "btn" %>

This will clone the incoming message to another request, and mark that request as "complete"

      <%= hidden_field_tag 'copy_incoming_message_id', incoming_message.id %>

 <% end %>

 <% if @raw_email.nil? %>
  <%# we're not on the raw_email page itself %>

   Inspect email

     <%= link_to "View raw email", "../show_raw_email/#{incoming_message.raw_email_id}", :class => "btn", :id => "show_raw_email" %>

 <% end %>

</formset>

<formset class="form-horizontal">
 <legend>Actions</legend>
 <% form_tag '../redeliver_incoming', :class => "form form-inline" do %>

  Redeliver message to another request (id or url_title)

      <% if @info_requests && @info_requests.size == 1 %>
        <%= text_field_tag 'url_title', @info_requests[0].url_title, { :size => 20 } %>
      <% else %>
        <%= text_field_tag 'url_title', "", { :size => 20 } %>
      <% end %>
      <%= hidden_field_tag 'redeliver_incoming_message_id', incoming_message.id %>
      <%= submit_tag "Redeliver to another request", :class => "btn" %>

 <% end %>

  Generate FOI officer upload URL

   <%= link_to 'Generate and take me there', "../generate_upload_url/#{incoming_message.info_request.id}?incoming_message_id=#{incoming_message.id}", :class => "btn", :id => "generate_upload_url" %>

<% form_tag '../destroy_incoming', :class => "form form-inline" do %>

  Destroy message

   <%= hidden_field_tag 'incoming_message_id', incoming_message.id %>
   <%= submit_tag "Destroy message", :class => "btn btn-danger", :confirm => "This is permanent! Are you sure?" %>

<% end %>

<% if @raw_email.nil? %>
 <%# we're not on the raw_email page itself %>

  Inspect email

    <%= link_to "View raw email", "../show_raw_email/#{incoming_message.raw_email_id}", :class => "btn", :id => "show_raw_email" %>

<% end %>

</formset>


remove all caching from your projects, it's making support received values be out of date

<% @project ||= @show_projects.first -%>

<%= your_project.title %>

<% if profile = @viewer.profiles.find_by_project_id(@project.id) %>
  (<%= link_to("Dashboard", profile_path(profile)) %>)
<% end %>

<%= render :remote, :controller => 'reports', :action => :project_stats, :project_id => your_project.id %>

<%
@viewer.set_project(your_project)

title = ""
if @viewer.is_eventgroup_coordinator?(@eg)
    title += ", Projects Coordinator"
end
if @viewer.is_project_director?
    title += ", Project Director"
end
if @viewer.is_project_administrator?
    title += ", Project Administrator"
end
if @viewer.is_support_coach?
    title += ", Support Coach"
end
if @viewer.is_project_staff?
    title += ", Project Staff"
end
if @viewer.is_processor?
    title += ", Processor"
end

%>

<%= "#{@viewer.name}#{title}" %>

<% if @viewer.is_support_coach? || @viewer.is_atleast_project_staff(your_project) %>
    <%= render :partial => "support_coach_list", :locals => { :project => your_project } %>
<% end %>

<% if !@viewer.is_student?(@eg) %>
  <%
    cache(:controller => 'main', :action => 'your_projects', :section => 'Acceptance',
          :project_id => your_project.id, :role => @viewer.roles_wrt_project(your_project)) do
  %>

      <%= link_to 'Assign tasks', :action => 'assign_individual_tasks', :project_id => your_project.id %>

Accepted pile:

	      <%= render :partial => "accepted_pile", :locals => { :project => your_project } %>

  <% end %>

    <% @can_evaluate = @viewer.is_eventgroup_coordinator?(@eg) || @viewer.is_processor? %>
    <% appln_includes = [ :references, { :viewer => { :persons => :campuses } }, :preference1, :profiles ]
       @processor_list = Applying.find_all_by_project_id your_project.id
    %>
    <% @refs_for_questionnaire = Hash[*(@processor_list.collect{ |applying|
           applying.appln.form.questionnaire.id
         }.uniq.inject([]) { |arr,qid|
           arr << qid << Questionnaire.find(qid).references
         })]
    %>

Processor's pile:

    <%= render :partial => "processor_pile", :locals => { :project => your_project } %>

Staff:

      <%= render :partial => "staff_pile", :locals => { :project => your_project } %>

  <% if @viewer.is_eventgroup_coordinator?(@eg) || @viewer.is_processor? %>

Withdrawn pile:

      <%= render :partial => "withdrawn_pile", :locals => {:project => your_project }%>

  <% end %>
<% end %>

<% @project ||= @show_projects.first -%>

<%= your_project.title %>

<% if profile = @viewer.profiles.find_by_project_id(@project.id) %>
  (<%= link_to("Dashboard", profile_path(profile)) %>)
<% end %>

<%= render :remote, :controller => 'reports', :action => :project_stats, :project_id => your_project.id %>

<%
@viewer.set_project(your_project)

title = ""
if @viewer.is_eventgroup_coordinator?(@eg)
    title += ", Projects Coordinator"
end
if @viewer.is_project_director?
    title += ", Project Director"
end
if @viewer.is_project_administrator?
    title += ", Project Administrator"
end
if @viewer.is_support_coach?
    title += ", Support Coach"
end
if @viewer.is_project_staff?
    title += ", Project Staff"
end
if @viewer.is_processor?
    title += ", Processor"
end

%>

<%= "#{@viewer.name}#{title}" %>

<% if @viewer.is_support_coach? || @viewer.is_atleast_project_staff(your_project) %>
    <%= render :partial => "support_coach_list", :locals => { :project => your_project } %>
<% end %>

<% if !@viewer.is_student?(@eg) %>
  <%
    cache(:controller => 'main', :action => 'your_projects', :section => 'Acceptance',
          :project_id => your_project.id, :role => @viewer.roles_wrt_project(your_project)) do
  %>

      <%= link_to 'Assign tasks', :action => 'assign_individual_tasks', :project_id => your_project.id %>

Accepted pile:

	      <%= render :partial => "accepted_pile", :locals => { :project => your_project } %>

  <% end %>

    <% @can_evaluate = @viewer.is_eventgroup_coordinator?(@eg) || @viewer.is_processor? %>
    <% appln_includes = [ :references, { :viewer => { :persons => :campuses } }, :preference1, :profiles ]
       @processor_list = Applying.find_all_by_project_id your_project.id
    %>
    <% @refs_for_questionnaire = Hash[*(@processor_list.collect{ |applying|
           applying.try(:appln).try(:form).try(:questionnaire).try(:id)
         }.compact.uniq.inject([]) { |arr,qid|
           arr << qid << Questionnaire.find(qid).references
         })]
    %>

  <%
    cache(:controller => 'main', :action => 'your_projects', :section => 'Applying',
          :project_id => your_project.id, :role => @viewer.roles_wrt_project(your_project)) do
  %>

Processor's pile:

      <%= render :partial => "processor_pile", :locals => { :project => your_project } %>

  <% end %>

  <%
    cache(:controller => 'main', :action => 'your_projects', :section => 'StaffProfile',
          :project_id => your_project.id, :role => @viewer.roles_wrt_project(your_project)) do
  %>

Staff:

        <%= render :partial => "staff_pile", :locals => { :project => your_project } %>

  <% end %>

  <%
    cache(:controller => 'main', :action => 'your_projects', :section => 'Withdrawn',
          :project_id => your_project.id, :role => @viewer.roles_wrt_project(your_project)) do
  %>

    <% if @viewer.is_eventgroup_coordinator?(@eg) || @viewer.is_processor? %>

Withdrawn pile:

        <%= render :partial => "withdrawn_pile", :locals => {:project => your_project }%>

    <% end %>
  <% end %>
<% end %>


fix your projects crash

fix your projects crash

<% if @accepted.length > 0 %>
    <form>

<%= sortable_table %>

        <%= th 'name' %>
        <%= th 'campus' %>
        <%= th 'project' %>
        <% if @full_view || @restricted_full_view %>
            <%= th 'appln (entire)' %>
        <% end %>
        <%= th 'appln (summary)' %>
        <%= th 'accepted at', 'str', true %>
        <% if @full_view || @restricted_full_view %>
            <%= th 'support claimed', 'string' %>
            <%= th 'support recvd', 'currency' %>
            <%= th 'support goal', 'currency'%>
            <%= th 'support coach', 'dropdown' %>
        <% end %>
        <%= th 'intern' %>
        <%= th 'other' %>

        <% for acceptance in @accepted %>
          <%
          if defined?(project).nil? || acceptance.project != project
            project = acceptance.project
            @viewer.set_project project

            @full_view = @viewer.fullview?
            @cache = ProfileDonation.cache project.id
          end
          %>

          <tr id="row_<%=acceptance.id%>">
	    <% appln = acceptance.appln; viewer = acceptance.viewer %>
	    <% viewer = appln.viewer if viewer.nil? && appln %>
	    <% if viewer.nil? %>
	      missing viewer for acceptance <%= acceptance.id %>
            <% else %>
              <%=h viewer.name %>
              <% if viewer.person %>
	        <%= h viewer.person.campus_abbrev %>
		  <% else %>
		    no person for viewer '<%= viewer.username %>' id <%= viewer.id %>
		  <% end %>

	    <% end %>
            <%= acceptance.project.title %>
            <% if @full_view %>

                  <%= view_entire_link acceptance.id %>

            <% elsif @restricted_full_view %>

            <% end %>

              <%= view_summary_link acceptance.id %>

            <%- if @eg.show_dates_as_distance %>
              <td value="<%= format_date(acceptance.accepted_at) %>"><%= format_date(acceptance.accepted_at, :distance) %><%= " ago" if acceptance.accepted_at %>
            <%- else -%>
              <%= format_date(acceptance.accepted_at) %>
            <%- end -%>

            <% if @full_view %>
              <td value="<%= '%010d' % (format_currency acceptance.support_claimed.to_i * 100).to_i %>_<%= format_date acceptance.support_claimed_updated_at %>">
                <%= format_currency acceptance.support_claimed %>

                <%- if @eg.show_dates_as_distance %>
                  <%= format_date acceptance.support_claimed_updated_at %>
                <%- else %>
                  <%= format_date(acceptance.support_claimed_updated_at, :distance) %><%= " ago" if acceptance.support_claimed_updated_at %>
                <%- end %>
                <%= format_currency acceptance.donations_total(:cache => @cache) %>
                <%= format_currency acceptance.cached_costing_total %>

                    <% if @viewer.can_modify_profile_in_project project %>
                        <% name = "support_coach_#{acceptance.id}" %>
                        <% support_coach_id = acceptance.support_coach.nil? ? '' : acceptance.support_coach_id %>
                        <%= render :partial => 'support_coach_choice', :locals => { :name => name,
                                                :current => support_coach_id, :project => project } %>

                  	    <%= observe_field name,
                                   :url => {
                                      :controller => :acceptance,
                                      :action => :update_support_coach,
                                      :id => acceptance.id,
                                      :update => "support_coach_#{acceptance.id}",
                                      :profile_id => acceptance.id,
                                   },
                              	:complete => visual_effect(:highlight, "row_#{acceptance.id}"),
                                  :with =>  "'support_coach_id='+escape($('#{name}').value)"
                         %>
                    <% else %>
                        <%= acceptance.support_coach_str
                          %>
                    <% end %>

            <% elsif @restricted_full_view %>

            <% end %>

            <%= render :partial => 'accepted_pile_table_intern', :object => acceptance %>

                <% if @viewer.is_eventgroup_coordinator?(@eg) %>
                  <% name = "acceptance_#{acceptance.id}" %>

                  <%= withdraw_move_link acceptance.id %>

                  <%= manual_donations_link acceptance.motivation_code %>

                  <%= costing_link acceptance.id %>
                <% else %>
                  <% if acceptance.as_intern? %>intern<% end %>

                  <% if @viewer.is_eventgroup_coordinator?(@eg) || @viewer.is_project_administrator? %>

                      <%= costing_link acceptance.id %>
                  <% end %>
                <% end %>

		<% if @viewer.is_eventgroup_coordinator?(@eg) || @viewer.is_processor? %>
		  <% if appln %>
                    <%= edit_always_editable_link acceptance.id %>
		  <% else %>
		    Error: no appln for acceptance <%= acceptance.id %>
		  <% end %>
                <% end %>

                <%= travel_link acceptance.id %>
                <%= profile_notes_link acceptance.id, acceptance.profile_notes.length %>

        <% end %>

  </form>
<% else %>

empty

<% end %>

<% if @accepted.length > 0 %>
    <form>

<%= sortable_table %>

        <%= th 'name' %>
        <%= th 'campus' %>
        <%= th 'project' %>
        <% if @full_view || @restricted_full_view %>
            <%= th 'appln (entire)' %>
        <% end %>
        <%= th 'appln (summary)' %>
        <%= th 'accepted at', 'str', true %>
        <% if @full_view || @restricted_full_view %>
            <%= th 'support claimed', 'string' %>
            <%= th 'support recvd', 'currency' %>
            <%= th 'support goal', 'currency'%>
            <%= th 'support coach', 'dropdown' %>
        <% end %>
        <%= th 'intern' %>
        <%= th 'other' %>

        <% for acceptance in @accepted %>
          <%
          if defined?(project).nil? || acceptance.project != project
            project = acceptance.project
            @viewer.set_project project

            @full_view = @viewer.fullview?
            @cache = ProfileDonation.cache project.id
          end
          %>

          <tr id="row_<%=acceptance.id%>">
	    <% appln = acceptance.appln; viewer = acceptance.viewer %>
	    <% viewer = appln.viewer if viewer.nil? && appln %>
	    <% if viewer.nil? %>
	      missing viewer for acceptance <%= acceptance.id %>
            <% else %>
              <%=h viewer.name %>
              <% if viewer.person %>
	        <%= h viewer.person.campus_abbrev %>
		  <% else %>
		    no person for viewer '<%= viewer.username %>' id <%= viewer.id %>
		  <% end %>

	    <% end %>
            <%= acceptance.project.title %>
            <% if @full_view %>

                  <%= view_entire_link acceptance.id %>

            <% elsif @restricted_full_view %>

            <% end %>

              <%= view_summary_link acceptance.id %>

            <%- if @eg.show_dates_as_distance %>
              <td value="<%= format_date(acceptance.accepted_at) %>"><%= format_date(acceptance.accepted_at, :distance) %><%= " ago" if acceptance.accepted_at %>
            <%- else -%>
              <%= format_date(acceptance.accepted_at) %>
            <%- end -%>

            <% if @full_view %>
              <td value="<%= '%010d' % (format_currency acceptance.support_claimed * 100).to_i %>_<%= format_date acceptance.support_claimed_updated_at %>">
                <%= format_currency acceptance.support_claimed %>

                <%- if @eg.show_dates_as_distance %>
                  <%= format_date acceptance.support_claimed_updated_at %>
                <%- else %>
                  <%= format_date(acceptance.support_claimed_updated_at, :distance) %><%= " ago" if acceptance.support_claimed_updated_at %>
                <%- end %>
                <%= format_currency acceptance.donations_total(:cache => @cache) %>
                <%= format_currency acceptance.cached_costing_total %>

                    <% if @viewer.can_modify_profile_in_project project %>
                        <% name = "support_coach_#{acceptance.id}" %>
                        <% support_coach_id = acceptance.support_coach.nil? ? '' : acceptance.support_coach_id %>
                        <%= render :partial => 'support_coach_choice', :locals => { :name => name,
                                                :current => support_coach_id, :project => project } %>

                  	    <%= observe_field name,
                                   :url => {
                                      :controller => :acceptance,
                                      :action => :update_support_coach,
                                      :id => acceptance.id,
                                      :update => "support_coach_#{acceptance.id}",
                                      :profile_id => acceptance.id,
                                   },
                              	:complete => visual_effect(:highlight, "row_#{acceptance.id}"),
                                  :with =>  "'support_coach_id='+escape($('#{name}').value)"
                         %>
                    <% else %>
                        <%= acceptance.support_coach_str
                          %>
                    <% end %>

            <% elsif @restricted_full_view %>

            <% end %>

            <%= render :partial => 'accepted_pile_table_intern', :object => acceptance %>

                <% if @viewer.is_eventgroup_coordinator?(@eg) %>
                  <% name = "acceptance_#{acceptance.id}" %>

                  <%= withdraw_move_link acceptance.id %>

                  <%= manual_donations_link acceptance.motivation_code %>

                  <%= costing_link acceptance.id %>
                <% else %>
                  <% if acceptance.as_intern? %>intern<% end %>

                  <% if @viewer.is_eventgroup_coordinator?(@eg) || @viewer.is_project_administrator? %>

                      <%= costing_link acceptance.id %>
                  <% end %>
                <% end %>

		<% if @viewer.is_eventgroup_coordinator?(@eg) || @viewer.is_processor? %>
		  <% if appln %>
                    <%= edit_always_editable_link acceptance.id %>
		  <% else %>
		    Error: no appln for acceptance <%= acceptance.id %>
		  <% end %>
                <% end %>

                <%= travel_link acceptance.id %>
                <%= profile_notes_link acceptance.id, acceptance.profile_notes.length %>

        <% end %>

  </form>
<% else %>

empty

<% end %>


git-svn-id: svn+ssh://ko.meadowy.net/home/svn/inside/kozuchi/trunk@582 c938ebee-df10-0410-95fc-be8c4b0ebdd5

      <%= render(:partial => "shared/information") %>

          日付

          摘要

          入金
          出金
          残高
          変更
          削除

      <div class="scroll_box" <%= "style='height:#{h @deals_scroll_height};'" if @deals_scroll_height && @deals_scroll_height != ''%>>

        <% for deal in @deals %>
          <% edit_target = deal.balance ? 'edit_balance' : 'edit_deal' %>
          <% first = true %>

          <% for account_entry in deal.account_entries %>
            <tr <%= "class='updated_line'" if (@updated_deal && deal.id == @updated_deal.id)%><%= 'class="unconfirmed"' if !deal.confirmed %>>

                <% if first %>
                  <a name="#<%=deal.id%>"%><%= format_date(deal.date) %>
                <% end %>

                <%= deal.daily_seq if first %>

              <% if first %>
                <td class="summary" rowspan="<%=deal.account_entries.size%>">
                  <% if !deal.confirmed %>
                    <%= link_to_remote('確認' , {:update => 'book', :url => { :action => 'confirm', :id => deal }}, :class => 'small_button', :alt => '確認状態にします。' ) %>
                  <% end %>
                  <%= deal.balance ? "残高確認" : h(deal.summary) %>

              <% end %>
              <% if deal.parent_for(account_entry.account.id) || deal.child_for(account_entry.account.id) || account_entry.friend_link_id || account_entry.settlement || account_entry.result_settlement %>

                  <%= h account_entry.account.name %>

                  <% if deal.parent_for(account_entry.account.id) %>
                    <%= link_to('→主' ,{:action => 'jump', :id => deal.parent.id}) %>
                  <% end %>
                  <% if deal.child_for(account_entry.account.id) %>
                    <%= link_to('→従',{:action => 'jump', :id => deal.child_for(account_entry.account.id).id}) %>
                  <% end %>
                  <% if account_entry.linked_account_entry %>
                    <span <%="class='unconfirmed'" unless account_entry.linked_account_entry.deal.confirmed %>><%= h account_entry.linked_account_entry.deal.user.login_id %>
                  <% end %>
                  <% if account_entry.settlement %>
                    <%= link_to '精算', :controller => 'settlements', :action => 'view', :id => account_entry.settlement.id %>
                  <% end %>
                  <% if account_entry.result_settlement %>
                    <%= link_to '精算', :controller => 'settlements', :action => 'view', :id => account_entry.result_settlement.id %>
                  <% end %>

              <% else %>

                  <%= h account_entry.account.name %>

              <% end %>
              <%= number_with_delimiter(account_entry.amount) if account_entry.amount  > 0 && !account_entry.initial_balance? %>
              <%= number_with_delimiter(account_entry.amount.abs) if account_entry.amount < 0 && !account_entry.initial_balance? %>
              <%= number_with_delimiter(account_entry.balance)%>
              <% if first %>
                <td rowspan="<%=deal.account_entries.size%>" class="action"><%= link_to_remote('変更' , :update => 'edit_box', :url => { :controller => 'deal', :action => edit_target, :id => deal, 'back_to[controller]' => 'deals', 'back_to[action]' => 'index'}, :complete => "location.hash = '#{deal.id}';location.hash = 'top';" ) %>
                <td rowspan="<%=deal.account_entries.size%>" class="action">
                  <% unless deal.settlement_attached? %>
                    <%= link_to '削除' ,{:action => 'delete_deal', :id => deal}, :confirm => "#{format_deal(deal)}を削除します。よろしいですか？" %>
                  <% end %>

              <% end %>

            <% first = false %>
          <% end %>
        <% end %>

      <% if @target_month && !@date%>

      <% end %>
      <% if @updated_deal%>

      <% end %>

      <%= render(:partial => "shared/information") %>

          日付

          摘要

          入金
          出金
          残高
          変更
          削除

      <div class="scroll_box" <%= "style='height:#{h @deals_scroll_height};'" if @deals_scroll_height && @deals_scroll_height != ''%>>

        <% for deal in @deals %>
          <% edit_target = deal.balance ? 'edit_balance' : 'edit_deal' %>
          <% first = true %>

          <% for account_entry in deal.account_entries %>
            <tr <%= "class='updated_line'" if (@updated_deal && deal.id == @updated_deal.id)%><%= 'class="unconfirmed"' if !deal.confirmed %>>

                <% if first %>
                  <a name="#<%=deal.id%>"%><%= format_date(deal.date) %>
                <% end %>

                <%= deal.daily_seq if first %>

              <% if first %>
                <td class="summary" rowspan="<%=deal.account_entries.size%>">
                  <% if !deal.confirmed %>
                    <%= link_to_remote('確認' , {:update => 'book', :url => { :action => 'confirm', :id => deal }}, :class => 'small_button', :alt => '確認状態にします。' ) %>
                  <% end %>
                  <%= deal.balance ? "残高確認" : h(deal.summary) %>

              <% end %>
              <% if deal.parent_for(account_entry.account.id) || deal.child_for(account_entry.account.id) || account_entry.friend_link_id || account_entry.settlement || account_entry.result_settlement %>

                  <%= h account_entry.account.name %>

                  <% if deal.parent_for(account_entry.account.id) %>
                    <%= link_to('→主' ,{:action => 'jump', :id => deal.parent.id}) %>
                  <% end %>
                  <% if deal.child_for(account_entry.account.id) %>
                    <%= link_to('→従',{:action => 'jump', :id => deal.child_for(account_entry.account.id).id}) %>
                  <% end %>
                  <% if account_entry.linked_account_entry %>
                    <span <%="class='unconfirmed'" unless account_entry.linked_account_entry.deal.confirmed %>><%= h account_entry.linked_account_entry.deal.user.login_id %>
                  <% end %>
                  <% if account_entry.settlement %>
                    <%= link_to '精算', :controller => 'settlements', :action => 'view', :id => account_entry.settlement.id %>
                  <% end %>
                  <% if account_entry.result_settlement %>
                    <%= link_to '精算', :controller => 'settlements', :action => 'view', :id => account_entry.result_settlement.id %>
                  <% end %>

              <% else %>

                  <%= h account_entry.account.name %>

              <% end %>
              <%= number_with_delimiter(account_entry.amount) if account_entry.amount > 0%>
              <%= number_with_delimiter(account_entry.amount.abs) if account_entry.amount < 0%>
              <%= number_with_delimiter(account_entry.balance)%>
              <% if first %>
                <td rowspan="<%=deal.account_entries.size%>" class="action"><%= link_to_remote('変更' , :update => 'edit_box', :url => { :controller => 'deal', :action => edit_target, :id => deal, 'back_to[controller]' => 'deals', 'back_to[action]' => 'index'}, :complete => "location.hash = '#{deal.id}';location.hash = 'top';" ) %>
                <td rowspan="<%=deal.account_entries.size%>" class="action">
                  <% unless deal.settlement_attached? %>
                    <%= link_to '削除' ,{:action => 'delete_deal', :id => deal}, :confirm => "#{format_deal(deal)}を削除します。よろしいですか？" %>
                  <% end %>

              <% end %>

            <% first = false %>
          <% end %>
        <% end %>

      <% if @target_month && !@date%>

      <% end %>
      <% if @updated_deal%>

      <% end %>


Put Scottish part of ICO help in better place, make it shorter.

<% @title = "Unhappy about a Freedom of Information request?" %>

<% if !@info_request.nil? %>

Unhappy about the response you got
to your request '<%=request_link(@info_request) %>'?

<% else %>

Unhappy about the response you got?

<% end %>

If ...

You didn't get a reply within 20 working days

You did not get all of the information that you requested or

Your request was rejected, but without a reason valid under the law

... you can

Ask for an internal review at the public authority.

If that doesn't help, complain to the Information Commisioner.

Either way, also use other means to answer your question.

1. Asking for an internal review #

<% if !@info_request.nil? %>
    Choose <%= link_to "request an internal review", show_response_no_followup_url(:id => @info_request.id, :incoming_message_id => nil) + "?internal_review=1#followup" %> and then write a message asking the authority to review your request.
<% else %>
    At the bottom of the relevant request page on WhatDoTheyKnow choose
    "request an internal review". Then write a message asking for an internal
    review of your request. You may want to include a link to the
    request page, to make it clear which request you are talking about.
<% end %>

Internal reviews should be quick. If one takes longer than 20 working days
then the authority should write and let you know, and it should never take
longer than 40 working days (see this
good
practice guide).
You will then either get the information that
you originally requested, or you will be told that the review upholds the
original decision.

2. Complaining to the Information Commissioner #

If you are still unhappy after the public authority has done their internal review,
then you can complain to the Information Commisioner. To do this read
Complaints about Freedom of Information
on the Information Commisioner's website. If you requested information from a Scottish
authority, then  appeal
to the Scottish Information Commissioner.

To make it easier to send the relevant information to the
Information Commisioner, either
<% if !@info_request.nil? %>
    include a link to your request
    <%=h main_url(request_url(@info_request)) %>
<% else %>
    include a link to your request on WhatDoTheyKnow
<% end %>
in your complaint or print out the whole page of your request and all attachments.

WhatDoTheyKnow has no special facilities for handling a request at this stage - it
passes into the Information Commissioner's system. You can leave annotations on your
request keeping people informed of progress.

A warning. There is a backlog of work at the Information Commissioner, and
it can take literally years to get resolution from them. If you reach this point,
you should accept that you won't get the information quickly by this means. Maybe
you want to help the fight to improve Freedom of Information, or maybe
getting the information slowly is still worthwhile. You can also try and
get the information by other means...

3. Using other means to answer your question #

You can try persuing your problem or your research in other ways.

Make a new FOI request for summary information, or for
documentation relating indirectly to matters in your rejected request.
Ask us for ideas if you're stuck.

If any other public authorities or publicly owned companies are involved,
then make FOI requests to them.

Write to your MP or other politician using WriteToThem and ask for their help
finding the answer. MPs can write directly to ministers or departments, and
can ask written questions in the House of Commons. Councillors in local authorities
can talk directly to council officers.

Ask other researchers who are interested in a similar
issue to yours for ideas. You can sometimes find them by browsing this site;
contact any registered user from their page. There may be an Internet
forum or group that they hang out in. If it is a local matter, use GroupsNearYou to find such a
forum.

Start a pledge on PledgeBank to get
others to act together with you. For example, you could arrange a meeting with
staff from the authority. Or you could form a small local campaigns group.

<% @title = "Unhappy about a Freedom of Information request?" %>

<% if !@info_request.nil? %>

Unhappy about the response you got
to your request '<%=request_link(@info_request) %>'?

<% else %>

Unhappy about the response you got?

<% end %>

If ...

You didn't get a reply within 20 working days

You did not get all of the information that you requested or

Your request was rejected, but without a reason valid under the law

... you can

Ask for an internal review at the public authority.

If that doesn't help, complain to the Information Commisioner.

Either way, also use other means to answer your question.

1. Asking for an internal review #

<% if !@info_request.nil? %>
    Choose <%= link_to "request an internal review", show_response_no_followup_url(:id => @info_request.id, :incoming_message_id => nil) + "?internal_review=1#followup" %> and then write a message asking the authority to review your request.
<% else %>
    At the bottom of the relevant request page on WhatDoTheyKnow choose
    "request an internal review". Then write a message asking for an internal
    review of your request. You may want to include a link to the
    request page, to make it clear which request you are talking about.
<% end %>

Internal reviews should be quick. If one takes longer than 20 working days
then the authority should write and let you know, and it should never take
longer than 40 working days (see this
good
practice guide).
You will then either get the information that
you originally requested, or you will be told that the review upholds the
original decision.

2. Complaining to the Information Commissioner #

If you are still unhappy after the public authority has done their internal review,
then you can complain to the Information Commisioner. To do this read
Complaints about Freedom of Information
on the Information Commisioner's website.

To make it easier to send the relevant information to the
Information Commisioner, either
<% if !@info_request.nil? %>
    include a link to your request
    <%=h main_url(request_url(@info_request)) %>
<% else %>
    include a link to your request on WhatDoTheyKnow
<% end %>
in your complaint or print out the whole page of your request and all attachments.

WhatDoTheyKnow has no special facilities for handling a request at this stage - it
passes into the Information Commissioner's system. You can leave annotations on your
request keeping people informed of progress.

A warning. There is a backlog of work at the Information Commissioner, and
it can take literally years to get resolution from them. If you reach this point,
you should accept that you won't get the information quickly by this means. Maybe
you want to help the fight to improve Freedom of Information, or maybe
getting the information slowly is still worthwhile. You can also try and
get the information by other means...

If you've requested information from a Scottish public authority, then you'll need to complain to
the Scottish Information Commissioner.  They have published guidance on how to make a complaint
to them on their website.

3. Using other means to answer your question #

You can try persuing your problem or your research in other ways.

Make a new FOI request for summary information, or for
documentation relating indirectly to matters in your rejected request.
Ask us for ideas if you're stuck.

If any other public authorities or publicly owned companies are involved,
then make FOI requests to them.

Write to your MP or other politician using WriteToThem and ask for their help
finding the answer. MPs can write directly to ministers or departments, and
can ask written questions in the House of Commons. Councillors in local authorities
can talk directly to council officers.

Ask other researchers who are interested in a similar
issue to yours for ideas. You can sometimes find them by browsing this site;
contact any registered user from their page. There may be an Internet
forum or group that they hang out in. If it is a local matter, use GroupsNearYou to find such a
forum.

Start a pledge on PledgeBank to get
others to act together with you. For example, you could arrange a meeting with
staff from the authority. Or you could form a small local campaigns group.


oops remove my test

oops remove my test


Add guidance in the foi officer help section on not attaching pdf documents

<% @title = "FOI officer questions" %>

<%= render :partial => 'sidebar' %>

<%= @title %>

I just got here from bottom of an FOI request, what is going on?

Why are you publishing responses to FOI requests?

Why should I not attach PDF documents to FOI responses?

Are the people making requests real people?

Aren't you making lots of vexatious requests?

I can see a request on <%= site_name %>, but we never got it by email!

How do you calculate the deadline shown on request pages?

How can I send a large file, which won't go by email?

Why do you publish the names of public servants and the text of emails?

Do you publish email addresses or mobile phone numbers?

What is your policy on copyright of documents?

I just got here from bottom of an FOI request, what is going on? #

<%= site_name %> is a service run by a charity. It helps ordinary members
of the public make FOI requests, and easily track and share the responses.

The FOI request you received was made by someone using <%= site_name %>. You can
simply reply to the request as you would any other request from an individual.
The only difference is that your response will be automatically published on
the Internet.

If you have privacy or other concerns, please read the answers below.
You might also like to read the introduction to <%= site_name %> to find out more about what
the site does from the point of view of a user. You can also search the
site to find the authority that you work for, and view the status of
any requests made using the site.

Finally, we welcome comments and
thoughts from FOI officers, please get in touch.

Why are you publishing responses to FOI requests? #

We think there are lots of benefits. Most importantly it will encourage the
public to be more interested and involved in the work of government. We
also hope that it will reduce the number of duplicate requests on any
subject that a public body will receive. Given that Freedom of Information
responses contain public information, which anybody could easily request
again from the public authority, we think there should be no reason not to
publish it widely.

Why should I not attach PDF documents to FOI responses?

  The Australian Government Webguide makes it very clear that PDF is not an acceptable format for you to use in the delivery of government information:

    PDF does not yet have approved Sufficient Techniques to claim WCAG 2.0 conformance, so it cannot be ‘relied upon’ in the provision of government information.

  Write a response in an email as plain text. This is not only a simple and efficient way for you to conform to government guidelines, it is easier and quicker for the recipient to read.

Are the people making requests real people? #

Yes. For the purposes of keeping track of responses we use
computer-generated email addresses for each request. However, before
they can send a request, each user must register on the site with a
unique email address that we then verify. You can search this site and
find a page listing all requests that each person has made.

Aren't you making lots of vexatious requests? #

<%= site_name %> is not making any requests. We are sending requests on
behalf of our users, who are real people making the requests.

Look at it like this - if lots of different people made requests from
different Hotmail email addresses, then you would not think that Microsoft were
making vexatious requests. It is exactly the same if lots of requests are made
via <%= site_name %>. Moreover, since all requests are public it is much easier
for you to see if one of our users is making vexatious requests.

I can see a request on <%= site_name %>, but we never got it by email! #

If a request appears on the site, then we have attempted to send it to
the authority by email. Any delivery failure messages will automatically
appear on the site. You can check the address we're using with the "View FOI
email address" link which appears on the page for the authority. Contact us if there is a better address we can
use.

Requests are sometimes not delivered because they are quietly removed by
"spam filters" in the IT department of the authority. Authorities can make
sure this doesn't happen by asking their IT departments to "whitelist"
any email from @<%= Configuration::incoming_email_domain %>.
If you ask us we will resend any request,
and/or give technical details of delivery so an IT department can chase
up what happened to the message.

Finally, you can respond to any request from your web browser, without
needing any email, using the "respond to request" link at the bottom of
each request page.

How do you calculate the deadline shown on request pages? #

The Freedom of Information Act says:

        …the agency or Minister must…as soon as practicable but in
        any case not later than the end of the period of 30 days after the day on
        which the request is received by or on behalf of the agency or Minister,
        take all reasonable steps to enable the applicant to be notified of a
        decision on the request

      —
      (s 15(5)(b))

    And we try to be as generous as possible in our calculation of the 30 day
    timeframe.

How can I send a large file, which won't go by email? #

Instead of email, you can respond to a request directly from your web
browser, including uploading a file. To do this, choose "respond to request" at
the bottom of the request's page. Contact us if it
is too big for even that (more than, say, 50Mb).

Why do you publish the names of public servants and the text of emails? #

We consider what officers or servants do in the course of their employment
to be public information. We will only remove content in exceptional
circumstances, see our take down policy.

Do you publish email addresses or mobile phone numbers? #

To prevent spam, we automatically remove most emails and some mobile numbers from
responses to requests.  Please contact us if we've
missed one.
For technical reasons we don't always remove them from attachments, such as certain PDFs.

If you need to know what an address was that we've removed, please get in touch with us. Occasionally, an email address
forms an important part of a response and we will post it up in an obscured
form in an annotation.

What is your policy on copyright of documents? #

Our Freedom of Information law is "applicant blind", so anyone in the
world can request the same document and get a copy of it.

If you think our making a document available on the internet infringes your
copyright, you may contact us and ask us
to take it down.  However, to save tax payers' money by preventing duplicate
requests, and for good public relations, we'd advise you not to do that.

If you haven't already, read the introduction -->

Otherwise, the credits or the programmers API -->

<% @title = "FOI officer questions" %>

<%= render :partial => 'sidebar' %>

<%= @title %>

I just got here from bottom of an FOI request, what is going on?

Why are you publishing responses to FOI requests?

Are the people making requests real people?

Aren't you making lots of vexatious requests?

I can see a request on <%= site_name %>, but we never got it by email!

How do you calculate the deadline shown on request pages?

How can I send a large file, which won't go by email?

Why do you publish the names of public servants and the text of emails?

Do you publish email addresses or mobile phone numbers?

What is your policy on copyright of documents?

I just got here from bottom of an FOI request, what is going on? #

<%= site_name %> is a service run by a charity. It helps ordinary members
of the public make FOI requests, and easily track and share the responses.

The FOI request you received was made by someone using <%= site_name %>. You can
simply reply to the request as you would any other request from an individual.
The only difference is that your response will be automatically published on
the Internet.

If you have privacy or other concerns, please read the answers below.
You might also like to read the introduction to <%= site_name %> to find out more about what
the site does from the point of view of a user. You can also search the
site to find the authority that you work for, and view the status of
any requests made using the site.

Finally, we welcome comments and
thoughts from FOI officers, please get in touch.

Why are you publishing responses to FOI requests? #

We think there are lots of benefits. Most importantly it will encourage the
public to be more interested and involved in the work of government. We
also hope that it will reduce the number of duplicate requests on any
subject that a public body will receive. Given that Freedom of Information
responses contain public information, which anybody could easily request
again from the public authority, we think there should be no reason not to
publish it widely.

Are the people making requests real people? #

Yes. For the purposes of keeping track of responses we use
computer-generated email addresses for each request. However, before
they can send a request, each user must register on the site with a
unique email address that we then verify. You can search this site and
find a page listing all requests that each person has made.

Aren't you making lots of vexatious requests? #

<%= site_name %> is not making any requests. We are sending requests on
behalf of our users, who are real people making the requests.

Look at it like this - if lots of different people made requests from
different Hotmail email addresses, then you would not think that Microsoft were
making vexatious requests. It is exactly the same if lots of requests are made
via <%= site_name %>. Moreover, since all requests are public it is much easier
for you to see if one of our users is making vexatious requests.

I can see a request on <%= site_name %>, but we never got it by email! #

If a request appears on the site, then we have attempted to send it to
the authority by email. Any delivery failure messages will automatically
appear on the site. You can check the address we're using with the "View FOI
email address" link which appears on the page for the authority. Contact us if there is a better address we can
use.

Requests are sometimes not delivered because they are quietly removed by
"spam filters" in the IT department of the authority. Authorities can make
sure this doesn't happen by asking their IT departments to "whitelist"
any email from @<%= Configuration::incoming_email_domain %>.
If you ask us we will resend any request,
and/or give technical details of delivery so an IT department can chase
up what happened to the message.

Finally, you can respond to any request from your web browser, without
needing any email, using the "respond to request" link at the bottom of
each request page.

How do you calculate the deadline shown on request pages? #

The Freedom of Information Act says:

        …the agency or Minister must…as soon as practicable but in
        any case not later than the end of the period of 30 days after the day on
        which the request is received by or on behalf of the agency or Minister,
        take all reasonable steps to enable the applicant to be notified of a
        decision on the request

      —
      (s 15(5)(b))

    And we try to be as generous as possible in our calculation of the 30 day
    timeframe.

How can I send a large file, which won't go by email? #

Instead of email, you can respond to a request directly from your web
browser, including uploading a file. To do this, choose "respond to request" at
the bottom of the request's page. Contact us if it
is too big for even that (more than, say, 50Mb).

Why do you publish the names of public servants and the text of emails? #

We consider what officers or servants do in the course of their employment
to be public information. We will only remove content in exceptional
circumstances, see our take down policy.

Do you publish email addresses or mobile phone numbers? #

To prevent spam, we automatically remove most emails and some mobile numbers from
responses to requests.  Please contact us if we've
missed one.
For technical reasons we don't always remove them from attachments, such as certain PDFs.

If you need to know what an address was that we've removed, please get in touch with us. Occasionally, an email address
forms an important part of a response and we will post it up in an obscured
form in an annotation.

What is your policy on copyright of documents? #

Our Freedom of Information law is "applicant blind", so anyone in the
world can request the same document and get a copy of it.

If you think our making a document available on the internet infringes your
copyright, you may contact us and ask us
to take it down.  However, to save tax payers' money by preventing duplicate
requests, and for good public relations, we'd advise you not to do that.

If you haven't already, read the introduction -->

Otherwise, the credits or the programmers API -->


Removed extraneous td from value column of show.rhtml

<% for column in model_ui.show_columns %>

  <%= column.human_name %>:
  <%= !column.render_td(self, @streamlined_item).blank? ? column.render_td(self, @streamlined_item) : ' ' %>

<% end %>

<% unless model_ui.read_only %>
<%= link_to 'Edit', {:action => 'edit', :id => @streamlined_item},
                    {:onclick => "Streamlined.Link.submit(this); return false;"} %>
<% end %>


Remove spurious comma that was breaking Safari.

<% form_tag :action => "finish" do %>

Area to Export

    <%= text_field_tag('maxlat', nil, :size => 10, :class => "export_bound") %>

    <%= text_field_tag('minlon', nil, :size => 10, :class => "export_bound") %>
    <%= text_field_tag('maxlon', nil, :size => 10, :class => "export_bound") %>

    <%= text_field_tag('minlat', nil, :size => 10, :class => "export_bound") %>

      Drag a box with control held down to select an area to export

Format to Export

      <%= radio_button_tag("format", "osm") %>OpenStreetMap XML Data

      <%= radio_button_tag("format", "mapnik") %>Mapnik Image

      <%= radio_button_tag("format", "osmarender") %>Osmarender Image

Licence

OpenStreetMap data is licensed under the Creative Commons Attribution-ShareAlike 2.0 license.

Options

Format <%= select_tag("mapnik_format", options_for_select([["PNG", "png"], ["JPEG", "jpeg"], ["SVG", "svg"], ["PDF", "pdf"], ["Postscript", "ps"]], "png")) %>

Scale 1 : <%= text_field_tag("mapnik_scale", nil, :size => 8) %> (max 1 : )

Options

Format <%= select_tag("osmarender_format", options_for_select([["PNG", "png"], ["JPEG", "jpeg"]], "png")) %>

Zoom <%= select_tag("osmarender_zoom", options_for_select([4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17])) %>

<%= submit_tag "Export", :id => "export_commit" %>

<% end %>


added javascripts for swf video

added javascripts for swf video

Welcome to Maximum Size Database!

<%= render :partial => '/layouts/introduction' %>

  <% unless @current_logged_in_user %>

	<fieldset class="narrow">

Please Log In

    <% form_tag 'login/login' do %>

          Please log in if you want to add data or comments.

          Email Address	<%= text_field_tag :email_address, params[:email_address] %>

            Password

          <%= password_field_tag :password %>

            <%= submit_tag 'Login' %>

            <%= link_to("I forgot my password!", :controller => 'login', :action => "password_reset") %>

            <%= link_to("I am a new user and want to register.",:controller => 'register', :action => 'index') %>

    <% end %>
  </fieldset>
  <% end %>
  <% form_tag 'bodysize/list' do %>
		<input type="hidden" name="need_template" />
		<input type="hidden" name="group_by" value=""/>
		<input type="hidden" name="bodysize[graph]" value="0" />

		<fieldset  class="narrow">

Search Data

Start	<%= select("bodysize", "start_period_midpoint", @start_period_options) %>

End	<%= select("bodysize", "end_period_midpoint", @end_period_options) %>

Kingdom	<%= select("bodysize", "kingdom_id", @kingdom_options, {:include_blank => true}) %>

Phylum	<%= select("bodysize", "phylum_id", @phylum_options, {:include_blank => true}) %>

Class	<%= text_field_tag "bodysize[class_classification]" %>

Environment	<%= select("bodysize", "environment_id", @environment_options, {:include_blank => true}) %>

Motility	<%= select("bodysize", "motility_id", @motility_options, {:include_blank => true}) %>

<%= submit_tag 'Search', :id => "search_button" %>

	</fieldset>

	<% end %>
	<fieldset  class="narrow">

Educational Video

    </fieldset>