Fix admin title prefix checkbox to actually allow you to uncheck it

git-svn-id: 70ab0960c3db1cbf656efd6df54a8f3de72dc710@1317 820eb932-12ee-0310-9ca8-eeb645f39767

<% @page_heading = 'Blog settings' %>

  <% form_tag :action => 'update' do %>

Which settings group would you like to edit?

General Settings

Text Filter

Spam Protection

Resource Defaults

Cache

General Settings

      Blog name:
      <input name="setting[blog_name]" id="blog_name" type="text" value="<%=h this_blog.blog_name %>" />

      Blog subtitle:
      <input name="setting[blog_subtitle]" id="blog_subtitle" type="text" value="<%=h this_blog.blog_subtitle %>" />

      <input name="setting[title_prefix]" id="blog_title_prefix" type="checkbox" value="1" <%= 'checked="checked"' if this_blog.title_prefix %> />
      <input name="setting[title_prefix]" type="hidden" value="0" />
      Prefix page title with blog name

      Base Url:
      <input name="setting[base_url]" id="base_url" type="text" value="<%=h this_blog.base_url %>" />

      <input name="setting[default_allow_comments]" id="default_allow_comments" type="checkbox" value="1" <%= 'checked="checked"' if this_blog.default_allow_comments%> />
      <input name="setting[default_allow_comments]" type="hidden" value="0"/>
        Enable comments by default

      <input name="setting[default_allow_pings]" id="default_allow_pings" type="checkbox" value="1" <%= 'checked="checked"' if this_blog.default_allow_pings%> />
      <input name="setting[default_allow_pings]" type="hidden" value="0"/>
        Enable Trackbacks by default

      Display
      <input name="setting[limit_article_display]" size="4" id="limit_article_display" type="text" value="<%= this_blog.limit_article_display %>" /> articles on my homepage by default.

      Display
      <input name="setting[limit_rss_display]" size="4" id="limit_rss_display" type="text" value="<%= this_blog.limit_rss_display %>" /> articles in my rss feed by default.

      <input name="setting[show_extended_on_rss]" id="show_extended_on_rss" type="checkbox" value="1" <%= 'checked="checked"' if this_blog.show_extended_on_rss%> />
      <input name="setting[show_extended_on_rss]" type="hidden" value="0"/>
        Show full article on rss feed

Should the blog show mailto: links to your email address?

<input name="setting[link_to_author]" id="link_to_author" type="checkbox" value="1" <%= 'checked="checked"' if this_blog.link_to_author%> /><input name="setting[link_to_author]" type="hidden" value="0"/> Enable E-Mail public display

Should the blog use of the Globally Recognized Avatar (Gravatar) service in comments?

      <input name="setting[use_gravatar]" id="use_gravatar" type="checkbox" value="1" <%= 'checked="checked"' if this_blog.use_gravatar %> />
      <input name="setting[use_gravatar]" type="hidden" value="0"/>
      Enable Gravatar integration

Would you like to include your latitude and longitude in your blog's HTML pages? See GeoURL for details.
Example: <tt>47.774,-122.201</tt>

      Latitude, Longitude:
      <input name="setting[geourl_location]" size="20" id="geourl_location" type="text" value="<%= this_blog.geourl_location %>" />

This setting allows you to disable trackbacks for every article in
    your blog.  It won't remove existing trackbacks, but it will prevent
    any further attempt to add a trackback anywhere on your blog.  You can
    enable or disable trackbacks per-article using the article's extended
    settings.  See also the
      "Enable Trackbacks by default" setting above.

      <input name="setting[global_pings_disable]" id="global_pings_disable" type="checkbox" value="1" <%= 'checked="checked"' if this_blog.global_pings_disable%> />
         <input name="setting[global_pings_disable]" type="hidden" value="0"/>
           Disable trackbacks site-wide

Should Typo send trackbacks to websites that you link to?  This should be disabled
       for private blogs, as it will leak non-public information to sites that you're discussing.
       For public blogs, there's no real point in disabling this.

      <input name="setting[send_outbound_pings]" id="send_outbound_pings" type="checkbox" value="1" <%= 'checked="checked"' if this_blog.send_outbound_pings%> />
         <input name="setting[send_outbound_pings]" type="hidden" value="0"/>
           Send trackbacks to external sites

      URLs to ping automatically:

      <textarea name="setting[ping_urls]" id="ping_urls" rows="5" cols="50"><%=h this_blog.ping_urls %></textarea>

<%= save("Save My Settings") %>

Text Filter

Typo supports a number of text filtering options.  To add new filters, see the "filters" tab on the toolbar above.

        <select name="setting[text_filter]" id="text_filter">
          <%= options_for_select text_filter_options, TextFilter.find_by_name(this_blog.text_filter) %>
        </select>
        Article filter

        <select name="setting[comment_text_filter]" id="comment_text_filter">
        <%= options_for_select text_filter_options, TextFilter.find_by_name(this_blog.comment_text_filter) %>
        </select>
        Comments filter

<%= save("Save My Settings") %>

Notification

Typo can notify you when new articles or comments are posted

      Email address to use in From: field when Typo sends mail:
      <input name="setting[email_from]" size="20" id="email_from" type="text" value="<%= this_blog.email_from %>" />

      Jabber account to use when sending Jabber notifications:
      <input name="setting[jabber_address]" size="20" id="jabber_address" type="text" value="<%= this_blog.jabber_address %>" />

      Password for Jabber account:
      <input name="setting[jabber_password]" size="20" id="jabber_password" type="password" value="<%= this_blog.jabber_password %>" />

<%= save("Save My Settings") %>

Spam Protection

Enabling spam protection will make typo compare the IP address of posters as well as the contents of their posts against local and remote blacklists. Good defense against spam bots.

          <input name="setting[sp_global]" id="sp_global" type="checkbox" value="1" <%= 'checked="checked"' if this_blog.sp_global%> /><input name="setting[sp_global]" type="hidden" value="0"/>
          Enable spam protection

Typo can (optionally) use the Akismet spam-filtering service.  You need to register with
           Akismet and receive an API key before you can use their service.  If you have an Akismet key, enter it here.

          Akismet Key
          <input name="setting[sp_akismet_key]" id="sp_akismet_key" type="text" value="<%=h this_blog.sp_akismet_key %>"/>

You can optionally disable non-Ajax comments.  Typo will always use Ajax for comment submission if Javascript is enabled,
           so non-Ajax comments are either from spammers or users without Javascript.

          <input name="setting[sp_allow_non_ajax_comments]" id="sp_allow_non_ajax_comments" type="checkbox" value="1" <%= 'checked="checked"' if this_blog.sp_allow_non_ajax_comments%> />
          <input name="setting[sp_allow_non_ajax_comments]" type="hidden" value="0" />
          Allow non-ajax comments

(Spam bots usually don't know anything about ajax comments)

          Disable comments after
          <input name="setting[sp_article_auto_close]" size="4" id="sp_article_auto_close" type="text" value="<%= this_blog.sp_article_auto_close %>" /> days

(Set to 0 to never disable comments)

Typo will automatically reject comments and trackbacks which contain over a certain amount of links in them.

          Max URLs:
          <input name="setting[sp_url_limit]" size="4" id="sp_url_limit" type="text" value="<%= this_blog.sp_url_limit %>" /> links

(Set to 0 to never reject comments)

<%= save("Save My Settings") %>

Resource Defaults

          The below settings act as defaults when you choose to publish an enclosure with iTunes metadata.

          Author:
          <input name="setting[itunes_author]" size="25" id="itunes_author" type="text" value="<%= this_blog.itunes_author %>" />

          Subtitle:
          <input name="setting[itunes_subtitle]" size="25" id="itunes_subtitle" type="text" value="<%= this_blog.itunes_subtitle %>" />(setting for channel)

        Summary:(setting for channel)

          <textarea name="setting[itunes_summary]" cols="40" rows="3"><%=h this_blog.itunes_summary %></textarea>

          Email:
          <input name="setting[itunes_email]" size="25" id="itunes_email" type="text" value="<%= this_blog.itunes_email %>" />  Not Published by Apple

          Optional Name:
          <input name="setting[itunes_name]" size="25" id="itunes_name" type="text" value="<%= this_blog.itunes_name %>" />  Not Published by Apple

          Copyright Information:
          <input name="setting[itunes_copyright]" size="25" id="itunes_copyright" type="text" value="<%= this_blog.itunes_copyright %>" />

          Explicit:
          <input name="setting[itunes_explicit]" id="itunes_explicit" type="checkbox"  value="1" <%= 'checked="checked"' if this_blog.itunes_explicit%> /><input name="setting[itunes_explicit]" type="hidden" value="0" />

<%= save("Save My Settings") %>

Cache

   <%= link_to 'Empty Fragment Cache', :controller => '/admin/cache', :action => 'sweep' %>

   <%= link_to 'Rebuild cached HTML', :controller => '/admin/cache', :action => 'sweep_html' %>

There are <%= @page_cache_size %> entries in the cache

    <%= save("Save My Settings") %>

  <% end %>

<% @page_heading = 'Blog settings' %>

  <% form_tag :action => 'update' do %>

Which settings group would you like to edit?

General Settings

Text Filter

Spam Protection

Resource Defaults

Cache

General Settings

      Blog name:
      <input name="setting[blog_name]" id="blog_name" type="text" value="<%=h this_blog.blog_name %>" />

      Blog subtitle:
      <input name="setting[blog_subtitle]" id="blog_subtitle" type="text" value="<%=h this_blog.blog_subtitle %>" />

      <input name="setting[title_prefix]" id="blog_title_prefix" type="checkbox" value="1" <%= 'checked="checked"' if this_blog.title_prefix %> />
      Prefix page title with blog name

      Base Url:
      <input name="setting[base_url]" id="base_url" type="text" value="<%=h this_blog.base_url %>" />

      <input name="setting[default_allow_comments]" id="default_allow_comments" type="checkbox" value="1" <%= 'checked="checked"' if this_blog.default_allow_comments%> />
      <input name="setting[default_allow_comments]" type="hidden" value="0"/>
        Enable comments by default

      <input name="setting[default_allow_pings]" id="default_allow_pings" type="checkbox" value="1" <%= 'checked="checked"' if this_blog.default_allow_pings%> />
      <input name="setting[default_allow_pings]" type="hidden" value="0"/>
        Enable Trackbacks by default

      Display
      <input name="setting[limit_article_display]" size="4" id="limit_article_display" type="text" value="<%= this_blog.limit_article_display %>" /> articles on my homepage by default.

      Display
      <input name="setting[limit_rss_display]" size="4" id="limit_rss_display" type="text" value="<%= this_blog.limit_rss_display %>" /> articles in my rss feed by default.

      <input name="setting[show_extended_on_rss]" id="show_extended_on_rss" type="checkbox" value="1" <%= 'checked="checked"' if this_blog.show_extended_on_rss%> />
      <input name="setting[show_extended_on_rss]" type="hidden" value="0"/>
        Show full article on rss feed

Should the blog show mailto: links to your email address?

<input name="setting[link_to_author]" id="link_to_author" type="checkbox" value="1" <%= 'checked="checked"' if this_blog.link_to_author%> /><input name="setting[link_to_author]" type="hidden" value="0"/> Enable E-Mail public display

Should the blog use of the Globally Recognized Avatar (Gravatar) service in comments?

      <input name="setting[use_gravatar]" id="use_gravatar" type="checkbox" value="1" <%= 'checked="checked"' if this_blog.use_gravatar %> />
      <input name="setting[use_gravatar]" type="hidden" value="0"/>
      Enable Gravatar integration

Would you like to include your latitude and longitude in your blog's HTML pages? See GeoURL for details.
Example: <tt>47.774,-122.201</tt>

      Latitude, Longitude:
      <input name="setting[geourl_location]" size="20" id="geourl_location" type="text" value="<%= this_blog.geourl_location %>" />

This setting allows you to disable trackbacks for every article in
    your blog.  It won't remove existing trackbacks, but it will prevent
    any further attempt to add a trackback anywhere on your blog.  You can
    enable or disable trackbacks per-article using the article's extended
    settings.  See also the
      "Enable Trackbacks by default" setting above.

      <input name="setting[global_pings_disable]" id="global_pings_disable" type="checkbox" value="1" <%= 'checked="checked"' if this_blog.global_pings_disable%> />
         <input name="setting[global_pings_disable]" type="hidden" value="0"/>
           Disable trackbacks site-wide

Should Typo send trackbacks to websites that you link to?  This should be disabled
       for private blogs, as it will leak non-public information to sites that you're discussing.
       For public blogs, there's no real point in disabling this.

      <input name="setting[send_outbound_pings]" id="send_outbound_pings" type="checkbox" value="1" <%= 'checked="checked"' if this_blog.send_outbound_pings%> />
         <input name="setting[send_outbound_pings]" type="hidden" value="0"/>
           Send trackbacks to external sites

      URLs to ping automatically:

      <textarea name="setting[ping_urls]" id="ping_urls" rows="5" cols="50"><%=h this_blog.ping_urls %></textarea>

<%= save("Save My Settings") %>

Text Filter

Typo supports a number of text filtering options.  To add new filters, see the "filters" tab on the toolbar above.

        <select name="setting[text_filter]" id="text_filter">
          <%= options_for_select text_filter_options, TextFilter.find_by_name(this_blog.text_filter) %>
        </select>
        Article filter

        <select name="setting[comment_text_filter]" id="comment_text_filter">
        <%= options_for_select text_filter_options, TextFilter.find_by_name(this_blog.comment_text_filter) %>
        </select>
        Comments filter

<%= save("Save My Settings") %>

Notification

Typo can notify you when new articles or comments are posted

      Email address to use in From: field when Typo sends mail:
      <input name="setting[email_from]" size="20" id="email_from" type="text" value="<%= this_blog.email_from %>" />

      Jabber account to use when sending Jabber notifications:
      <input name="setting[jabber_address]" size="20" id="jabber_address" type="text" value="<%= this_blog.jabber_address %>" />

      Password for Jabber account:
      <input name="setting[jabber_password]" size="20" id="jabber_password" type="password" value="<%= this_blog.jabber_password %>" />

<%= save("Save My Settings") %>

Spam Protection

Enabling spam protection will make typo compare the IP address of posters as well as the contents of their posts against local and remote blacklists. Good defense against spam bots.

          <input name="setting[sp_global]" id="sp_global" type="checkbox" value="1" <%= 'checked="checked"' if this_blog.sp_global%> /><input name="setting[sp_global]" type="hidden" value="0"/>
          Enable spam protection

Typo can (optionally) use the Akismet spam-filtering service.  You need to register with
           Akismet and receive an API key before you can use their service.  If you have an Akismet key, enter it here.

          Akismet Key
          <input name="setting[sp_akismet_key]" id="sp_akismet_key" type="text" value="<%=h this_blog.sp_akismet_key %>"/>

You can optionally disable non-Ajax comments.  Typo will always use Ajax for comment submission if Javascript is enabled,
           so non-Ajax comments are either from spammers or users without Javascript.

          <input name="setting[sp_allow_non_ajax_comments]" id="sp_allow_non_ajax_comments" type="checkbox" value="1" <%= 'checked="checked"' if this_blog.sp_allow_non_ajax_comments%> />
          <input name="setting[sp_allow_non_ajax_comments]" type="hidden" value="0" />
          Allow non-ajax comments

(Spam bots usually don't know anything about ajax comments)

          Disable comments after
          <input name="setting[sp_article_auto_close]" size="4" id="sp_article_auto_close" type="text" value="<%= this_blog.sp_article_auto_close %>" /> days

(Set to 0 to never disable comments)

Typo will automatically reject comments and trackbacks which contain over a certain amount of links in them.

          Max URLs:
          <input name="setting[sp_url_limit]" size="4" id="sp_url_limit" type="text" value="<%= this_blog.sp_url_limit %>" /> links

(Set to 0 to never reject comments)

<%= save("Save My Settings") %>

Resource Defaults

          The below settings act as defaults when you choose to publish an enclosure with iTunes metadata.

          Author:
          <input name="setting[itunes_author]" size="25" id="itunes_author" type="text" value="<%= this_blog.itunes_author %>" />

          Subtitle:
          <input name="setting[itunes_subtitle]" size="25" id="itunes_subtitle" type="text" value="<%= this_blog.itunes_subtitle %>" />(setting for channel)

        Summary:(setting for channel)

          <textarea name="setting[itunes_summary]" cols="40" rows="3"><%=h this_blog.itunes_summary %></textarea>

          Email:
          <input name="setting[itunes_email]" size="25" id="itunes_email" type="text" value="<%= this_blog.itunes_email %>" />  Not Published by Apple

          Optional Name:
          <input name="setting[itunes_name]" size="25" id="itunes_name" type="text" value="<%= this_blog.itunes_name %>" />  Not Published by Apple

          Copyright Information:
          <input name="setting[itunes_copyright]" size="25" id="itunes_copyright" type="text" value="<%= this_blog.itunes_copyright %>" />

          Explicit:
          <input name="setting[itunes_explicit]" id="itunes_explicit" type="checkbox"  value="1" <%= 'checked="checked"' if this_blog.itunes_explicit%> /><input name="setting[itunes_explicit]" type="hidden" value="0" />

<%= save("Save My Settings") %>

Cache

   <%= link_to 'Empty Fragment Cache', :controller => '/admin/cache', :action => 'sweep' %>

   <%= link_to 'Rebuild cached HTML', :controller => '/admin/cache', :action => 'sweep_html' %>

There are <%= @page_cache_size %> entries in the cache

    <%= save("Save My Settings") %>

  <% end %>


Fixed NPE for work publishing

Fixed NPE for work publishing

  <% if @page && @work && @collection
       title = @collection.title + ' -- ' + @work.title + ' -- ' + @page.title + ' (FromThePage)'
     elsif @work && @collection
       title = @collection.title + ' -- ' + @work.title + ' (FromThePage)'
     elsif @article && @collection
       title = @collection.title + ' -- ' + @article.title + ' (FromThePage)'
     elsif @collection
       title = @collection.title + ' (FromThePage)'
     else
       title = 'FromThePage'
     end
  %>
  <title><%= title %></title>
  <%=  javascript_include_tag :defaults %>
  <%= stylesheet_link_tag 'application' %>
  <%= stylesheet_link_tag 'transcribe' %>

    <%= link_to('Dashboard', { :controller => 'dashboard' }) %> |
    <% if logged_in? %>
	    <%= link_to('Log out', { :controller => 'account', :action => 'logout' }) %>
    <% else %>
	    <%= link_to('Log in', { :controller => 'account', :action => 'login' }) %>
	    |
	    <%= link_to('Sign Up', { :controller => 'account', :action => 'signup' }) %>
    <% end %>

        <%= link_to('FromThePage',
                    { :controller => 'dashboard',
                      :action => 'main_dashboard' },
                    { :class => 'site-logo' }) %>

      <% if @work || @collection%>

	        <% if @collection %>
		        <%= link_to(@collection.title,
		                    { :controller => 'collection',
		                      :action => 'show',
		                      :collection_id => @collection.id }) %>
	        <% end %>
	        <%= "—" if @collection && @work %>
	        <% if @work %>
		        <%= link_to(@work.title,
		                    { :controller => 'display',
		                      :action => 'read_work',
		                      :work_id => @work.id }) %>
	        <% end %>

      <% end %>

<% if(flash[:notice]) %>

<%= flash[:notice] %>

<% end %>
<% if(flash[:error]) %>

<%= flash[:error] %>

<% end %>

<%= @content_for_layout %>

  <% if @page
       title = @collection.title + ' -- ' + @work.title + ' -- ' + @page.title + ' (FromThePage)'
     elsif @work
       title = @collection.title + ' -- ' + @work.title + ' (FromThePage)'
     elsif @article
       title = @collection.title + ' -- ' + @article.title + ' (FromThePage)'
     elsif @collection
       title = @collection.title + ' (FromThePage)'
     else
       title = 'FromThePage'
     end
  %>
  <title><%= title %></title>
  <%=  javascript_include_tag :defaults %>
  <%= stylesheet_link_tag 'application' %>
  <%= stylesheet_link_tag 'transcribe' %>

    <%= link_to('Dashboard', { :controller => 'dashboard' }) %> |
    <% if logged_in? %>
	    <%= link_to('Log out', { :controller => 'account', :action => 'logout' }) %>
    <% else %>
	    <%= link_to('Log in', { :controller => 'account', :action => 'login' }) %>
	    |
	    <%= link_to('Sign Up', { :controller => 'account', :action => 'signup' }) %>
    <% end %>

        <%= link_to('FromThePage',
                    { :controller => 'dashboard',
                      :action => 'main_dashboard' },
                    { :class => 'site-logo' }) %>

      <% if @work || @collection%>

	        <% if @collection %>
		        <%= link_to(@collection.title,
		                    { :controller => 'collection',
		                      :action => 'show',
		                      :collection_id => @collection.id }) %>
	        <% end %>
	        <%= "—" if @collection && @work %>
	        <% if @work %>
		        <%= link_to(@work.title,
		                    { :controller => 'display',
		                      :action => 'read_work',
		                      :work_id => @work.id }) %>
	        <% end %>

      <% end %>

<% if(flash[:notice]) %>

<%= flash[:notice] %>

<% end %>
<% if(flash[:error]) %>

<%= flash[:error] %>

<% end %>

<%= @content_for_layout %>


fixed table layout to show entries in boxes

<% %>
<% @hours = ['12am', '1am', '2am', '3am', '4am', '5am', '6am', '7am', '8am', '9am', '10am', '11am', '12pm', '1pm',
            '2pm', '3pm', '4pm', '5pm', '6pm', '7pm', '8pm', '9pm', '10pm', '11pm']
             -%>
<% entries = @entries[Date.civil(@year, @month, @day)] -%>
<% entries.sort!{|a,b| a.start_time <=> b.start_time} if entries and !entries.empty? -%>
<% entries.sort!{|a,b| a.end_time <=> b.end_time} if entries and !entries.empty? -%>
<%= javascript_include_tag 'jquery', 'jqModal' %>
<%= stylesheet_link_tag 'jqModal', 'simple_calendar' %>

    <%= @date.strftime('%A, %B') %> <%= @date.day %>

  <% @hours.each_with_index do |hour, i| %>

     <th class="hour_header" id="<%= home_path %>/simple_calendar_entries/new/<%= @year %>_<%= @month %>_<%= @day %>?hour=<%= i %>&mode=day">
        <%= hour %>

      <% if entries and !entries.empty? -%>
        <% entries.each do |entry| -%>
          <% if entry.start_time.between?(some_time(@date, i, 00), some_time(@date, i, 29)) -%>
            <td id="entry_<%= entry.id %>" class="day_entry" rowspan="<%= entry.span %>" width="<%= (100 / entry.all_touching(entries).size) %>%" colspan="<%= 10 / entry.all_touching(entries).size %>">
              <% javascript_tag("$('entry_#{entry.id}').width = ($('day_cal_table').getWidth() - $('week_days_row').getWidth() - 5) / #{entry.all_touching(entries).size};") %>
              <%= entry.time %> - <%= entry.e_time %>

              <%= link_to entry.name, simple_calendar_entry_path(entry) + "?mode=#{@mode}", {:class => 'entry'} %>
              -
              <%= entry.detail %>

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

      <th class="hour_header" id="<%= home_path %>/simple_calendar_entries/new/<%= @year %>_<%= @month %>_<%= @day %>?hour=<%= i %>&mode=day">
      <% if entries and !entries.empty? -%>
        <% entries.each do |entry| -%>
          <% if entry.start_time.between?(some_time(@date, i, 30), some_time(@date, i, 59)) -%>
            <td id="entry_<%= entry.id %>" class="day_entry" rowspan="<%= entry.span %>" width="<%= (100 / entry.all_touching(entries).size) %>%" colspan="<%= 10 / entry.all_touching(entries).size %>">
              <% javascript_tag("$('entry_#{entry.id}').width = ($('day_cal_table').getWidth() - $('day_cal_table').down(2).getWidth() - 5) / #{entry.all_touching(entries).size};") %>
              <%= entry.time %> - <%= entry.e_time %>

              <%= link_to entry.name, simple_calendar_entry_path(entry) + "?mode=#{@mode}", {:class => 'entry'} %>
              -
              <%= entry.detail %>

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

  <% end %>

<% %>
<% @hours = ['12am', '1am', '2am', '3am', '4am', '5am', '6am', '7am', '8am', '9am', '10am', '11am', '12pm', '1pm',
            '2pm', '3pm', '4pm', '5pm', '6pm', '7pm', '8pm', '9pm', '10pm', '11pm']
             -%>
<% entries = @entries[Date.civil(@year, @month, @day)].sort{|a,b| a.start_time <=> b.start_time} -%>
<%= javascript_include_tag 'jquery', 'jqModal' %>
<%= stylesheet_link_tag 'jqModal', 'simple_calendar' %>

    <%= @date.strftime('%A, %B') %> <%= @date.day %>

  <% @hours.each_with_index do |hour, i| %>

     <th class="hour_header" id="<%= home_path %>/simple_calendar_entries/new/<%= @year %>_<%= @month %>_<%= @day %>?hour=<%= i %>&mode=day">
        <%= hour %>

        <% if entries and !entries.empty? -%>
          <% columns = 0 -%>
          <% touching_entries = 0 -%>
          <% entries.each do |entry| -%>
            <% if entry.start_time.between?(some_time(@date, i, 00), some_time(@date, i, 29)) -%>
              <% touching_entries = entry.all_touching(entries).size -%>
              <td id="entry_<%= entry.id %>" class="day_entry" width="<%= (100 / (entry.all_touching(entries).size)).to_s %>%">
                <%= entry.time %> - <%= entry.e_time %>
                <%= link_to entry.name, simple_calendar_entry_path(entry) + "?mode=#{@mode}", {:class => 'entry'} %>

                <% entry.detail %>

              <% columns += 1 -%>
            <% elsif some_time(@date, i, 01).between?(entry.start_time, entry.end_time) -%>
              <td id="entry_<%= entry.id %>" class="day_entry" width="<%= (100 / (entry.all_touching(entries).size)).to_s %>%">
                _cont: <%= entry.name %>

              <% columns += 1 -%>
            <% end -%>
          <% end -%>
          <% (columns..(touching_entries - 1)).each do -%>
            <td width="<%= (100 / touching_entries).to_s if touching_entries != 0 %>%">
          <% end -%>
        <% end -%>

      <th class="hour_header" id="<%= home_path %>/simple_calendar_entries/new/<%= @year %>_<%= @month %>_<%= @day %>?hour=<%= i %>&mode=day">

        <% if entries and !entries.empty? -%>
          <% columns = 0 -%>
          <% touching_entries = 0 -%>
          <% entries.each do |entry| -%>
            <% if entry.start_time.between?(some_time(@date, i, 30), some_time(@date, i, 59)) -%>
              <% touching_entries = entry.all_touching(entries).size -%>
              <td id="entry_<%= entry.id %>" class="day_entry" width="<%= (100 / (entry.all_touching(entries).size)).to_s %>%">
                <%= entry.time %> - <%= entry.e_time %>
                <%= link_to entry.name, simple_calendar_entry_path(entry) + "?mode=#{@mode}", {:class => 'entry'} %>

                <% entry.detail %>

              <% columns += 1 -%>
            <% elsif some_time(@date, i, 31).between?(entry.start_time, entry.end_time) -%>
              <td id="entry_<%= entry.id %>" class="day_entry" width="<%= (100 / (entry.all_touching(entries).size)).to_s %>%">
                _cont: <%= entry.name %>

              <% columns += 1 -%>
            <% end -%>
          <% end -%>
          <% (columns..(touching_entries - 1)).each do -%>
            <td width="<%= (100 / touching_entries).to_s if touching_entries != 0 %>%">
          <% end -%>
        <% end -%>

  <% end %>


remove deprecated start/end_form_tag [Anthony Eden]

git-svn-id: 04df172255571dc4112f542816614b941e6b1324@2507 567b1171-46fb-0310-a4c9-b4bef9110e78

<%% form_tag <%= controller_plural_name %>_path do -%>

Login

<%%= text_field_tag 'login' %>

Password

<%%= password_field_tag 'password' %>

<%%= submit_tag 'Log in' %>

<%% end -%>

<%%= start_form_tag <%= controller_plural_name %>_path %>

Login

<%%= text_field_tag 'login' %>

Password

<%%= password_field_tag 'password' %>

<%%= submit_tag 'Log in' %>

<%%= end_form_tag %>


ActionItem1049: fixing link

ActionItem1049: fixing link

<form>
  <%# FIXME %>

    <%= _('Editing theme "%s"') % @theme.name %>
    <%= button(:eyes, _('Preview this theme'), :action => 'start_test', :id => @theme.id) %>
    <%= button(:back, _('Back'), :action => 'index') %>

</form>

<%= _('CSS files') %>

    <% for css in @css_files %>

<%= link_to_remote(css, :url => { :action => 'css_editor', :id => @theme.id, :css => css }, :update => { :success => 'css-code' }) %>

    <% end %>

  <% button_bar do %>
    <%= lightbox_button(:add, _('New CSS'), :action => 'add_css', :id => @theme.id) %>
  <% end %>

<%= _('Images') %>

    <% for image in @image_files %>

<%= image_tag("/user_themes/#{@theme.id}/images/#{image}") %>

    <% end %>

  <% button_bar do %>
    <%= lightbox_button(:add, _('Add image'), :action => 'add_image', :id =>  @theme.id) %>
  <% end %>

    <%= _('Select a CSS file to edit') %>

<%# javascript_include_tag 'codepress/codepress' %>

<form>
  <%# FIXME %>

    <%= _('Editing theme "%s"') % @theme.name %>
    <%= button(:search, _('Preview this theme'), :action => 'index') %>
    <%= button(:back, _('Back'), :action => 'index') %>

</form>

<%= _('CSS files') %>

    <% for css in @css_files %>

<%= link_to_remote(css, :url => { :action => 'css_editor', :id => @theme.id, :css => css }, :update => { :success => 'css-code' }) %>

    <% end %>

  <% button_bar do %>
    <%= lightbox_button(:add, _('New CSS'), :action => 'add_css', :id => @theme.id) %>
  <% end %>

<%= _('Images') %>

    <% for image in @image_files %>

<%= image_tag("/user_themes/#{@theme.id}/images/#{image}") %>

    <% end %>

  <% button_bar do %>
    <%= lightbox_button(:add, _('Add image'), :action => 'add_image', :id =>  @theme.id) %>
  <% end %>

    <%= _('Select a CSS file to edit') %>

<%# javascript_include_tag 'codepress/codepress' %>


Help about pseudonymous requests.

Help about pseudonymous requests.

<% @title = "About" %>

<%= render :partial => 'help/alpha_notice' %>

Contact Us

If your question isn't answered here, or you just wanted to let us know
something about the site, contact us.

Introduction to WhatDoTheyKnow

What is WhatDoTheyKnow for?

To help you find out inside information about what the UK government
is doing.

How does the site work?

You choose the public authority that you would like information from, then
write a brief note describing what you want to know. We then send your request
to the public authority. Any response they make is automatically published on the
website for you and anyone else to find and read.

Why would I bother to do this?

You pay taxes, and then government does things with the money. All sorts of
things that affect your life, from healthcare through to national defence. Some
it does badly, some it does well. The more we find out about how government
works, the better able we are to make suggestions to improve the things that
are done badly, and to celebrate the things that are done well.

Why would the public authority bother to reply?

Under Freedom of Information (FOI) law, they have to respond.

Who makes it?

WhatDoTheyKnow is made by mySociety,
and was initially funded by the JRSST Charitable Trust. mySociety is a project of the
registered charity UK Citizens Online Democracy.
If you like what we're doing, then you can
make a donation.

Making requests

You're missing the public authority that I want to request from!

Please contact us with the name of the public authority and,
if you can find it, their contact email address for Freedom of Information requests.
If you'd like to help add a whole category of public authority to the site, for example all
primary care trusts or all schools, then please
edit this shared spreadsheet (Google account required).

How quickly will I get a response?

By law public authorities must respond within 20 days, excluding weekends and
any UK bank holidays. The date that the response is due by is shown on the
page for your request. You will be emailed if this date goes by without
a response, so you can send the public authority another note to hurry them up.

Can you tell me more of the nitty gritty about the process of making requests?

Have a look at the
access to official information
pages on the Information Commisioner's website.

Can I request information about myself?

Not using this site. Requests made using WhatDoTheyKnow are public, made under the
Freedom of Information Act, and cannot help you find information about a
private individual. If you would like to know what information a public
authority holds about yourself, you should make a "Subject Access Request" in
private using Data Protection law.  The leaflet Subject
Access - A guide for data subjects (on the Information Commisioner's
website) explains how to do this.

I'd like to keep my request secret! (At least until I publish my story)

WhatDoTheyKnow is currently only designed for public requests. All
responses that we receive are automatically published on the website for anyone
to read.  You should contact the public authority directly if you would like to
make a request in private.  If you're interested in buying a system which helps
you manage FOI requests in secret, then contact us.

Privacy policy

Who gets to see my email address?

We will not disclose your email address to anyone, including the public
authority you are sending a request to, unless we are obliged to by law,
or you ask us to. If you send a message to another user on the site, then
it will reveal your email address to them. You will be told that this
is going to happen.

Will you send nasty, brutish spam to my email address?

Nope. After you sign up to WhatDoTheyKnow we will only send you emails
about the site or related mySociety services. We will never give or sell
your email addresses to anyone else, unless we are obliged to by law, or you
ask us to.

Why will my name appear publically on the site?

It means that someone researching the same area can get in touch with you,
and maybe give you more information or ideas relating to your request.  Also,
we're going to publish the response with the name of the civil servant who
wrote it, so it seems only fair that your name should be public too!
Therefore, we encourage you to use your real name, but you may use a pseudonym
if you would like to be anonymous.

So I can make an FOI request using a pseudonym?

Yes, you can. It is good practice for the public authority to reply to such
a request, except in special circumstances such as if they suspect you of
making vexatious requests. See Freedom of Information Good Practice Guidance No 6 for details. You
should refer to this if a public authority attempts to refuse a request because you used a pseudonym.
Saying that, you can avoid the problem by simply making your pseudonym look like a real person's name,
as there is no general obligation to prove your identity.

Why does the list of things that I'm tracking appear publically on the site?

This helps you find others who are researching the same area of government,
so you can form groups to investigate or campaign together. It also helps us
show requests which are related to other requests. If you've ever used a
"social bookmarking" website such as Delicious, Digg or reddit, think of it like
that.

<% @title = "About" %>

<%= render :partial => 'help/alpha_notice' %>

Contact Us

If your question isn't answered here, or you just wanted to let us know
something about the site, contact us.

Introduction to WhatDoTheyKnow

What is WhatDoTheyKnow for?

To help you find out inside information about what the UK government
is doing.

How does the site work?

You choose the public authority that you would like information from, then
write a brief note describing what you want to know. We then send your request
to the public authority. Any response they make is automatically published on the
website for you and anyone else to find and read.

Why would I bother to do this?

You pay taxes, and then government does things with the money. All sorts of
things that affect your life, from healthcare through to national defence. Some
it does badly, some it does well. The more we find out about how government
works, the better able we are to make suggestions to improve the things that
are done badly, and to celebrate the things that are done well.

Why would the public authority bother to reply?

Under Freedom of Information (FOI) law, they have to respond.

Who makes it?

WhatDoTheyKnow is made by mySociety,
and was initially funded by the JRSST Charitable Trust. mySociety is a project of the
registered charity UK Citizens Online Democracy.
If you like what we're doing, then you can
make a donation.

Making requests

You're missing the public authority that I want to request from!

Please contact us with the name of the public authority and,
if you can find it, their contact email address for Freedom of Information requests.
If you'd like to help add a whole category of public authority to the site, for example all
primary care trusts or all schools, then please
edit this shared spreadsheet (Google account required).

How quickly will I get a response?

By law public authorities must respond within 20 days, excluding weekends and
any UK bank holidays. The date that the response is due by is shown on the
page for your request. You will be emailed if this date goes by without
a response, so you can send the public authority another note to hurry them up.

Can you tell me more of the nitty gritty about the process of making requests?

Have a look at the
access to official information
pages on the Information Commisioner's website.

Can I request information about myself?

Not using this site. Requests made using WhatDoTheyKnow are public, made under the
Freedom of Information Act, and cannot help you find information about a
private individual. If you would like to know what information a public
authority holds about yourself, you should make a "Subject Access Request" in
private using Data Protection law.  The leaflet Subject
Access - A guide for data subjects (on the Information Commisioner's
website) explains how to do this.

I'd like to keep my request secret! (At least until I publish my story)

WhatDoTheyKnow is currently only designed for public requests. All
responses that we receive are automatically published on the website for anyone
to read.  You should contact the public authority directly if you would like to
make a request in private.  If you're interested in buying a system which helps
you manage FOI requests in secret, then contact us.

Privacy policy

Who gets to see my email address?

We will not disclose your email address to anyone, including the public
authority you are sending a request to, unless we are obliged to by law,
or you ask us to. If you send a message to another user on the site, then
it will reveal your email address to them. You will be told that this
is going to happen.

Will you send nasty, brutish spam to my email address?

Nope. After you sign up to WhatDoTheyKnow we will only send you emails
about the site or related mySociety services. We will never give or sell
your email addresses to anyone else, unless we are obliged to by law, or you
ask us to.

Why will my name appear publically on the site?

It means that someone researching the same area can get in touch with you,
and maybe give you more information or ideas relating to your request.  Also,
we're going to publish the response with the name of the civil servant who
wrote it, so it seems only fair that your name should be public too!
Therefore, we encourage you to use your real name, but you may use a pseudonym
if you would like to be anonymous.

Why does the list of things that I'm tracking appear publically on the site?

This helps you find others who are researching the same area of government,
so you can form groups to investigate or campaign together. It also helps us
show requests which are related to other requests. If you've ever used a
"social bookmarking" website such as Delicious, Digg or reddit, think of it like
that.


Only show start of messages by default, with JS toggle to see the remainder.

<% @title = "FOI request - " + h(@info_request.title) %>
<%= javascript_include_tag :defaults %>

<%=@title%>

<% for column in InfoRequest.content_columns %>
  <%= column.human_name %>: <%=h @info_request.send(column.name) %>

<% end %>
Created by: <%= user_both_links(@info_request.user) %>

Public authority: <%= public_body_both_links(@info_request.public_body) %>

Incoming email address: <%= link_to h(@info_request.incoming_email), "mailto:" + @info_request.incoming_email %>

    <%= link_to 'Public page', main_url(request_url(@info_request)) %>
    | <%= link_to 'Edit', '../edit/' + @info_request.id.to_s %>
    | <%= link_to 'FOI officer upload URL', '../generate_upload_url/' + @info_request.id.to_s %> (see also links on incoming messages below)

Events

  Id
  <% for column in InfoRequestEvent.content_columns %>
    <%= column.human_name %>
  <% end %>

<% for info_request_event in @info_request.info_request_events.find(:all, :order => "created_at, id") %>
  <tr class="<%= cycle('odd', 'even') %>">
  <%=h info_request_event.id %>
  <% for column in InfoRequestEvent.content_columns %>

      <% if column.name == 'params_yaml' %>

<%= info_request_event.params_yaml %>

      <% elsif column.text? %>
        <%=h (info_request_event.send(column.name) || '').gsub(/_/,' ') %>
      <% else %>
        <%=h info_request_event.send(column.name) %>
      <% end %>

  <% end %>

<% end %>

Outgoing messages

    Id
    <% for column in OutgoingMessage.content_columns %>
      <%= column.human_name %>
    <% end %>
    Actions

<% for outgoing_message in @info_request.outgoing_messages.find(:all, :order => 'created_at') %>
  <tr class="<%= cycle('odd', 'even') %>">
  <%=h outgoing_message.id %>
  <% for column in OutgoingMessage.content_columns.map { |c| c.name } %>

    <% if column == 'body' %>

<%= simple_format( truncate(outgoing_message.body, 400,
                  link_to_function("...", "$(this).up('td').childElements().invoke('toggle')")
            )) %>

<%= simple_format( outgoing_message.body ) %>

    <% else %>
      <%= simple_format( outgoing_message.send(column) ) %>
    <% end %>

  <% end %>

  <% form_tag '../resend' do %>

          <%= hidden_field_tag 'outgoing_message_id', outgoing_message.id %>
          <%= submit_tag "Resend" %>

  <% end %>
  <%= link_to "Edit", '../edit_outgoing/' + outgoing_message.id.to_s %>

<% end %>

Incoming messages

  Id
  <% for column in IncomingMessage.content_columns %>
    <%= column.human_name %>
  <% end %>
  Actions

<% for incoming_message in @info_request.incoming_messages.find(:all, :order => 'created_at') %>
  <tr class="<%= cycle('odd', 'even') %>" id="incoming-<%=incoming_message.id.to_s%>">
  <%=h incoming_message.id %>
  <% for column in IncomingMessage.content_columns.map { |c| c.name } %>
    <% if column =~ /^cached_.*?_text$/ %>

<%= simple_format( truncate(incoming_message.send(column), 400,
                  link_to_function("...", "$(this).up('td').childElements().invoke('toggle')")
            )) %>

<%= simple_format( incoming_message.send(column) ) %>

    <% else %>
      <%= simple_format( incoming_message.send(column) ) %>
    <% end %>
  <% end %>

        <% if !incoming_message.raw_email_id.nil? %>

            <%= link_to "View raw email", "../show_raw_email/" + incoming_message.raw_email_id.to_s %>

        <% end %>
        <%= render :partial => 'incoming_message_actions', :locals => { :incoming_message => incoming_message } %>

<% end %>

Annotations

<% if @info_request.comments.size > 0 %>

    Id
    Posted by
    <% for column in Comment.content_columns %>
      <%= column.human_name %>
    <% end %>
    Actions

  <% for comment in @info_request.comments %>
    <tr class="<%= cycle('odd', 'even') %>">
    <%=h comment.id %>
    <%= user_both_links(comment.user) %>
    <% for column in Comment.content_columns.map { |c| c.name } %>
      <% if column == 'body' && !comment.visible %>
          <s><%=h comment.send(column) %></s>
      <% else %>
          <%=h comment.send(column) %>
      <% end %>
    <% end %>

        <%= link_to "Edit", '../edit_comment/' + comment.id.to_s %>

  <% end %>

<% else %>

None yet.

<% end %>

Exim delivery logs

(Lines containing the request incoming email address, updated hourly.)

<% for exim_log_done_id, exim_logs in @info_request.exim_logs.group_by(&:exim_log_done_id) %>

<% for exim_log in exim_logs %><%=h exim_log.line%><% end %>

<% end %>
<% if @info_request.exim_logs.size == 0 %>

None (perhaps this is an old or a very new request)

<% end %>

Censor rules

<%= render :partial => 'admin_censor_rule/show', :locals => { :censor_rules => @info_request.censor_rules, :info_request => @info_request } %>

<% @title = "FOI request - " + h(@info_request.title) %>

<%=@title%>

<% for column in InfoRequest.content_columns %>
  <%= column.human_name %>: <%=h @info_request.send(column.name) %>

<% end %>
Created by: <%= user_both_links(@info_request.user) %>

Public authority: <%= public_body_both_links(@info_request.public_body) %>

Incoming email address: <%= link_to h(@info_request.incoming_email), "mailto:" + @info_request.incoming_email %>

    <%= link_to 'Public page', main_url(request_url(@info_request)) %>
    | <%= link_to 'Edit', '../edit/' + @info_request.id.to_s %>
    | <%= link_to 'FOI officer upload URL', '../generate_upload_url/' + @info_request.id.to_s %> (see also links on incoming messages below)

Events

  Id
  <% for column in InfoRequestEvent.content_columns %>
    <%= column.human_name %>
  <% end %>

<% for info_request_event in @info_request.info_request_events.find(:all, :order => "created_at, id") %>
  <tr class="<%= cycle('odd', 'even') %>">
  <%=h info_request_event.id %>
  <% for column in InfoRequestEvent.content_columns %>

      <% if column.name == 'params_yaml' %>

<%= info_request_event.params_yaml %>

      <% elsif column.text? %>
        <%=h (info_request_event.send(column.name) || '').gsub(/_/,' ') %>
      <% else %>
        <%=h info_request_event.send(column.name) %>
      <% end %>

  <% end %>

<% end %>

Outgoing messages

    Id
    <% for column in OutgoingMessage.content_columns %>
      <%= column.human_name %>
    <% end %>
    Actions

<% for outgoing_message in @info_request.outgoing_messages.find(:all, :order => 'created_at') %>
  <tr class="<%= cycle('odd', 'even') %>">
  <%=h outgoing_message.id %>
  <% for column in OutgoingMessage.content_columns.map { |c| c.name } %>
    <%= simple_format( outgoing_message.send(column) ) %>
  <% end %>

  <% form_tag '../resend' do %>

          <%= hidden_field_tag 'outgoing_message_id', outgoing_message.id %>
          <%= submit_tag "Resend" %>

  <% end %>
  <%= link_to "Edit", '../edit_outgoing/' + outgoing_message.id.to_s %>

<% end %>

Incoming messages

  Id
  <% for column in IncomingMessage.content_columns %>
    <%= column.human_name %>
  <% end %>
  Actions

<% for incoming_message in @info_request.incoming_messages.find(:all, :order => 'created_at') %>
  <tr class="<%= cycle('odd', 'even') %>" id="incoming-<%=incoming_message.id.to_s%>">
  <%=h incoming_message.id %>
  <% for column in IncomingMessage.content_columns.map { |c| c.name } %>
    <%= simple_format( incoming_message.send(column) ) %>
  <% end %>

        <% if !incoming_message.raw_email_id.nil? %>

            <%= link_to "View raw email", "../show_raw_email/" + incoming_message.raw_email_id.to_s %>

        <% end %>
        <%= render :partial => 'incoming_message_actions', :locals => { :incoming_message => incoming_message } %>

<% end %>

Annotations

<% if @info_request.comments.size > 0 %>

    Id
    Posted by
    <% for column in Comment.content_columns %>
      <%= column.human_name %>
    <% end %>
    Actions

  <% for comment in @info_request.comments %>
    <tr class="<%= cycle('odd', 'even') %>">
    <%=h comment.id %>
    <%= user_both_links(comment.user) %>
    <% for column in Comment.content_columns.map { |c| c.name } %>
      <% if column == 'body' && !comment.visible %>
          <s><%=h comment.send(column) %></s>
      <% else %>
          <%=h comment.send(column) %>
      <% end %>
    <% end %>

        <%= link_to "Edit", '../edit_comment/' + comment.id.to_s %>

  <% end %>

<% else %>

None yet.

<% end %>

Exim delivery logs

(Lines containing the request incoming email address, updated hourly.)

<% for exim_log_done_id, exim_logs in @info_request.exim_logs.group_by(&:exim_log_done_id) %>

<% for exim_log in exim_logs %><%=h exim_log.line%><% end %>

<% end %>
<% if @info_request.exim_logs.size == 0 %>

None (perhaps this is an old or a very new request)

<% end %>

Censor rules

<%= render :partial => 'admin_censor_rule/show', :locals => { :censor_rules => @info_request.censor_rules, :info_request => @info_request } %>


disabled group discription

disabled group discription

Short name (must only contain alphanumeric characters)

<%= text_field 'group', 'name'  %>

Full name

<%= text_field 'group', 'full_name'  %>

Public Summary

<%= text_field 'group', 'summary'  %>

Public Description

<%= text_area 'group', 'public_description', :rows => 10  %>

Private Description

<%= text_area 'group', 'private_description', :rows => 10  %>


Remove sidebar placeholder text.

Remove sidebar placeholder text.

<% @title = h(@info_request.title) %>

<% if @info_request.awaiting_description %>

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

<% end %>

<%=@title%>

A Freedom of Information request to
    <%= public_body_link(@info_request.public_body) %>
    by
    <%= user_link(@info_request.user) %>

    <% if @info_request.awaiting_description %>
        <% if @is_owning_user %>
            Please answer the question above so we know whether the
            <%= MySociety::Format.fancy_pluralize(@new_responses_count, 'recent response contains', 'recent responses contain') %> useful information.
        <% else %>
            This request has an unknown status. We're waiting for
            <%= user_link(@info_request.user) %> to read
            <%= MySociety::Format.fancy_pluralize(@new_responses_count, 'a recent response', 'recent responses') %>
            and update the status.
        <% end %>
    <% elsif @status == 'waiting_response' %>
        Currently waiting for a response from <%= public_body_link(@info_request.public_body) %>,
        due by <%= simple_date(@info_request.date_response_required_by) %>.
    <% elsif @status == 'waiting_response_overdue' %>
        Currently overdue a response from <%=
        public_body_link(@info_request.public_body) %>. The
        <%= link_to "response was due", about_url %>

        on <%= simple_date(@info_request.date_response_required_by) %>.
    <% elsif @status == 'rejected' %>
        The request was rejected by <%= public_body_link(@info_request.public_body) %>.
    <% elsif @status == 'successful' %>
        The request was successful.
    <% elsif @status == 'partially_successful' %>
        The request was partially successful.
    <% elsif @status == 'waiting_clarification' %>
        <% if @is_owning_user %>
            <%=h @info_request.public_body.name %> is waiting for your clarification.
            Please
            <%= link_to "send a follow up message", show_response_url(:id => @info_request.id, :incoming_message_id => @info_request.get_last_response.id) + "#show_response_followup" %>.
        <% else %>
            The request is waiting for clarification.
            If you are
            <%= user_link(@info_request.user) %>, please
            <%= link_to "sign in", signin_url(:r => request.request_uri) %> to send a follow up message.
        <% end %>
    <% elsif @status == 'requires_admin' %>
        This request has had an unusual response, and requires attention from the foi.mysociety.org team.
    <% else %>
        <% raise "unknown status " + @status %>
    <% end %>

    <% for info_request_event in @info_request_events %>
        <%= render :partial => 'correspondence', :locals => { :info_request_event => info_request_event } %>
    <% end %>

<% if @info_request.awaiting_description %>

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

<% end %>

<% @title = h(@info_request.title) %>

<% if @info_request.awaiting_description %>

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

<% end %>

<%=@title%>

A Freedom of Information request to
    <%= public_body_link(@info_request.public_body) %>
    by
    <%= user_link(@info_request.user) %>

    <% if @info_request.awaiting_description %>
        <% if @is_owning_user %>
            Please answer the question above so we know whether the
            <%= MySociety::Format.fancy_pluralize(@new_responses_count, 'recent response contains', 'recent responses contain') %> useful information.
        <% else %>
            This request has an unknown status. We're waiting for
            <%= user_link(@info_request.user) %> to read
            <%= MySociety::Format.fancy_pluralize(@new_responses_count, 'a recent response', 'recent responses') %>
            and update the status.
        <% end %>
    <% elsif @status == 'waiting_response' %>
        Currently waiting for a response from <%= public_body_link(@info_request.public_body) %>,
        due by <%= simple_date(@info_request.date_response_required_by) %>.
    <% elsif @status == 'waiting_response_overdue' %>
        Currently overdue a response from <%=
        public_body_link(@info_request.public_body) %>. The
        <%= link_to "response was due", about_url %>

        on <%= simple_date(@info_request.date_response_required_by) %>.
    <% elsif @status == 'rejected' %>
        The request was rejected by <%= public_body_link(@info_request.public_body) %>.
    <% elsif @status == 'successful' %>
        The request was successful.
    <% elsif @status == 'partially_successful' %>
        The request was partially successful.
    <% elsif @status == 'waiting_clarification' %>
        <% if @is_owning_user %>
            <%=h @info_request.public_body.name %> is waiting for your clarification.
            Please
            <%= link_to "send a follow up message", show_response_url(:id => @info_request.id, :incoming_message_id => @info_request.get_last_response.id) + "#show_response_followup" %>.
        <% else %>
            The request is waiting for clarification.
            If you are
            <%= user_link(@info_request.user) %>, please
            <%= link_to "sign in", signin_url(:r => request.request_uri) %> to send a follow up message.
        <% end %>
    <% elsif @status == 'requires_admin' %>
        This request has had an unusual response, and requires attention from the foi.mysociety.org team.
    <% else %>
        <% raise "unknown status " + @status %>
    <% end %>

    <% for info_request_event in @info_request_events %>
        <%= render :partial => 'correspondence', :locals => { :info_request_event => info_request_event } %>
    <% end %>

Juicy stuff will be here

For now it is just padding to make the messages on the left
    narrower, so I can see what the formatting is like.

<% if @info_request.awaiting_description %>

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

<% end %>


Added version number to page title

Added version number to page title

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN"
	"http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">

    <meta http-equiv="Content-type" content="text/html; charset=utf-8" />
    <title>Twitter4R - Open Source Ruby Project Code Coverage (RCov C0)</title>
    <meta type="keywords" content="twitter4r, twitter, rest, api, open source, oss, open source software, open source project, rubyforge, code coverage, c0 code coverage, code metrics"/>
    <link href="../stylesheets/site.css" type="text/css" media="screen" rel="stylesheet"/>
    <link rel="shortcut icon" href="favicon.ico" />

Documentation

Twitter4R: RDoc

Twitter4R: RCov

Project Links

MIT License

Rubyforge: Forums

Rubyforge: Files

Retrospectiva: Blog

Retrospectiva: Wiki

Retrospectiva: Tickets

Twitter4R v<%= version %>

Simple Pure Ruby API for Twitter

Code Coverage Metrics (C0)

        <% unless index %>
          [Back to coverage index]
        <% end %>

<%= legend_content %>

        <%= table_content %>

<%= code_content %>

© Copyright 2006-2007 Susan Potter.  All rights reserved.

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN"
	"http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">

    <meta http-equiv="Content-type" content="text/html; charset=utf-8" />
    <title>Twitter4R - Open Source Ruby Project Code Coverage (RCov C0)</title>
    <meta type="keywords" content="twitter4r, twitter, rest, api, open source, oss, open source software, open source project, rubyforge, code coverage, c0 code coverage, code metrics"/>
    <link href="../stylesheets/site.css" type="text/css" media="screen" rel="stylesheet"/>
    <link rel="shortcut icon" href="favicon.ico" />

Documentation

Twitter4R: RDoc

Twitter4R: RCov

Project Links

MIT License

Rubyforge: Forums

Rubyforge: Files

Retrospectiva: Blog

Retrospectiva: Wiki

Retrospectiva: Tickets

Twitter4R

Simple Pure Ruby API for Twitter

Code Coverage Metrics (C0)

        <% unless index %>
          [Back to index]
        <% end %>

        <%= legend_content %>
        <%= table_content %>
        <%= code_content %>

© Copyright 2006-2007 Susan Potter.  All rights reserved.


Made additional side-links yield appear above the Log Out option.

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

  <%= stylesheet_link_tag 'andreas06' %>

Skip to: site menu | section menu | main content

e.f.l.

		Edmonton Free Library

Site menu:

		Welcome |

		<a <%= link_to 'books', books_path, :class => 'navitab' %> |
		<a <%= link_to 'video', videos_path, :class => 'navitab' %> |

		find out more |

Back to top

e.f.l.

					<% if current_user %>
						<%= user_link current_user, :class => 'nav' %>

						<%= link_to 'edit profile', {:controller => 'account'}, :class =>'nav' %>

					<% else %>
						<%= link_to 'log in', {:controller => 'account', :action => 'login'}, :class=> 'nav' %>

						<%= link_to 'new account', {:controller => 'account', :action => 'signup'}, :class=> 'nav' %>

					<% end %>
					<%= yield :extra_side_links %>
					<% if current_user %>
						<%= link_to 'log out', {:controller => 'account', :action => 'logout'}, :class=> 'nav' %>
					<% end %>
					Back to top

					<% if flash[:notice] %>

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

					<% elsif flash[:error] %>

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

					<% end %>

					<%= yield  %>

Back to top

 Copy away mofos | Design by Andreas Viklund

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

  <%= stylesheet_link_tag 'andreas06' %>

Skip to: site menu | section menu | main content

e.f.l.

		Edmonton Free Library

Site menu:

		Welcome |

		<a <%= link_to 'books', books_path, :class => 'navitab' %> |
		<a <%= link_to 'video', videos_path, :class => 'navitab' %> |

		find out more |

Back to top

e.f.l.

					<% if current_user %>
						<%= user_link current_user, :class => 'nav' %>

						<%= link_to 'edit profile', {:controller => 'account'}, :class =>'nav' %>

						<%= link_to 'log out', {:controller => 'account', :action => 'logout'}, :class=> 'nav' %>
					<% else %>
						<%= link_to 'log in', {:controller => 'account', :action => 'login'}, :class=> 'nav' %>

						<%= link_to 'new account', {:controller => 'account', :action => 'signup'}, :class=> 'nav' %>

					<% end %>
          <%= yield :extra_side_links %>
					Back to top

					<% if flash[:notice] %>

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

					<% elsif flash[:error] %>

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

					<% end %>

					<%= yield  %>

Back to top

 Copy away mofos | Design by Andreas Viklund


[Mezuro] Inserted links on class types

[Mezuro] Inserted links on class types

<%= _('Source tree') %>

<% module_name = source_tree.module.name %>
<% module_label = "#{module_name} (#{source_tree.module.granularity})" %>

  <% if module_name != project_name %>
    <a href="#" class="source-tree-link" data-module-name="<%= project_name %>">
      <%= project_name %>

  <% end %>

  <% split_link = source_tree.module.ancestor_names %>
  <% split_link.each do |link| %>
    /<a href="#" class="source-tree-link" data-module-name="<%= link %>">
      <%= link.split(".").last %>

  <% end %>

<% if source_tree.children %>

    <% source_tree.children.each do |child| %>
      <% if child.module.granularity=='PACKAGE' %>

	        <%= image_tag('/plugins/mezuro/images/folder.png')%>
	        <a href='#' class="source-tree-link" data-module-name="<%= child.module.name %>"><%= child.module.name %>

      <% else %>

	        <%= image_tag('/plugins/mezuro/images/file.png') %>

                  <a href='#' class="source-tree-link" data-module-name="<%= child.module.name %>">
                    <%= child.module.name %>

      <% end %>
    <% end %>

<% end %>

<%= _('Source tree') %>

<% module_name = source_tree.module.name %>
<% module_label = "#{module_name} (#{source_tree.module.granularity})" %>

  <% if module_name != project_name %>
    <a href="#" class="source-tree-link" data-module-name="<%= project_name %>">
      <%= project_name %>

  <% end %>

  <% split_link = source_tree.module.ancestor_names %>
  <% split_link.each do |link| %>
    /<a href="#" class="source-tree-link" data-module-name="<%= link %>">
      <%= link.split(".").last %>

  <% end %>

<% if source_tree.children %>

    <% source_tree.children.each do |child| %>
      <% if child.module.granularity=='PACKAGE' %>

	        <%= image_tag('/plugins/mezuro/images/folder.png')%>
	        <a href='#' class="source-tree-link" data-module-name="<%= child.module.name %>"><%= child.module.name %>

      <% else %>

	        <%= image_tag('/plugins/mezuro/images/file.png') %>
	        <%= child.module.name %>

      <% end %>
    <% end %>

<% end %>


Fix bbox display again, how do we keep mixing our lons and lats?

    Created at:
    <%= h(changeset_details.created_at) %>

    Closed at:
    <%= h(changeset_details.closed_at) %>

  <% if changeset_details.user.data_public? %>

      Belongs to:
      <%= link_to h(changeset_details.user.display_name), :controller => "user", :action => "view", :display_name => changeset_details.user.display_name %>

  <% end %>

  <%= render :partial => "tag_details", :object => changeset_details %>

    Bounding box:
    <% unless changeset_details.has_valid_bbox? %>
      No bounding box has been stored for this changeset.
    <% else
          minlon = changeset_details.min_lon/GeoRecord::SCALE.to_f
          minlat = changeset_details.min_lat/GeoRecord::SCALE.to_f
          maxlon = changeset_details.max_lon/GeoRecord::SCALE.to_f
          maxlat = changeset_details.max_lat/GeoRecord::SCALE.to_f
    %>

            <%=maxlat -%>

            <%=minlon -%>
            (<a href='/?minlon=<%= minlon %>&minlat=<%= minlat %>&maxlon=<%= maxlon %>&maxlat=<%= maxlat %>&box=yes' title='show area box'>box)
            <%=maxlon -%>

            <%= minlat -%>

    <% end %>

  <% unless @nodes.empty? %>

      Has the following <%= @node_pages.item_count %> nodes:

          <% @nodes.each do |node| %>

<%= link_to "Node #{node.id.to_s}, version #{node.version.to_s}", :action => "node", :id => node.id.to_s %>

          <% end %>

    <%= render :partial => 'paging_nav', :locals => { :pages => @node_pages, :page_param => "node_page"} %>
  <% end %>

  <% unless @ways.empty? %>

      Has the following <%= @way_pages.item_count %> ways:

          <% @ways.each do |way| %>

<%= link_to "Way #{way.id.to_s}, version #{way.version.to_s}", :action => "way", :id => way.id.to_s %>

          <% end %>
          <%=
          #render :partial => "containing_relation", :collection => changeset_details.containing_relation_members
          %>

    <%= render :partial => 'paging_nav', :locals => { :pages => @way_pages, :page_param => "way_page" } %>
  <% end %>

  <% unless @relations.empty? %>

      Has the following <%= @relation_pages.item_count %> relations:

          <% @relations.each do |relation| %>

<%= link_to "Relation #{relation.id.to_s}, version #{relation.version.to_s}", :action => "relation", :id => relation.id.to_s %>

          <% end %>

    <%= render :partial => 'paging_nav', :locals => { :pages => @relation_pages, :page_param => "relation_page" } %>
  <% end %>

    Created at:
    <%= h(changeset_details.created_at) %>

    Closed at:
    <%= h(changeset_details.closed_at) %>

  <% if changeset_details.user.data_public? %>

      Belongs to:
      <%= link_to h(changeset_details.user.display_name), :controller => "user", :action => "view", :display_name => changeset_details.user.display_name %>

  <% end %>

  <%= render :partial => "tag_details", :object => changeset_details %>

    Bounding box:
    <% unless changeset_details.has_valid_bbox? %>
      No bounding box has been stored for this changeset.
    <% else
          minlon = changeset_details.min_lon/GeoRecord::SCALE.to_f
          minlat = changeset_details.min_lat/GeoRecord::SCALE.to_f
          maxlon = changeset_details.max_lon/GeoRecord::SCALE.to_f
          maxlat = changeset_details.max_lat/GeoRecord::SCALE.to_f
    %>

            <%=maxlat -%>

            <%=minlon -%>
            (<a href='/?minlon=<%= minlon %>&minlat=<%= minlat %>&maxlon=<%= maxlon %>&maxlat=<%= maxlat %>&box=yes' title='show area box'>box)
            <%=maxlon -%>

            <%= minlon -%>

    <% end %>

  <% unless @nodes.empty? %>

      Has the following <%= @node_pages.item_count %> nodes:

          <% @nodes.each do |node| %>

<%= link_to "Node #{node.id.to_s}, version #{node.version.to_s}", :action => "node", :id => node.id.to_s %>

          <% end %>

    <%= render :partial => 'paging_nav', :locals => { :pages => @node_pages, :page_param => "node_page"} %>
  <% end %>

  <% unless @ways.empty? %>

      Has the following <%= @way_pages.item_count %> ways:

          <% @ways.each do |way| %>

<%= link_to "Way #{way.id.to_s}, version #{way.version.to_s}", :action => "way", :id => way.id.to_s %>

          <% end %>
          <%=
          #render :partial => "containing_relation", :collection => changeset_details.containing_relation_members
          %>

    <%= render :partial => 'paging_nav', :locals => { :pages => @way_pages, :page_param => "way_page" } %>
  <% end %>

  <% unless @relations.empty? %>

      Has the following <%= @relation_pages.item_count %> relations:

          <% @relations.each do |relation| %>

<%= link_to "Relation #{relation.id.to_s}, version #{relation.version.to_s}", :action => "relation", :id => relation.id.to_s %>

          <% end %>

    <%= render :partial => 'paging_nav', :locals => { :pages => @relation_pages, :page_param => "relation_page" } %>
  <% end %>


minor cosmetic changes (typography mostly)

@import url(http://fonts.googleapis.com/css?family=Permanent+Marker&v2);

body
{
  font-family: Verdana, Arial, sans-serif;
}

h1, h2, h3
{
  font-family: Gill Sans, Trebuchet MS, Helvetica, sans-serif;
}

#banner
{
	background-color: #003399;
	background-image: none;
	border-color: #999;
	border-width: 1px;
}

#tagline,
#header
{
  visibility: hidden;
}

#orglogo
{
  text-align: left;
	font-size: 64px;
  font-family: 'Permanent Marker', cursive;
  margin-left: 0px;
	width: 80%;

	background-image: url(../asktheeu-theme/images/navimg/asktheeu-logo.png);
	background-repeat: no-repeat;
	background-position: -30px 0px;
	height: 100px;

  color: #FFCC00;
}

#orglogo span
{
  margin-left: 2.5em;
}

div.lang {
  top: 5px;
  padding-right: 5px;
  font-weight: bold;
  color: #DDD;
}

div.lang a {
  color: #777;
}

#topnav {
  background-color: #002266;
  font-weight: bold;
}

@import url(http://fonts.googleapis.com/css?family=Permanent+Marker&v2);

#banner
{
	background-color: #003399;
	background-image: none;
}

#tagline,
#header
{
  visibility: hidden;
}

#orglogo
{
  text-align: left;
	font-size: 64px;
  font-family: 'Permanent Marker', cursive;
  margin-left: 0px;
	width: 80%;

	background-image: url(../asktheeu-theme/images/navimg/asktheeu-logo.png);
	background-repeat: no-repeat;
	background-position: -30px 0px;
	height: 125px;

  color: #FFCC00;
}

#orglogo span
{
  margin-left: 2.5em;
}

div.lang {
  top: 5px;
  padding-right: 5px;
  font-weight: bold;
  color: #DDD;
}

div.lang a {
  color: #777;
}


Arg!  Tired of the comment textarea being so small!!

git-svn-id: bc266cc4dcdee41d9588461a87969679bbc3047f@882 7a65b82a-1d14-0410-b525-e2835e71a0b4

<%= :form_comments_summary.t %>:

<%= text_field("comment", "summary", :size => 80) %>

<%= :form_comments_comment.t %>:

<%= text_area("comment", "comment", :cols => 80, :rows => 10) %>

<%= render(:partial => 'shared/textilize_help') %>

<%= focus_on('comment_summary') %>

<%= :form_comments_summary.t %>:

<%= text_field("comment", "summary", :size => 80) %>

<%= :form_comments_comment.t %>:

<%= text_area("comment", "comment", :cols => 80, :rows => 5) %>

<%= render(:partial => 'shared/textilize_help') %>

<%= focus_on('comment_summary') %>


Fix identation

Fix identation

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="<%= html_language %>" lang="<%= html_language %>">

    <title><%= h page_title %></title>
    <%= yield(:feeds) %>

    <meta http-equiv="Content-Type" content="text/html; charset=utf-8"/>
    <meta name="description" content="<%= @environment.name %>" />

    <meta name="twitter:card" value="summary">
    <meta name="twitter:title" content="<%= h page_title %>">
    <meta name="twitter:description" content="<%= meta_description_tag(@page) %>">

    <meta property="og:type" content="<%= @page ? 'article' : 'website' %>">
    <meta property="og:url" content="<%= @page ? url_for(@page.url) : @environment.top_url %>">
    <meta property="og:title" content="<%= h page_title %>">
    <meta property="og:site_name" content="<%= profile ? profile.name : @environment.name %>">
    <meta property="og:description" content="<%= @page ? truncate(strip_tags(@page.body.to_s), :length => 200) : @environment.name %>">

    <% if @page %>
      <meta property="article:published_time" content="<%= show_date(@page.published_at) %>">
      <% @page.body_images_paths.each do |img| %>
        <meta name="twitter:image" content="<%= img.to_s %>">
        <meta property="og:image" content="<%= img.to_s %>">
      <% end %>
    <% end %>

    <link rel="shortcut icon" href="<%= image_path(theme_favicon) %>" type="image/x-icon" />
    <%= noosfero_javascript %>
    <%= noosfero_stylesheets %>
    <%= stylesheet_link_tag '/tema/style.css?layout=false' %>

    <%# Add custom tags/styles/etc via content_for %>
    <%= yield :head %>
    <%=
      @plugins.dispatch(:head_ending).map do |content|
        if content.respond_to?(:call) then instance_eval(&content).html_safe else content.html_safe end
      end.join("\n")
    %>

  <body class="<%= h body_classes %>">
    <%= _("Go to the content") %>

    <%=
      @plugins.dispatch(:body_beginning).map do |content|
        if content.respond_to?(:call) then instance_eval(&content).html_safe else content.html_safe end
      end.join("\n")
    %>

        <%= theme_header %>

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

          <%= theme_site_title %>

            <%= theme_extra_navigation %>

            <%= insert_boxes(yield) %>

    <%= render_environment_features(:logged_in) %>

      <%= theme_footer %>

    <%= noosfero_layout_features %>
    <%= theme_javascript_ng %>
    <%= addthis_javascript %>


one more credit

one more credit

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

<title><%= AppConfig.param("app_name") %> | <%= @page_title %></title>
 <%= stylesheet_link_tag 'basic' %>

<%= render(:partial => "layout_helpers/resolve_head_content" ) %>

<%= render(:partial => "layout_helpers/resolve_body_open" ) %>

  <%= image_tag('/local/header.gif', :style=>"float: left;")
  %>

URL:
        <% url = permalink_url(request, @user_request) %>
        <%= link_to url, url %>

    <%= @content_for_layout %>

  FindIt service provided by <%= link_to 'Johns Hopkins Libraries', 'http://webapps.jhu.edu/jhuniverse/libraries/' %> | Powered by <%= link_to 'Umlaut', 'http://umlaut.rubyforge.org/' %>, using services from <%= link_to 'SFX', 'http://www.exlibrisgroup.com/sfx.htm' %>, <%= link_to 'CrossRef', 'http://www.crossref.org' %>, <%= link_to 'Amazon', 'http://www.amazon.com' %>, <%= link_to 'OCLC Worldcat', 'http://www.worldcat.org' %>, <%= link_to 'ISBNdb', 'http://isbndb.com' %>, <%= link_to 'LibraryThing', 'http://www.librarything.com' %>, <%= link_to 'Google Books', 'http://books.google.com' %>, <%= link_to 'HathiTrust', 'http://www.lib.umich.edu/mdp/' %>, <%= link_to 'OpenLibrary', 'http://openlibrary.org/' %>, <%= link_to 'the Internet Archive', 'http://archive.org' %>, <%= link_to 'Worldcat Identities', 'http://orlabs.oclc.org/Identities/' %> and others.
  <% if AppConfig.param('main_sfx_base_url') && @user_request %>
    <%=
    url = AppConfig.param('main_sfx_base_url');
    url += '?'
    url += @user_request.to_context_object.kev
    url += "&sfx.ignore_date_threshold=1" if title_level_request?

    link_to('[S]', url, :target=>'_blank') %>
  <% end %>

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

<title><%= AppConfig.param("app_name") %> | <%= @page_title %></title>
 <%= stylesheet_link_tag 'basic' %>

<%= render(:partial => "layout_helpers/resolve_head_content" ) %>

<%= render(:partial => "layout_helpers/resolve_body_open" ) %>

  <%= image_tag('/local/header.gif', :style=>"float: left;")
  %>

URL:
        <% url = permalink_url(request, @user_request) %>
        <%= link_to url, url %>

    <%= @content_for_layout %>

  FindIt service provided by <%= link_to 'Johns Hopkins Libraries', 'http://webapps.jhu.edu/jhuniverse/libraries/' %> | Powered by <%= link_to 'Umlaut', 'http://umlaut.rubyforge.org/' %>, using services from <%= link_to 'SFX', 'http://www.exlibrisgroup.com/sfx.htm' %>, <%= link_to 'CrossRef', 'http://www.crossref.org' %>, <%= link_to 'Amazon', 'http://www.amazon.com' %>, <%= link_to 'OCLC Worldcat', 'http://www.worldcat.org' %>, <%= link_to 'ISBNdb', 'http://isbndb.com' %>, <%= link_to 'LibraryThing', 'http://www.librarything.com' %>, <%= link_to 'Google Books', 'http://books.google.com' %>, <%= link_to 'HathiTrust', 'http://www.lib.umich.edu/mdp/' %>, <%= link_to 'OpenLibrary', 'http://openlibrary.org/' %>, <%= link_to 'the Internet Archive', 'http://archive.org' %>  and others.
  <% if AppConfig.param('main_sfx_base_url') && @user_request %>
    <%=
    url = AppConfig.param('main_sfx_base_url');
    url += '?'
    url += @user_request.to_context_object.kev
    url += "&sfx.ignore_date_threshold=1" if title_level_request?

    link_to('[S]', url, :target=>'_blank') %>
  <% end %>


handle nil refs when grabbing the questionnaires

<% @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)
         }.uniq.compact.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.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 %>


extra space bad

extra space bad

<% @title = _("{{title}} - a Freedom of Information request to {{public_body}}",
                :title => h(@info_request.title),
                :public_body => (@info_request.public_body.name)) %>

<% if @info_request.prominence == 'hidden' %>

    <%= _('This request has prominence \'hidden\'. You can only see it because you are logged
    in as a super user.') %>

<% end %>
<% if @info_request.prominence == 'requester_only' %>

    <%= _('This request is hidden, so that only you the requester can see it. Please
    contact us if you are not sure why.', :url => help_requesting_path.html_safe) %>

<% end %>

<% if ( @update_status || @info_request.awaiting_description ) && ! @info_request.is_external? %>

    <%= render :partial => 'describe_state', :locals => { :id_suffix => "1" } %>

<% end %>

<%=h(@info_request.title)%>

    <% if !@info_request.is_external? && @info_request.user.profile_photo %>

            <img src="<%= get_profile_photo_url(:url_name => @info_request.user.url_name) %>" alt="">

    <% end %>

        <% if !@user.nil? && @user.admin_page_links? %>
            <%= _('{{user}} ({{user_admin_link}}) made this {{law_used_full}} request (admin) to {{public_body_link}} (admin)',
                    :user => @info_request.is_external? ? (@info_request.user_name || _('An anonymous user')) : user_link(@info_request.user),
                    :law_used_full => h(@info_request.law_used_full),
                    :user_admin_link => user_admin_link_for_request(@info_request, _('external'), _('admin')),
                    :request_admin_url => admin_request_show_url(@info_request),
                    :public_body_link => public_body_link(@info_request.public_body),
                    :public_body_admin_url => admin_body_show_url(@info_request.public_body)) %>
        <% else %>
            <%= _('{{user}} made this {{law_used_full}} request',:user=>@info_request.is_external? ? (@info_request.user_name || _('An anonymous user')) : user_link(@info_request.user), :law_used_full=>h(@info_request.law_used_full)) %>
            <%= _('to {{public_body}}',:public_body=>public_body_link(@info_request.public_body)) %>
        <% end %>

    <p id="request_status" class="request_icon_line icon_<%= @info_request.calculate_status %>">
    <% if @info_request.awaiting_description %>
        <% if @is_owning_user && !@info_request.is_external? %>
            <%= _('Please answer the question above so we know whether the ')%>
            <%= MySociety::Format.fancy_pluralize(@new_responses_count, 'recent response contains', 'recent responses contain') %> <%= _('useful information.') %>
        <% else %>
            <%= _('This request has an unknown status.') %>
            <% if @old_unclassified %>
              <%= _('We\'re waiting for someone to read') %>
              <%= MySociety::Format.fancy_pluralize(@new_responses_count, 'a recent response', 'recent responses') %>
              <%= _('and update the status accordingly. Perhaps you might like to help out by doing that?') %>
            <% else %>
            <%=  _('We\'re waiting for') %>
              <%= user_link_for_request(@info_request) %> <%= _('to read') %>
              <%= MySociety::Format.fancy_pluralize(@new_responses_count, 'a recent response', 'recent responses') %>
              <%= _('and update the status.') %>
            <% end %>
        <% end %>
    <% elsif @status == 'waiting_response' %>
        <%= _('Currently waiting for a response from {{public_body_link}}, they must respond promptly and', :public_body_link=> public_body_link(@info_request.public_body)) %>
        <% if @info_request.public_body.is_school? %>
        <%= _('in term time') %>
        <% else %>
        <%= _('normally') %>
        <% end %>
        <%= _('no later than') %> <%= simple_date(@info_request.date_response_required_by) %>
        (<%= link_to _("details"), "/help/requesting#quickly_response" %>).
    <% elsif @status == 'waiting_response_overdue' %>
        <%= _('Response to this request is delayed.') %>
        <%= _('By law, {{public_body_link}} should normally have responded promptly and',:public_body_link=>public_body_link(@info_request.public_body)) %>
            <% if @info_request.public_body.is_school? %>
            <%= _('in term time') %>
            <% end %>
            <%= _('by') %> <%= simple_date(@info_request.date_response_required_by) %>
        (<%= link_to _('details'), help_requesting_path + '#quickly_response' %>)
    <% elsif @status == 'waiting_response_very_overdue' %>
        <%= _('Response to this request is long overdue.') %>
        <%= _('By law, under all circumstances, {{public_body_link}} should have responded by now',:public_body_link => public_body_link(@info_request.public_body)) %>
        (<%= link_to _('details'), help_requesting_path + '#quickly_response' %>).
        <% if !@info_request.is_external? %>
            You can <%= link_to "complain to the Ombudsman", "http://www.ombudsman.parliament.nz/make-a-complaint/complaining-about-access-to-official-information-551307291224432" %>.

        <% end %>
    <% elsif @status == 'not_held' %>
        <%= public_body_link(@info_request.public_body) %> <%= _('did not have the information requested.') %>
    <% elsif @status == 'rejected' %>
        <%= _('The request was refused by') %> <%= public_body_link(@info_request.public_body) %>.
    <% elsif @status == 'successful' %>
        <%= _('The request was successful.') %>
    <% elsif @status == 'partially_successful' %>
        <%= _('The request was partially successful.') %>
    <% elsif @status == 'waiting_clarification' %>
        <% if @is_owning_user && !@info_request.is_external? %>
            <%=h @info_request.public_body.name %> <%= _('is waiting for your clarification.') %>
            <%= _('Please') %>
              <%= link_to _("send a follow up message"), respond_to_last_path(@info_request) + '#followup' %>.
        <% else %>
            <%= _('The request is waiting for clarification.') %>
            <% if !@info_request.is_external? %>
              <%= _('If you are {{user_link}}, please',:user_link=>user_link_for_request(@info_request)) %>
              <%= link_to _("sign in"), signin_path(:r => request.request_uri) %> <%= _('to send a follow up message.') %>
            <% end %>
        <% end %>
    <% elsif @status == 'gone_postal' %>
        <%= _('The authority would like to / has responded by post to this request.') %>
    <% elsif @status == 'internal_review' %>
        <%= _('Waiting for an internal review by {{public_body_link}} of their handling of this request.',:public_body_link=>public_body_link(@info_request.public_body)) %>
    <% elsif @status == 'error_message' %>
        <%= _('There was a delivery error or similar, which needs fixing by the {{site_name}} team.', :site_name=>site_name) %>
    <% elsif @status == 'requires_admin' %>
        <%= _('This request has had an unusual response, and requires attention from the {{site_name}} team.', :site_name=>site_name) %>
    <% elsif @status == 'user_withdrawn' %>
        <%= _('This request has been withdrawn by the person who made it.
               There may be an explanation in the correspondence below.') %>
    <% elsif @status == 'attention_requested' %>
        <%= _('This request has been reported as needing administrator attention (perhaps because it is vexatious, or a request for personal information)') %>
    <% elsif @status == 'vexatious' %>
        <%= _('This request has been hidden from the site, because an administrator considers it vexatious') %>
    <% elsif @status == 'not_foi' %>
        <%= _('This request has been hidden from the site, because an administrator considers it not to be an FOI request') %>
    <% else %>
        <%= render :partial => 'general/custom_state_descriptions', :locals => { :status => @status } %>
    <% end %>

    <% for info_request_event in @info_request_events %>
        <% if info_request_event.visible %>
            <%= render :partial => 'correspondence', :locals => { :info_request_event => info_request_event } %>
        <% end %>
    <% end %>

    <% if @info_request.awaiting_description && ! @info_request.is_external? %>

        <%= render :partial => 'describe_state', :locals => { :id_suffix => "2" } %>

    <% end %>

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

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

<% @title = _("{{title}} - a Freedom of Information request to {{public_body}}",
                :title => h(@info_request.title),
                :public_body => (@info_request.public_body.name)) %>

<% if @info_request.prominence == 'hidden' %>

    <%= _('This request has prominence \'hidden\'. You can only see it because you are logged
    in as a super user.') %>

<% end %>
<% if @info_request.prominence == 'requester_only' %>

    <%= _('This request is hidden, so that only you the requester can see it. Please
    contact us if you are not sure why.', :url => help_requesting_path.html_safe) %>

<% end %>

<% if ( @update_status || @info_request.awaiting_description ) && ! @info_request.is_external? %>

    <%= render :partial => 'describe_state', :locals => { :id_suffix => "1" } %>

<% end %>

<%=h(@info_request.title)%>

    <% if !@info_request.is_external? && @info_request.user.profile_photo %>

            <img src="<%= get_profile_photo_url(:url_name => @info_request.user.url_name) %>" alt="">

    <% end %>

        <% if !@user.nil? && @user.admin_page_links? %>
            <%= _('{{user}} ({{user_admin_link}}) made this {{law_used_full}} request (admin) to {{public_body_link}} (admin)',
                    :user => @info_request.is_external? ? (@info_request.user_name || _('An anonymous user')) : user_link(@info_request.user),
                    :law_used_full => h(@info_request.law_used_full),
                    :user_admin_link => user_admin_link_for_request(@info_request, _('external'), _('admin')),
                    :request_admin_url => admin_request_show_url(@info_request),
                    :public_body_link => public_body_link(@info_request.public_body),
                    :public_body_admin_url => admin_body_show_url(@info_request.public_body)) %>
        <% else %>
            <%= _('{{user}} made this {{law_used_full}} request',:user=>@info_request.is_external? ? (@info_request.user_name || _('An anonymous user')) : user_link(@info_request.user), :law_used_full=>h(@info_request.law_used_full)) %>
            <%= _('to {{public_body}}',:public_body=>public_body_link(@info_request.public_body)) %>
        <% end %>

    <p id="request_status" class="request_icon_line icon_<%= @info_request.calculate_status %>">
    <% if @info_request.awaiting_description %>
        <% if @is_owning_user && !@info_request.is_external? %>
            <%= _('Please answer the question above so we know whether the ')%>
            <%= MySociety::Format.fancy_pluralize(@new_responses_count, 'recent response contains', 'recent responses contain') %> <%= _('useful information.') %>
        <% else %>
            <%= _('This request has an unknown status.') %>
            <% if @old_unclassified %>
              <%= _('We\'re waiting for someone to read') %>
              <%= MySociety::Format.fancy_pluralize(@new_responses_count, 'a recent response', 'recent responses') %>
              <%= _('and update the status accordingly. Perhaps you might like to help out by doing that?') %>
            <% else %>
            <%=  _('We\'re waiting for') %>
              <%= user_link_for_request(@info_request) %> <%= _('to read') %>
              <%= MySociety::Format.fancy_pluralize(@new_responses_count, 'a recent response', 'recent responses') %>
              <%= _('and update the status.') %>
            <% end %>
        <% end %>
    <% elsif @status == 'waiting_response' %>
        <%= _('Currently waiting for a response from {{public_body_link}}, they must respond promptly and', :public_body_link=> public_body_link(@info_request.public_body)) %>
        <% if @info_request.public_body.is_school? %>
        <%= _('in term time') %>
        <% else %>
        <%= _('normally') %>
        <% end %>
        <%= _('no later than') %> <%= simple_date(@info_request.date_response_required_by) %>
        (<%= link_to _("details"), "/help/requesting#quickly_response" %>).
    <% elsif @status == 'waiting_response_overdue' %>
        <%= _('Response to this request is delayed.') %>
        <%= _('By law, {{public_body_link}} should normally have responded promptly and',:public_body_link=>public_body_link(@info_request.public_body)) %>
            <% if @info_request.public_body.is_school? %>
            <%= _('in term time') %>
            <% end %>
            <%= _('by') %> <%= simple_date(@info_request.date_response_required_by) %>
        (<%= link_to _('details'), help_requesting_path + '#quickly_response' %>)
    <% elsif @status == 'waiting_response_very_overdue' %>
        <%= _('Response to this request is long overdue.') %>
        <%= _('By law, under all circumstances, {{public_body_link}} should have responded by now',:public_body_link => public_body_link(@info_request.public_body)) %>
        (<%= link_to _('details'), help_requesting_path + '#quickly_response' %>).
        <% if !@info_request.is_external? %>
            You can <%= link_to "complain to the Ombudsman", "http://www.ombudsman.parliament.nz/make-a-complaint/complaining-about-access-to-official-information-551307291224432" %> .

        <% end %>
    <% elsif @status == 'not_held' %>
        <%= public_body_link(@info_request.public_body) %> <%= _('did not have the information requested.') %>
    <% elsif @status == 'rejected' %>
        <%= _('The request was refused by') %> <%= public_body_link(@info_request.public_body) %>.
    <% elsif @status == 'successful' %>
        <%= _('The request was successful.') %>
    <% elsif @status == 'partially_successful' %>
        <%= _('The request was partially successful.') %>
    <% elsif @status == 'waiting_clarification' %>
        <% if @is_owning_user && !@info_request.is_external? %>
            <%=h @info_request.public_body.name %> <%= _('is waiting for your clarification.') %>
            <%= _('Please') %>
              <%= link_to _("send a follow up message"), respond_to_last_path(@info_request) + '#followup' %>.
        <% else %>
            <%= _('The request is waiting for clarification.') %>
            <% if !@info_request.is_external? %>
              <%= _('If you are {{user_link}}, please',:user_link=>user_link_for_request(@info_request)) %>
              <%= link_to _("sign in"), signin_path(:r => request.request_uri) %> <%= _('to send a follow up message.') %>
            <% end %>
        <% end %>
    <% elsif @status == 'gone_postal' %>
        <%= _('The authority would like to / has responded by post to this request.') %>
    <% elsif @status == 'internal_review' %>
        <%= _('Waiting for an internal review by {{public_body_link}} of their handling of this request.',:public_body_link=>public_body_link(@info_request.public_body)) %>
    <% elsif @status == 'error_message' %>
        <%= _('There was a delivery error or similar, which needs fixing by the {{site_name}} team.', :site_name=>site_name) %>
    <% elsif @status == 'requires_admin' %>
        <%= _('This request has had an unusual response, and requires attention from the {{site_name}} team.', :site_name=>site_name) %>
    <% elsif @status == 'user_withdrawn' %>
        <%= _('This request has been withdrawn by the person who made it.
               There may be an explanation in the correspondence below.') %>
    <% elsif @status == 'attention_requested' %>
        <%= _('This request has been reported as needing administrator attention (perhaps because it is vexatious, or a request for personal information)') %>
    <% elsif @status == 'vexatious' %>
        <%= _('This request has been hidden from the site, because an administrator considers it vexatious') %>
    <% elsif @status == 'not_foi' %>
        <%= _('This request has been hidden from the site, because an administrator considers it not to be an FOI request') %>
    <% else %>
        <%= render :partial => 'general/custom_state_descriptions', :locals => { :status => @status } %>
    <% end %>

    <% for info_request_event in @info_request_events %>
        <% if info_request_event.visible %>
            <%= render :partial => 'correspondence', :locals => { :info_request_event => info_request_event } %>
        <% end %>
    <% end %>

    <% if @info_request.awaiting_description && ! @info_request.is_external? %>

        <%= render :partial => 'describe_state', :locals => { :id_suffix => "2" } %>

    <% end %>

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

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