added a bit of javascript to set the default settings in the sharing form for new items

<% set_parameters_for_sharing_form %>
<%# initialization: required to keep javascript independent of the access type codes, to allow the use the constants instead -%>
<%= render :partial=>"assets/sharing_constants" %>

<%# this hidden input will submit all permission data with the form -%>
<%= hidden_field_tag "sharing[permissions][contributor_types]", "" -%>
<%= hidden_field_tag "sharing[permissions][values]", "" -%>

    <%= help_icon("Here you can specify who can see#{', download' if @resource.is_downloadable?} and edit this #{@resource_type}.") -%>
    Sharing

        Here you can specify who can view the summary of<% if @resource.is_downloadable? %>, get access to the content of,<% end %> and edit the <%= @resource_type -%>.
        <%= link_to_function "More info " + expand_image, visual_effect(:toggle_blind, "more_sharing_info", :duration => 0.3) -%>

          You may:

Keep the <%= @resource_type -%> private, and only visible to yourself.

Share within the selected projects and with all other users that are a member of a <%= Seek::Config.project_name %> project.

          <% if try_block{@resource.can_publish?} %>

Share with the all visitors (including anonymous visitors with no login)

          <% end %>

Define more fine-grained sharing in the Advanced sharing: you can share within your Project/Institution only,
 with specific individuals, or set up custom favourite groups for people you regularly need to share with.

<label for="sharing_scope_<%= Policy::PRIVATE -%>">
            <input type="hidden" id='access_type_select_<%= Policy::PRIVATE -%>' name="sharing[access_type_<%= Policy::PRIVATE -%>]" value="<%= Policy::NO_ACCESS -%>">
        <input <%= 'checked="checked"' if @sharing_mode == Policy::PRIVATE %> id="sharing_scope_<%= Policy::PRIVATE -%>" name="sharing[sharing_scope]"
                                                                                value="<%= Policy::PRIVATE -%>" type="radio" />
            - Keep this <%= @resource_type -%> private (only visible to you)

Or share it with..

            <input type="radio" <%= 'checked="checked"' if @sharing_mode == Policy::ALL_SYSMO_USERS -%> id="sharing_scope_<%= Policy::ALL_SYSMO_USERS -%>" name="sharing[sharing_scope]" value="<%= Policy::ALL_SYSMO_USERS -%>" />
            - Your project(s):

             <select name="sharing[your_proj_access_type]" id="sharing_your_proj_access_type">
                 <%= policy_selection_options([Policy::VISIBLE,Policy::ACCESSIBLE,Policy::EDITING,Policy::MANAGING], @resource, your_project_access_type(@policy, @resource)) -%>
             </select>
             and other registered users.
             <%= render :partial => "assets/sharing_form_access_type_dropdown", :locals => { :access_type_selector_for_scope => Policy::ALL_SYSMO_USERS,
               :sharing_scope => Policy::ALL_SYSMO_USERS, :access_type => @access_mode, :access_type_options=>[Policy::NO_ACCESS,Policy::VISIBLE,Policy::ACCESSIBLE,Policy::EDITING] } -%>

          <label for="sharing_scope_<%= Policy::EVERYONE -%>">
            <input type="radio" <%= 'checked="checked"' if @sharing_mode == Policy::EVERYONE -%> id="sharing_scope_<%= Policy::EVERYONE -%>" name="sharing[sharing_scope]"
                   value="<%= Policy::EVERYONE -%>" <%= 'disabled="true"' if @resource.respond_to?(:can_publish?) && !@resource.can_publish? -%>/>
            - All visitors (including anonymous visitors with no login):

              <%= render :partial => "assets/sharing_form_access_type_dropdown", :locals => { :access_type_selector_for_scope => Policy::EVERYONE,
            :sharing_scope => @sharing_mode, :access_type => @access_mode } -%>

    <% if @resource.new_record? && @resource.errors.empty? -%>

    <% end -%>

    <%= link_to_function "Advanced permissions " + expand_image, :class => 'advanced_sharing_link', :style => "display:" + (@policy.permissions.empty? ? 'block;' : 'none;'), :id =>'advanced_sharing_expand_image' do |page|
        page.visual_effect :toggle_blind, "advanced sharing", :duration => 0.5
        page["advanced_sharing_expand_image"].toggle
        page["advanced_sharing_collapse_image"].toggle
        end
    -%>
    <%= link_to_function "Advanced permissions " + collapse_image, :class => 'advanced_sharing_link', :style => "display:" + (@policy.permissions.empty? ? 'none;' : 'block;'), :id =>'advanced_sharing_collapse_image'do |page|
        page.visual_effect :toggle_blind, "advanced sharing", :duration => 0.5
        page["advanced_sharing_expand_image"].toggle
        page["advanced_sharing_collapse_image"].toggle
        end
    -%>

    <div id="advanced sharing" class='sharing_box_form' style="display:<%= @policy.permissions.empty? ? 'none;' : 'block;'-%>">

Define more fine-grained sharing

              So far you have selected to share this <%= @resource_type -%> with:

              Loading...

              Build up the list of people and groups to share with.
              Select from the options below and click "Add" to apply
              your choices and add collaborators to your current selection:

                <%= image_tag icon_filename_for_key("spinner"), :id => "f_group_deleting_spinner", :alt=>"loading...", :title=>"loading...", :style => "display: none; vertical-align: middle; float: right;" -%>
                <%= help_icon("Here you can choose your favourite groups to share this #{@resource_type} with.") -%>
                Favourite Groups

                  <% favourite_groups = FavouriteGroup.get_all_without_blacklists_and_whitelists(current_user.id) -%>
                  <% f_group_select_options = (favourite_groups.blank? ? "<option value=\"\">You don't have any favourite groups</option>" : options_for_select(favourite_groups)) -%>

                  <%= select_tag "favourite_group_select", f_group_select_options, :style => "width: 82%; vertical-align: middle; margin-right: 0.4em;", :disabled => (favourite_groups.blank?) -%>

                  <%= link_to "Add", "", :id => "add_f_group_link", :style => "font-weight: bold; vertical-align: middle;", :disabled => (favourite_groups.blank?),
                    :onclick => "javascript: if($('favourite_group_select').disabled) return(false); addContributor('FavouriteGroup', $('favourite_group_select').options[$('favourite_group_select').selectedIndex].text, parseInt($('favourite_group_select').options[$('favourite_group_select').selectedIndex].value), #{Policy::DETERMINED_BY_GROUP}); return(false);" -%>

                  <li id="edit_f_group_li" style="display: <%= favourite_groups.blank? ? "none" : "block" -%>; list-style-type: disc; padding: 0;"><%= favourite_group_popup_link_action_edit(@resource.class.name) -%>

                  <li id="delete_f_group_li" style="display: <%= favourite_groups.blank? ? "none" : "block" -%>; list-style-type: disc; padding: 0;">
                    <%= link_to "Delete selected favourite group", delete_favourite_group_path(0), :onclick => "deleteSelectedFavouriteGroup(); return(false);" -%>

<%= favourite_group_popup_link_action_new(@resource.class.name) -%>

                <%= help_icon("Here you can choose projects, institutions and workgroups to share this #{@resource_type} with.") -%>
                Projects and Institutions

                  <% right_arrow_image = icon_filename_for_key("arrow_right") -%>

                  Step 1
                  <%= image_tag right_arrow_image, :style => "vertical-align: middle; padding: 0 0.8em;" -%>

                  Step 2
                  <%= image_tag right_arrow_image, :style => "vertical-align: middle; padding: 0 0.8em;" -%>

                  Step 3

                    <input type="hidden" id="proj_select_step_index" value="1">

                      <%= image_tag icon_filename_for_key("spinner"), :id => "institutions_loading_spinner", :alt=>"loading...", :title=>"loading...", :style => "display: none; vertical-align: middle; float: right;" -%>
                      Step 1: Select a project
                      <%= select("proj_project", "select",
                        Project.find(:all).collect {|p| [ p.name, p.id ] },
                        {:include_blank => 'All Projects @ Institution (from Step 2)'}, {:style => "width: 100%; vertical-align: middle; margin: 0.3em 0;"}) -%>

                      Step 2: Select scope of the project
                      <%= select_tag("proj_institution_select", nil, {:style => "width: 100%; vertical-align: middle; margin: 0.3em 0;"}) -%>

                      Step 3: Choose access rights, review and submit

                      <select name="proj_access_type_select" id="proj_access_type_select" onchange="javascript: replaceReviewWorkGroupURL();" style="width: 100%; vertical-align: middle; margin: 0.3em 0;">
                        <%= policy_selection_options [Policy::NO_ACCESS,Policy::VISIBLE,Policy::ACCESSIBLE,Policy::EDITING,Policy::MANAGING], @resource -%>
                      </select>

                        <%= link_to "< Previous step", "", :onclick => "javascript: projectInstitutionStepAction(-1); return(false);", :style => "font-weight: bold;" -%>

                        <%= link_to "Next step >", "", :onclick => "javascript: projectInstitutionStepAction(1); return(false);", :style => "font-weight: bold;" -%>

                            <%= link_to "Add immediately", "", :onclick => "javascript: addProjectInstitution(); return(false);", :style => "font-weight: bold; padding: 0;" -%>

<%= workgroup_member_review_popup_link(@resource.class.name) -%>

                <%= help_icon("Here you can specify individual people to share this #{@resource_type} with.") -%>
                Individual People

                    Please type names of people to share this <%= @resource_type -%> with into the box below - suggestions will be displayed as you type.
                    Select access rights from drop-down menu; these will be applied to all chosen people.
                    Clicking "Add" will add selected people to the list.

                          ^_^<input type="text" id="ip_hidden_input" tabindex="-1" >

                            <input type="text" size="1" tabindex="" id="ip_autocomplete_input" />

Type the name of a friend, friend list, or email address

                        <select name="individual_people_access_type_select" id="individual_people_access_type_select" style="width: 344px; vertical-align: middle; margin-top: 0.3em;">
                          <%= policy_selection_options nil, @resource -%>
                        </select>

                        <%= link_to "Add", "", :onclick => "javascript: addIndividualPeople(); return(false);" -%>

<% set_parameters_for_sharing_form %>
<%# initialization: required to keep javascript independent of the access type codes, to allow the use the constants instead -%>
<%= render :partial=>"assets/sharing_constants" %>

<%# this hidden input will submit all permission data with the form -%>
<%= hidden_field_tag "sharing[permissions][contributor_types]", "" -%>
<%= hidden_field_tag "sharing[permissions][values]", "" -%>

    <%= help_icon("Here you can specify who can see#{', download' if @resource.is_downloadable?} and edit this #{@resource_type}.") -%>
    Sharing

        Here you can specify who can view the summary of<% if @resource.is_downloadable? %>, get access to the content of,<% end %> and edit the <%= @resource_type -%>.
        <%= link_to_function "More info " + expand_image, visual_effect(:toggle_blind, "more_sharing_info", :duration => 0.3) -%>

          You may:

Keep the <%= @resource_type -%> private, and only visible to yourself.

Share within the selected projects and with all other users that are a member of a <%= Seek::Config.project_name %> project.

          <% if try_block{@resource.can_publish?} %>

Share with the all visitors (including anonymous visitors with no login)

          <% end %>

Define more fine-grained sharing in the Advanced sharing: you can share within your Project/Institution only,
 with specific individuals, or set up custom favourite groups for people you regularly need to share with.

<label for="sharing_scope_<%= Policy::PRIVATE -%>">
            <input type="hidden" id='access_type_select_<%= Policy::PRIVATE -%>' name="sharing[access_type_<%= Policy::PRIVATE -%>]" value="<%= Policy::NO_ACCESS -%>">
        <input <%= 'checked="checked"' if @sharing_mode == Policy::PRIVATE %> id="sharing_scope_<%= Policy::PRIVATE -%>" name="sharing[sharing_scope]"
                                                                                value="<%= Policy::PRIVATE -%>" type="radio" />
            - Keep this <%= @resource_type -%> private (only visible to you)

Or share it with..

            <input type="radio" <%= 'checked="checked"' if @sharing_mode == Policy::ALL_SYSMO_USERS -%> id="sharing_scope_<%= Policy::ALL_SYSMO_USERS -%>" name="sharing[sharing_scope]" value="<%= Policy::ALL_SYSMO_USERS -%>" />
            - Selected projects:

             <select name="sharing[your_proj_access_type]" id="sharing_your_proj_access_type">
                 <%= policy_selection_options([Policy::VISIBLE,Policy::ACCESSIBLE,Policy::EDITING,Policy::MANAGING], @resource, your_project_access_type(@policy, @resource)) -%>
             </select>
             and all <%= Seek::Config.project_name %> users:
             <%= render :partial => "assets/sharing_form_access_type_dropdown", :locals => { :access_type_selector_for_scope => Policy::ALL_SYSMO_USERS,
               :sharing_scope => Policy::ALL_SYSMO_USERS, :access_type => @access_mode, :access_type_options=>[Policy::NO_ACCESS,Policy::VISIBLE,Policy::ACCESSIBLE,Policy::EDITING] } -%>

          <label for="sharing_scope_<%= Policy::EVERYONE -%>">
            <input type="radio" <%= 'checked="checked"' if @sharing_mode == Policy::EVERYONE -%> id="sharing_scope_<%= Policy::EVERYONE -%>" name="sharing[sharing_scope]"
                   value="<%= Policy::EVERYONE -%>" <%= 'disabled="true"' if @resource.respond_to?(:can_publish?) && !@resource.can_publish? -%>/>
            - All visitors (including anonymous visitors with no login):

              <%= render :partial => "assets/sharing_form_access_type_dropdown", :locals => { :access_type_selector_for_scope => Policy::EVERYONE,
            :sharing_scope => @sharing_mode, :access_type => @access_mode } -%>

    <%= link_to_function "Advanced sharing " + expand_image, :class => 'advanced_sharing_link', :style => "display:" + (@policy.permissions.empty? ? 'block;' : 'none;'), :id =>'advanced_sharing_expand_image' do |page|
        page.visual_effect :toggle_blind, "advanced sharing", :duration => 0.5
        page["advanced_sharing_expand_image"].toggle
        page["advanced_sharing_collapse_image"].toggle
        end
    -%>
    <%= link_to_function "Advanced sharing " + collapse_image, :class => 'advanced_sharing_link', :style => "display:" + (@policy.permissions.empty? ? 'none;' : 'block;'), :id =>'advanced_sharing_collapse_image'do |page|
        page.visual_effect :toggle_blind, "advanced sharing", :duration => 0.5
        page["advanced_sharing_expand_image"].toggle
        page["advanced_sharing_collapse_image"].toggle
        end
    -%>

    <div id="advanced sharing" class='sharing_box_form' style="display:<%= @policy.permissions.empty? ? 'none;' : 'block;'-%>">

Define more fine-grained sharing

              So far you have selected to share this <%= @resource_type -%> with:

              Loading...

              Build up the list of people and groups to share with.
              Select from the options below and click "Add" to apply
              your choices and add collaborators to your current selection:

                <%= image_tag icon_filename_for_key("spinner"), :id => "f_group_deleting_spinner", :alt=>"loading...", :title=>"loading...", :style => "display: none; vertical-align: middle; float: right;" -%>
                <%= help_icon("Here you can choose your favourite groups to share this #{@resource_type} with.") -%>
                Favourite Groups

                  <% favourite_groups = FavouriteGroup.get_all_without_blacklists_and_whitelists(current_user.id) -%>
                  <% f_group_select_options = (favourite_groups.blank? ? "<option value=\"\">You don't have any favourite groups</option>" : options_for_select(favourite_groups)) -%>

                  <%= select_tag "favourite_group_select", f_group_select_options, :style => "width: 82%; vertical-align: middle; margin-right: 0.4em;", :disabled => (favourite_groups.blank?) -%>

                  <%= link_to "Add", "", :id => "add_f_group_link", :style => "font-weight: bold; vertical-align: middle;", :disabled => (favourite_groups.blank?),
                    :onclick => "javascript: if($('favourite_group_select').disabled) return(false); addContributor('FavouriteGroup', $('favourite_group_select').options[$('favourite_group_select').selectedIndex].text, parseInt($('favourite_group_select').options[$('favourite_group_select').selectedIndex].value), #{Policy::DETERMINED_BY_GROUP}); return(false);" -%>

                  <li id="edit_f_group_li" style="display: <%= favourite_groups.blank? ? "none" : "block" -%>; list-style-type: disc; padding: 0;"><%= favourite_group_popup_link_action_edit(@resource.class.name) -%>

                  <li id="delete_f_group_li" style="display: <%= favourite_groups.blank? ? "none" : "block" -%>; list-style-type: disc; padding: 0;">
                    <%= link_to "Delete selected favourite group", delete_favourite_group_path(0), :onclick => "deleteSelectedFavouriteGroup(); return(false);" -%>

<%= favourite_group_popup_link_action_new(@resource.class.name) -%>

                <%= help_icon("Here you can choose projects, institutions and workgroups to share this #{@resource_type} with.") -%>
                Projects and Institutions

                  <% right_arrow_image = icon_filename_for_key("arrow_right") -%>

                  Step 1
                  <%= image_tag right_arrow_image, :style => "vertical-align: middle; padding: 0 0.8em;" -%>

                  Step 2
                  <%= image_tag right_arrow_image, :style => "vertical-align: middle; padding: 0 0.8em;" -%>

                  Step 3

                    <input type="hidden" id="proj_select_step_index" value="1">

                      <%= image_tag icon_filename_for_key("spinner"), :id => "institutions_loading_spinner", :alt=>"loading...", :title=>"loading...", :style => "display: none; vertical-align: middle; float: right;" -%>
                      Step 1: Select a project
                      <%= select("proj_project", "select",
                        Project.find(:all).collect {|p| [ p.name, p.id ] },
                        {:include_blank => 'All Projects @ Institution (from Step 2)'}, {:style => "width: 100%; vertical-align: middle; margin: 0.3em 0;"}) -%>

                      Step 2: Select scope of the project
                      <%= select_tag("proj_institution_select", nil, {:style => "width: 100%; vertical-align: middle; margin: 0.3em 0;"}) -%>

                      Step 3: Choose access rights, review and submit

                      <select name="proj_access_type_select" id="proj_access_type_select" onchange="javascript: replaceReviewWorkGroupURL();" style="width: 100%; vertical-align: middle; margin: 0.3em 0;">
                        <%= policy_selection_options [Policy::NO_ACCESS,Policy::VISIBLE,Policy::ACCESSIBLE,Policy::EDITING,Policy::MANAGING], @resource -%>
                      </select>

                        <%= link_to "< Previous step", "", :onclick => "javascript: projectInstitutionStepAction(-1); return(false);", :style => "font-weight: bold;" -%>

                        <%= link_to "Next step >", "", :onclick => "javascript: projectInstitutionStepAction(1); return(false);", :style => "font-weight: bold;" -%>

                            <%= link_to "Add immediately", "", :onclick => "javascript: addProjectInstitution(); return(false);", :style => "font-weight: bold; padding: 0;" -%>

<%= workgroup_member_review_popup_link(@resource.class.name) -%>

                <%= help_icon("Here you can specify individual people to share this #{@resource_type} with.") -%>
                Individual People

                    Please type names of people to share this <%= @resource_type -%> with into the box below - suggestions will be displayed as you type.
                    Select access rights from drop-down menu; these will be applied to all chosen people.
                    Clicking "Add" will add selected people to the list.

                          ^_^<input type="text" id="ip_hidden_input" tabindex="-1" >

                            <input type="text" size="1" tabindex="" id="ip_autocomplete_input" />

Type the name of a friend, friend list, or email address

                        <select name="individual_people_access_type_select" id="individual_people_access_type_select" style="width: 344px; vertical-align: middle; margin-top: 0.3em;">
                          <%= policy_selection_options nil, @resource -%>
                        </select>

                        <%= link_to "Add", "", :onclick => "javascript: addIndividualPeople(); return(false);" -%>


Changed the text strings in the bottom line of the Assign Reviewers screen to be less cryptic.

git-svn-id: f67d969b640da65cb7bc1d229e09fd6d2db44ae1@525 392d7b7b-3f31-0410-9dc3-c95a9635ea79

Contributors

Assignment <%= @assignment.name %>

<%
   column_definitions = Array.new
   column_definitions << {:name => 'Contributor', :type => 'display', :field => 'name'}
   column_definitions << {:name => 'Modify Reviewers', :action => 'list_reviewers', :controller => 'review_mapping', :hidden => {:name => 'assignment_id', :id => @assignment.id}}
   column_definitions << {:name => 'Delete Mappings', :action => 'delete_all_reviewers',  :controller => 'review_mapping', :hidden => {:name => 'assignment_id', :id => @assignment.id}}

   delete_options = {:enabled => false}
%>
<%= render :partial => 'shared_scripts/selectTable', :locals => {:column_definitions => column_definitions, :delete_options => delete_options, :elements => @items, :delete_controller => 'review_mapping'} %>

<%
  session[:return_to] = request.request_uri
%>
<%= link_to 'Assign reviewers automatically', :action => 'select_mapping', :id => @assignment.id %>
| <%= link_to 'Import reviewer mappings',
            :controller=>'import_file',
            :action=>'start',
            :model => 'ReviewMapping',
            :title => 'Reviewer Mappings',
            :expected_fields =>  "Contributor, Reviewer1, Reviewer2, ... , ReviewerN",
            :id => @assignment.id %>
| <%= link_to 'Import metareviewer mappings',
            :controller=>'import_file',
            :action=>'start',
            :model => 'ReviewOfReviewMapping',
            :title => 'Metareviewer Mappings',
            :expected_fields => 'Contributor, Reviewer, Metareviewer1, Metareviewer2, ... MetareviewerN',
            :id => @assignment.id %>
| <%= link_to 'Back', :controller => 'tree_display', :action => 'list' %>

Contributors

Assignment <%= @assignment.name %>

<%
   column_definitions = Array.new
   column_definitions << {:name => 'Contributor', :type => 'display', :field => 'name'}
   column_definitions << {:name => 'Modify Reviewers', :action => 'list_reviewers', :controller => 'review_mapping', :hidden => {:name => 'assignment_id', :id => @assignment.id}}
   column_definitions << {:name => 'Delete Mappings', :action => 'delete_all_reviewers',  :controller => 'review_mapping', :hidden => {:name => 'assignment_id', :id => @assignment.id}}

   delete_options = {:enabled => false}
%>
<%= render :partial => 'shared_scripts/selectTable', :locals => {:column_definitions => column_definitions, :delete_options => delete_options, :elements => @items, :delete_controller => 'review_mapping'} %>

<%
  session[:return_to] = request.request_uri
%>
<%= link_to 'Select Mapping Strategy', :action => 'select_mapping', :id => @assignment.id %>
| <%= link_to 'Import Reviewer Mappings',
            :controller=>'import_file',
            :action=>'start',
            :model => 'ReviewMapping',
            :title => 'Reviewer Mappings',
            :expected_fields =>  "Contributor, Reviewer1, Reviewer2, ... , ReviewerN",
            :id => @assignment.id %>
| <%= link_to 'Import Review of Reviewer Mappings',
            :controller=>'import_file',
            :action=>'start',
            :model => 'ReviewOfReviewMapping',
            :title => 'Review of Reviewer Mappings',
            :expected_fields => 'Contributor, Reviewer, ReviewOfReviewer1, ReviewOfReviewer2, ... ReviewOfReviewerN',
            :id => @assignment.id %>
| <%= link_to 'Back', :controller => 'tree_display', :action => 'list' %>


Clean up terminology.  Closes #1009

Clean up terminology.  Closes #1009

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

<%= error_messages_for 'article' %>

  Title:

  <%= text_field 'article', 'title'  %>
  (<%= link_to_function "» edit permalink", "Toggle.display('permalink')" %>)

  Permalink:

  <%= text_field 'article', 'permalink'  %>

  Body:

  <%= text_area 'article', 'body', :rows => 25, :style => 'width: 48%;'  %>

<%= markup_help_popup @article.text_filter, "Markup Help" %>

  Categories:

  <select id="categories" name="categories[]" multiple="multiple" size="10" style="width:250px;">
  <%= options_from_collection_for_select(@categories, "id", "name", @selected) %>
  </select>

  Tags:

  <%= text_field 'article', 'keywords'  %>

  Add Extended Content

  Extended:

  <%= text_area 'article', 'extended', :rows => 30, :style => 'width: 48%;'  %>

Toggle Advanced Options (+/-)

Allow comments: <%= check_box 'article', 'allow_comments'  %>

Allow trackbacks: <%= check_box 'article', 'allow_pings'  %>

Published:<%= check_box 'article', 'published'  %>

Textfilter: <%= select 'article', 'text_filter', text_filter_options %>

Publish at:<%= datetime_select 'article', 'published_at', :include_blank => true  %>

Attachments (+/-)

<%= render :partial => 'admin/content/attachment', :locals => { :attachment_num => 1 } -%>

<%= error_messages_for 'article' %>

  Title:

  <%= text_field 'article', 'title'  %>
  (<%= link_to_function "» edit permalink", "Toggle.display('permalink')" %>)

  Permalink:

  <%= text_field 'article', 'permalink'  %>

  Body:

  <%= text_area 'article', 'body', :rows => 25, :style => 'width: 48%;'  %>

<%= markup_help_popup @article.text_filter, "Markup Help" %>

  Categories:

  <select id="categories" name="categories[]" multiple="multiple" size="10" style="width:250px;">
  <%= options_from_collection_for_select(@categories, "id", "name", @selected) %>
  </select>

  Keywords:

  <%= text_field 'article', 'keywords'  %>

  Add Extended Content

  Extended:

  <%= text_area 'article', 'extended', :rows => 30, :style => 'width: 48%;'  %>

Toggle Advanced Options (+/-)

Allow comments: <%= check_box 'article', 'allow_comments'  %>

Allow pings: <%= check_box 'article', 'allow_pings'  %>

Published:<%= check_box 'article', 'published'  %>

Textfilter: <%= select 'article', 'text_filter', text_filter_options %>

Publish at:<%= datetime_select 'article', 'published_at', :include_blank => true  %>

Attachments (+/-)

<%= render :partial => 'admin/content/attachment', :locals => { :attachment_num => 1 } -%>


Additional quote.

Additional quote.

<% @title = "About" %>

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 "promptly", and in any event not later
than 20 working days after receiving your request. The date of that hard limit
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 remind
them that they are breaking the law. Note: If you had to
clarify your request, the clock starts from that date, instead of the date they
received your initial request.

What if I'm not satisfied with the response?

If you didn't get the information you asked for, or you didn't get it in time,
then read our page 'Unhappy about the response you got?'.

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.

Why can I only request information about the environment from some authorities?

Some public authorities, such as South East Water,
don't come under the Freedom of Information Act, but do come under another law called
the Environmental Information Regulations (EIR). It's a very similar law, so you make a request
to them using WhatDoTheyKnow in just the same way as an FOI request. The only difference
is that on the page where you write you request, it reminds you that you can only
request "environmental information" and tells you what that means. It is quite broad.

So can I request information using EIR from other authorities?

Yes, just make a Freedom of Information (FOI) request as normal. The
authority has a duty to work out if the Environmental Information Regulations
(EIR) is the more appropriate legislation to reply under.

Privacy questions

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
relating to a request you made, an email alert that you have signed up for,
or for other reasons that you specifically authorise. 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.

They've asked for my postal address!

If a public authority asks you for your full, physical address, reply to them saying
that section 8.1.b of the FOI Act asks for an "address for correspondence",
and that the email address you are using is sufficient.

The Ministry of Justice has guidance
on this –
"As well as hard copy written correspondence, requests that are
transmitted electronically (for example, in emails) are acceptable
... If a request is received by email and no postal address is given, the email
address should be treated as the return address."

As if that isn't enough, the Information Commissioner's
Hints for Practitioners say
"Any correspondence could include a request for information. If it is written (this includes e-mail), legible, gives the name of the applicant, an address for reply (which could be electronic), and includes a description of the information required, then it will fall within the scope of the legislation."

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.

FOI officer questions

Why are you publishing responses to FOI requests?

Freedom of Information responses contain public information, which anybody could
easily request again from the public authority. Therefore,
there is no reason they shouldn't be published on the Internet. There are lots
of benefits - everything from preventing duplicate requests, to getting the public
more involved and interested in the work of government.

Are the people making requests real people?

Yes. This website is a service to help ordinary members of the public
make FOI requests, and easily track the responses. The people are real
people, for whom we have a verified email address unique to each person.

Aren't you making lots of vexatious requests?

WhatDoTheyKnow is not making any requests. We are sending requests on
behalf of our users, who are real people making the requests. Look at it like
this - if lots of different people made requests from different Hotmail email
addresses, then you would not think that Microsoft were making vexatious
requests. It is exactly the same if lots of requests are made via
WhatDoTheyKnow. Moreover, since all requests are public it is much easier for
you to see if one of our users is making vexatious requests, and for us to
block them when that happens.

Won't I be breaking copyright law by sending a response that you then publish?

No, you will simply be replying to an FOI request by email (the "expressed
preference" of the requester, under
section
11(1) of the Freedom of Information Act). That we are later republishing your
response is a separate matter of copyright law, and not something which FOIA lists
as a reason for rejecting a request.

Isn't it a problem that you publish the names of civil servants
and the text of emails?

Officers or servants responding to requests are doing so on behalf of the
public as part of their job, and we publish their response on that
basis. Usually the names and phone numbers of FOI officers are already
available on authority websites. We also encourage our users to give their real
name too, so it is fair both ways.

Do you publish email addresses or mobile phone numbers?

We automatically remove email addresses and labelled mobile phone numbers
that are in the email part of responses from public authorities. Please
contact us if we've missed one. We don't currently
remove these from attachments,
such as Word documents.

Can you take down private information about me?

If you see any information on the site which you'd like us to remove or
hide, then please let us know. We'll then
remove it, provided it is genuinely private information.

Credit where credit is due

Which people made WhatDoTheyKnow?

Oh, nearly everyone (and maybe you too)!

    Heather Brooke
    (vampy!) has
    been pushing the idea of a UK FOI archive for years now.

    Both Phil Rodgers and Francis Irving
    entered it in a mySociety competition for ideas for public interest websites to build.

    It won,
    and then Chris Lightfoot (RIP :()
    thought up the wheeze of intercepting email responses to requests and
    automatically publishing them.

    Tom Steinberg got the cash to pay for the site from
    a dead chocolate mogul (thank you!) ...

    ... so that Francis Irving, Angie Ahl, Tommy Martin, Louise Crow, Matthew Somerville
    and Tom Steinberg could do the complex mixture of design and coding to build
    what you see today.

    Thanks particularly to Julian Todd (great blog!),
    Francis Davey, and Etienne Pollard for using the site early on and giving
    feedback (and/or legal advice!), and also to all our other users and
    testers.

    Lots of people have been looking up FOI email addresses, and a few
    volunteering to run the site - most especially Adam McGreggor, Alex
    Skene, John Cross and Tony Bowden.

Finally we couldn't do any of this without those
crazy people who volunteer,
amongst many other things, to do the accounts and fill in our VAT return.

You're all stars.

<% @title = "About" %>

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 "promptly", and in any event not later
than 20 working days after receiving your request. The date of that hard limit
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 remind
them that they are breaking the law. Note: If you had to
clarify your request, the clock starts from that date, instead of the date they
received your initial request.

What if I'm not satisfied with the response?

If you didn't get the information you asked for, or you didn't get it in time,
then read our page 'Unhappy about the response you got?'.

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.

Why can I only request information about the environment from some authorities?

Some public authorities, such as South East Water,
don't come under the Freedom of Information Act, but do come under another law called
the Environmental Information Regulations (EIR). It's a very similar law, so you make a request
to them using WhatDoTheyKnow in just the same way as an FOI request. The only difference
is that on the page where you write you request, it reminds you that you can only
request "environmental information" and tells you what that means. It is quite broad.

So can I request information using EIR from other authorities?

Yes, just make a Freedom of Information (FOI) request as normal. The
authority has a duty to work out if the Environmental Information Regulations
(EIR) is the more appropriate legislation to reply under.

Privacy questions

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
relating to a request you made, an email alert that you have signed up for,
or for other reasons that you specifically authorise. 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.

They've asked for my postal address!

If a public authority asks you for your full, physical address, reply to them saying
that section 8.1.b of the FOI Act asks for an "address for correspondence",
and that the email address you are using is sufficient.
The Ministry of Justice has guidance
on this –
"As well as hard copy written correspondence, requests that are
transmitted electronically (for example, in emails) are acceptable
... If a request is received by email and no postal address is given, the email
address should be treated as the return address."

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.

FOI officer questions

Why are you publishing responses to FOI requests?

Freedom of Information responses contain public information, which anybody could
easily request again from the public authority. Therefore,
there is no reason they shouldn't be published on the Internet. There are lots
of benefits - everything from preventing duplicate requests, to getting the public
more involved and interested in the work of government.

Are the people making requests real people?

Yes. This website is a service to help ordinary members of the public
make FOI requests, and easily track the responses. The people are real
people, for whom we have a verified email address unique to each person.

Aren't you making lots of vexatious requests?

WhatDoTheyKnow is not making any requests. We are sending requests on
behalf of our users, who are real people making the requests. Look at it like
this - if lots of different people made requests from different Hotmail email
addresses, then you would not think that Microsoft were making vexatious
requests. It is exactly the same if lots of requests are made via
WhatDoTheyKnow. Moreover, since all requests are public it is much easier for
you to see if one of our users is making vexatious requests, and for us to
block them when that happens.

Won't I be breaking copyright law by sending a response that you then publish?

No, you will simply be replying to an FOI request by email (the "expressed
preference" of the requester, under
section
11(1) of the Freedom of Information Act). That we are later republishing your
response is a separate matter of copyright law, and not something which FOIA lists
as a reason for rejecting a request.

Isn't it a problem that you publish the names of civil servants
and the text of emails?

Officers or servants responding to requests are doing so on behalf of the
public as part of their job, and we publish their response on that
basis. Usually the names and phone numbers of FOI officers are already
available on authority websites. We also encourage our users to give their real
name too, so it is fair both ways.

Do you publish email addresses or mobile phone numbers?

We automatically remove email addresses and labelled mobile phone numbers
that are in the email part of responses from public authorities. Please
contact us if we've missed one. We don't currently
remove these from attachments,
such as Word documents.

Can you take down private information about me?

If you see any information on the site which you'd like us to remove or
hide, then please let us know. We'll then
remove it, provided it is genuinely private information.

Credit where credit is due

Which people made WhatDoTheyKnow?

Oh, nearly everyone (and maybe you too)!

    Heather Brooke
    (vampy!) has
    been pushing the idea of a UK FOI archive for years now.

    Both Phil Rodgers and Francis Irving
    entered it in a mySociety competition for ideas for public interest websites to build.

    It won,
    and then Chris Lightfoot (RIP :()
    thought up the wheeze of intercepting email responses to requests and
    automatically publishing them.

    Tom Steinberg got the cash to pay for the site from
    a dead chocolate mogul (thank you!) ...

    ... so that Francis Irving, Angie Ahl, Tommy Martin, Louise Crow, Matthew Somerville
    and Tom Steinberg could do the complex mixture of design and coding to build
    what you see today.

    Thanks particularly to Julian Todd (great blog!),
    Francis Davey, and Etienne Pollard for using the site early on and giving
    feedback (and/or legal advice!), and also to all our other users and
    testers.

    Lots of people have been looking up FOI email addresses, and a few
    volunteering to run the site - most especially Adam McGreggor, Alex
    Skene, John Cross and Tony Bowden.

Finally we couldn't do any of this without those
crazy people who volunteer,
amongst many other things, to do the accounts and fill in our VAT return.

You're all stars.


Roll back [25] for now, because Rails 1.1.x doesn't support  { :method => :post }.

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

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

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

%>

<% unless @object.new_record? %>

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

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

<%

    builder.epilogue do
    end
  end
end
%>

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

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

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

%>

<% unless @object.new_record? %>

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

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

<%

    builder.epilogue do
    end
  end
end
%>


ahora si

ahora si

git-svn-id: 268669d3058f191005ae665964cd19b71efa10c4@13148 3f47a204-8049-4147-aab0-d444c64e7564

<% if logged_in? && current_user.superuser==true %>

<%= link_to "Events" , {:controller=>'events', :action=>'show'}, :class => "secund", :method=> 'get'%>

<%= link_to 'Search' , {:controller=>'events',:action => 'search'}, :class => "secund", :title=>"Search for events"%>

<%= link_to "Resources", {:controller=>'machines',  :action=>'list_user_machines'},:class => "secund",:method=> 'get'%>

<%= link_to 'Manage Users' ,  manage_users_path, :class => "secund", :method=> 'get' %>

<%= link_to 'Manage Resources',  manage_resources_path, :class => "secund", :method=> 'get' %>

<% elsif logged_in?%>

<%= link_to 'Search', {:controller=>'events', :action => 'search'},  :title=>"Search for events"%>

<%= link_to "Events", {:controller=>'events', :action=>'show'}, :method=> 'get'%>

<%= link_to "Resources", {:controller=>'machines', :class => "secund", :action=>'list_user_machines'},:method=> 'get'%>

<% else %>

<%= link_to "Home", {:controller=>'events', :action=>'show'}, :class => "secund" , :method=> 'get'%>

<%= link_to 'Search', {:action => 'search'}, :class => "secund" ,:title=>"Search for events"%>

<% end %>

<% if logged_in? && current_user.superuser==true %>

<%= link_to "Events" , {:controller=>'events', :action=>'show'}, :class => "secund", :method=> 'get'%>

<%= link_to 'Search' , {:controller=>'events',:action => 'search'}, :class => "secund", :title=>"Search for events"%>

<%= link_to "Resources", {:controller=>'machines',  :action=>'list_user_machines'},:class => "secund",:method=> 'get'%>

<%= link_to 'Manage Users' ,  manage_users_path, :class => "secund", :method=> 'get' %>

<%= link_to 'Manage Resources',  manage_resources_path, :class => "secund", :method=> 'get' %>

<% elsif logged_in?%>

<%= link_to 'Search', {:action => 'search'},  :title=>"Search for events"%>

<%= link_to "Events", {:controller=>'events', :action=>'show'}, :method=> 'get'%>

<%= link_to "Resources", {:controller=>'machines', :class => "secund", :action=>'list_user_machines'},:method=> 'get'%>

<% else %>

<%= link_to "Home", {:controller=>'events', :action=>'show'}, :class => "secund" , :method=> 'get'%>

<%= link_to 'Search', {:action => 'search'}, :class => "secund" ,:title=>"Search for events"%>

<% end %>


remove debug message that got in

remove debug message that got in

<%= javascript_include_tag "update_view_links" %>

    All staff have access to reports now.  Your report will open in a new window.  Click the CSV link to have the report open in excel.

    <% if @is_staff %>

    Questionnaire Dependent Reports

Please contact russ.martin@c4c.ca if there is a report you need to work that is not.  If a report is not here that you want, you can try and create it in the custom reports.

        <% if !@project_director_projects.empty? %>

<%= project_specific_report 'Processor Forms', 'processor_forms',
                        :formats => [ 'pdf','html' ], :include_blank => true, :include_all => true,
                        :projects_list => 'director' do |report|
                      viewers_with_profile_for_project_choice report, :formats => [ 'pdf','html' ], :include_all => true
                    end
                %>
                This report can take a few minutes for a full project.

<%= project_specific_report 'Summary Forms', 'summary_forms',
                        :formats => [ 'pdf','html' ], :include_blank => true,
                        :projects_list => 'director' do |report|
                      viewers_with_profile_for_project_choice report, :formats => [ 'pdf','html' ], :include_all => true
                    end
                %>
                This report can take a few minutes for a full project.

         <% end %>

   Standard Reports (for all projects and event groups)

         Lists all registrants -- people applying for a given project, who indicated this project as their first preference.

<%= project_specific_report 'Registrants', 'registrants', :include_all => true %>

         Lists participants -- people accepted for a given project

<%= project_specific_report 'Accepted', 'participants', :include_all => true %>

         For this event group, lists all projects and relevant statistics of how many started, submitted, completed, accepted and withdrawn applications each project has.

<%= report 'Project Stats', 'project_stats', :include_all => true %>

         Lists financial status of all project participants for the given project.

<%= project_specific_report 'Funding Status', 'funding_status', :include_all => true %>

         Lists the financial situation of an individual project participant.

<%= project_specific_report 'Funding Details', 'funding_details_costing', :include_blank => true do |report|
         viewers_with_profile_for_project_choice(report)
         end
         %>

         Lists all applicants and their passport information such as birthdate, passport number, passport expiry and passport country.

<%= project_specific_report 'Travel List', 'travel_list', :include_all => true, :include_pref1s_option => true %>

         Lists all project participants and their individual travel itineraries.

<%= project_specific_report 'Itinerary', 'itinerary', :include_all => true,
                :include_pref1s_option => false %>

        Lists all project participants assigned to a given travel segment (flight).

<%= travel_segment_specific_report 'Profiles with travel segment ', 'travel_segment',
                :include_all => true, :include_profiles_option => true do
                  @append = " | " + link_to("custom", {:action => "custom_itinerary_report"})
                  ""
                end %>

        Lists all applicants that have been accepted as interns.  To include the people currently applying as interns use the checkbox.

<%= project_specific_report 'Interns', 'interns', :include_all => true, :include_pref1s_option => true %>

        Lists all participants who have a given cost item applied to them.

<%= project_specific_report 'Cost Items', 'cost_items',
                     :include_blank => true, :include_all => true,
                     :projects_list => 'director' do |report|
                   cost_items_for_project report
                 end
                %>

        Lists all manual donations for a project.

<%= project_specific_report 'Manual Donations', 'manual_donations',
                    :include_blank => true, :include_all => true do |report|
                [  %|
              type #{select_tag 'manual_donations_type',
                options_for_select(['all' ] + DonationType.find(:all).collect(&:description), 'USDMANUAL')}
                #{observe_field 'manual_donations_type', :function => 'set_manual_donation_status_visibility();'}

                status #{select_tag 'manual_donations_status', options_for_select(['any' ] + ManualDonation::STATUSES, 'all')}

              |, [ 'type', 'status' ] ]
                end %>

        Lists the status of paperwork items.

<%= project_specific_report 'Prep Items', 'prep_items',
                     :include_blank => true, :include_all => true,
                     :projects_list => 'director' do |report|
                   prep_items_for_project report, :include_all => true
                 end
                %>

        Lists crisis information for everyone accepted to a project

<%= project_specific_report 'Crisis Info', 'crisis_management', :include_all => true,
                :include_blank => true,
                :include_pref1s_option => false %>

    <% end %>


For the time being, allow wiki assignments to return all updates made starting at the date when the assignment was created.

git-svn-id: f67d969b640da65cb7bc1d229e09fd6d2db44ae1@584 392d7b7b-3f31-0410-9dc3-c95a9635ea79

<% # The code below should be replaced with a call to a function that returns a list of the submitted files
   # (or listing of wiki pages the reviewer should be able to see).  Then, you check the cardinality of that
   # list.  If it is nonzero, you print out the list and then the review form.  If it is 0, you print a message
   # saying nothing has been submitted, and exit.
%>
<%if @assgt.wiki_type.name == "No"%>
<%if @files.size == 0%>

<%else%>
Submitted Files

<%end%>
<%end%>

<%
 _time = Time.now.month.to_s + "/" + Time.now.day.to_s + "/" + Time.now.year.to_s
 if @assgt.wiki_type.name == "DokuWiki" %>

DokuWiki Review Links:

<% # The code below becomes @assgt.review, which invokes the proper review function
   # for this type of assignment
%>
<%= review_dokuwiki @assgt.directory_path, _time, @author_name  %>

<% elsif @assgt.wiki_type.name == "MediaWiki" %>

MediaWiki Review Links:

<% # What we need here is a method that finds all of the contributions of the
   # user(s) being reviewed, e.g., files submitted or wiki pages created.  It
   # should return an array of links.  It is passed (or has as its receiver)
   # some kind of data structure that contains the IDs of the user(s) being reviewed.
%>
<% # We shouldn't check for team assignments.  Rather, an assignment should have an
   # attribute that corresponds to whether or not it's a team assignment.  This
   # attribute will be sent a message G to go get a set of the users being reviewed.
   # Then the method that finds all the contributions (described in the immediately
   # preceding comment) will be sent the array that message G returns).
%>
<%if @assgt.team_assignment
  	for team_member in @team_members
		member_name = User.find(team_member.user_id).name
%>
	<%= review_mediawiki_group @assgt.directory_path, @assgt.created_at, member_name  %>
	<%end%>
<%else%>
	<%= review_mediawiki @assgt.directory_path, @assgt.created_at, @author_name  %>
<%end%>

<% end %>

<% for file in @files %>

<%= link_to File.basename(file), :action => 'new_review', :id => @mapping_id, :fname => File.basename(file),"current_folder[name]" => @current_folder.name %>

<% end %>

<% # The code below should be replaced with a call to a function that returns a list of the submitted files
   # (or listing of wiki pages the reviewer should be able to see).  Then, you check the cardinality of that
   # list.  If it is nonzero, you print out the list and then the review form.  If it is 0, you print a message
   # saying nothing has been submitted, and exit.
%>
<%if @assgt.wiki_type.name == "No"%>
<%if @files.size == 0%>

<%else%>
Submitted Files

<%end%>
<%end%>

<%
 _time = Time.now.month.to_s + "/" + Time.now.day.to_s + "/" + Time.now.year.to_s
 if @assgt.wiki_type.name == "DokuWiki" %>

DokuWiki Review Links:

<% # The code below becomes @assgt.review, which invokes the proper review function
   # for this type of assignment
%>
<%= review_dokuwiki @assgt.directory_path, _time, @author_name  %>

<% elsif @assgt.wiki_type.name == "MediaWiki" %>

MediaWiki Review Links:

<% # What we need here is a method that finds all of the contributions of the
   # user(s) being reviewed, e.g., files submitted or wiki pages created.  It
   # should return an array of links.  It is passed (or has as its receiver)
   # some kind of data structure that contains the IDs of the user(s) being reviewed.
%>
<% # We shouldn't check for team assignments.  Rather, an assignment should have an
   # attribute that corresponds to whether or not it's a team assignment.  This
   # attribute will be sent a message G to go get a set of the users being reviewed.
   # Then the method that finds all the contributions (described in the immediately
   # preceding comment) will be sent the array that message G returns).
%>
<%if @assgt.team_assignment
  	for team_member in @team_members
		member_name = User.find(team_member.user_id).name
%>
	<%= review_mediawiki_group @assgt.directory_path, _time, member_name  %>
	<%end%>
<%else%>
	<%= review_mediawiki @assgt.directory_path, _time, @author_name  %>
<%end%>

<% end %>

<% for file in @files %>

<%= link_to File.basename(file), :action => 'new_review', :id => @mapping_id, :fname => File.basename(file),"current_folder[name]" => @current_folder.name %>

<% end %>


Add option to remove description

Add option to remove description

<% article = article_common %>
<% show_description = true if show_description.nil? %>

<%= render :partial => 'article_author', :object => article %>
<%= render :partial => 'article_description', :object => article if show_description %>
<%= render :partial => 'article_tags', :object => article.tags %>
<%= render :partial => 'article_categories', :object => article.categories %>
<%= render :partial => 'article_last_change', :object => article %>

<% article = article_common %>

<%= render :partial => 'article_author', :object => article %>
<%= render :partial => 'article_description', :object => article %>
<%= render :partial => 'article_tags', :object => article.tags %>
<%= render :partial => 'article_categories', :object => article.categories %>
<%= render :partial => 'article_last_change', :object => article %>


typo fix

typo fix

Erfolgsrechnung für <%= @client.name %> <%= @year %>

    Aufwand
    Ertrag

          Konto
          Saldo

        <% for account in @client.expenses %>

          <%= link_to account.title, :controller => 'accounts', :action => 'show', :id => account %>
          <%= account.saldo %>

        <% end %>

          Total
          <%= @client.saldo(:expenses) %>

          Konto
          Saldo

        <% for account in @client.earnings %>

          <%= link_to account.title, :controller => 'accounts', :action => 'show', :id => account %>
          <%= -account.saldo %>

        <% end %>

          Total
          <%= -@client.saldo(:earnings) %>

Erfolgrechnung für <%= @client.name %> <%= @year %>

    Aufwand
    Ertrag

          Konto
          Saldo

        <% for account in @client.expenses %>

          <%= link_to account.title, :controller => 'accounts', :action => 'show', :id => account %>
          <%= account.saldo %>

        <% end %>

          Total
          <%= @client.saldo(:expenses) %>

          Konto
          Saldo

        <% for account in @client.earnings %>

          <%= link_to account.title, :controller => 'accounts', :action => 'show', :id => account %>
          <%= -account.saldo %>

        <% end %>

          Total
          <%= -@client.saldo(:earnings) %>


European date format in HTML output

European date format in HTML output

<!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><%= title %></title>

  <%= syntax_highlighter %>

  <% if history %>

Last revision:
      <%= history.revisions.first.subject %>
      (<%= history.revisions.first.author %>, <%= history.revisions.first.date.strftime('%d/%m/%Y %H:%M') %>) |
      History

  <% end %>

<%= content %>

  <% if history %>

History

    <% history.revisions.each do |revision| %>
    <div id="revision_<%= revision.sha %>" class="revision">

<%= revision.date.strftime('%d/%m/%Y %H:%M') %> : <%= revision.subject %> (<%= revision.author %>)

<%= revision.diff %>

    <% end %>

  <% end %>

<!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><%= title %></title>

  <%= syntax_highlighter %>

  <% if history %>

Last revision:
      <%= history.revisions.first.subject %>
      (<%= history.revisions.first.author %>, <%= history.revisions.first.date.strftime('%m/%d/%Y %H:%M') %>) |
      History

  <% end %>

<%= content %>

  <% if history %>

History

    <% history.revisions.each do |revision| %>
    <div id="revision_<%= revision.sha %>" class="revision">

<%= revision.date.strftime('%m/%d/%Y %H:%M') %> : <%= revision.subject %> (<%= revision.author %>)

<%= revision.diff %>

    <% end %>

  <% end %>


Fix HTML, code formatting and spelling only

<% @title = "Making requests" %>

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

<%= @title %> #

I'm not sure which authority to make my request to, how can I find out? #

It can be hard to untangle government's complicated structured, and work out
who knows the information that you want. Here are a few tips:

Browse or search <%= site_name %> looking for similar requests to yours.

When you've found an authority you think might have the information, use
the "home page" link on the right hand side of their page to check what they do
on their website.

Contact the authority by phone or email to ask if they hold the kind of
information you're after.

Don't worry excessively about getting the right authority. If you get it
wrong, they will transfer your request to the correct authority for you.

If you've got a thorny case, please contact us for help.

Who can make a request? #

Any person, of any nationality, anywhere in the world, however young or old can make a request under Federal Australian Freedom of Information (FOI) law.

The Freedom of Information Act simply says that "every person has a legally enforceable right to obtain access in accordance with this Act". A "person" can also be a body corporate, such as a company.

See the Attorney General's department FOI Guidelines – Fundamental principles and procedures - section 3.2 for more.

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

At the moment we aim to cover all Australian Federal public authorities. We plan to add State and Local Government authorities soon.

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 (new state or local government region etc.) of public authority to the site, we'd love
to hear from you too.

Why do you include some authorities that aren't formally subject to FOI?#

<%= site_name %> lets you make requests for information to a range of
organisations:

 Those formally subject to the FOI Act

 Those which choose to voluntarily comply with the FOI Act

 Those which aren't subject to the Act but we think should be, on grounds
  such as them having significant public responsibilities.

In the last case, we're using the site to lobby for expansion of the
scope of the FOI Act. Even if an organisation is not legally obliged to respond
to an FOI request, they can still do so voluntarily.

Why must I keep my request focused?#

Please put in your request only what is needed so that someone can
easily identify what information you are asking for. Please do
not include any of the following:

arguments about your cause

statements that could defame or insult others

If you do, we may have to remove your request to avoid problems with
libel law, which is a pain for both you and us. Short, succinct messages
make it easier for authorities to be clear what information you are
requesting, which means you will get a reply more quickly.

If you want information to support an argument or campaign, Freedom of
Information is a powerful tool. Although you may not use this site to
run your campaign, we encourage you to use it to get the information you
need. We also encourage to run your campaign elsewhere - one effective
and very easy way is to <%= link_to 'start your own blog',
"http://wordpress.com/"%>. You are welcome to link to your campaign
from this site in an annotation to your request (you can make
annotations after submitting the request).

Does it cost me anything to make a request?#

  Making an FOI request is always free. A public body may choose to impose
  certain charges to provide the information but they can only charge you if
  you have specifically agreed in advance to pay.

  The
  law contains a 'lowest reasonable cost' objective, meaning that if
  the public body chooses to impose a charge it should fairly reflect the work
  involved in providing access to documents and must not be used to discourage
  you from exercising your right of access.

  If a public body decides to charge you for access to documents there are
  certain circumstances where the
  charges may be reduced or waived, such as:

Releasing the information is in the general public interest

The charges would cause you financial hardship (e.g. you're a pensioner)

Sometimes an authority will refuse your request, saying that the cost
of handling it exceeds a level that would detriment their day to day work. At this point you can refine your
request. e.g. it would be much cheaper for an authority to tell you the amount
spent on marshmallows in the past year than in the past ten years.

How quickly will I get a response? #

  By law, the public authority must keep you informed about the progress of your FOI request.

  Within 14 days after they receive your request they must give you
  written acknowledgement and within 30 days they
  must provide you with either the documents you have asked for or a written
  decision on your request.

  For various reasons,
  this timeframe can be extended.

  <%= site_name %> will email you if you don't get a timely response.  You can
  then send the public authority a message to remind them, and tell them if they
  are breaking the law.

What if I never get a response?#

There are several things you can do if you never get a response.

Sometimes there has been a genuine problem and the authority never
    received the request. It is worth telephoning the authority and politely
    checking that they received the request. It was sent to them by email.

If they have not received it, the problem is most likely due to
    "spam filters". Refer the authority to the measures in the answer
    'I can see a request on <%= site_name %>, but we never got it by email!'
    in the FOI officers section of this help.

If you're still having no luck, then you can ask for an internal review,
    or complain to the Information Commissioner about the authority, or both.
    Read our page 'Unhappy about the response you got?'.

What if I'm not satisfied with the response? #

If you didn't get the information you asked for, or you didn't get it in time,
then read our page 'Unhappy about the response you got?'.

It says I can't re-use the information I got!#

  Authorities often add legal boilerplate about the Commonwealth Copyright
  Administration, which at first glance implies you may not be able do
  anything with the information. This is likely to be incorrect as the latest

    Statement of IP Principles for Australian Government Agencies

  explicitly encourages reuse.

    Consistent with the need for free and open re-use and adaptation, public
    sector information should be licensed by agencies under the Creative
    Commons BY standard as the default.

You can, of course, write articles about the information or summarise it, or
quote parts of it. We also think you should feel free to republish the
information in full, just as we do, even though in theory you might not be
allowed to do so.  See our policy on copyright.

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

Have a look at the
Freedom of Information guidelines
pages on the Information Commissioner's website.

Can I request information about myself? #

No. Requests made using <%= site_name %> are public, made under the Freedom of
Information Act, and cannot help you find information about a private
individual.

If you see that somebody has included personal information, perhaps
unwittingly, in a request, please contact us
immediately so we can remove it.

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

<%= site_name %> 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.

Can I make the same to request to lots of authorities, e.g. all departments? #

We ask you to first send a test version of your request to a few
authorities. Their responses will help you improve the wording of your request,
so that you get the best information when you send the request to all of
the authorities. There is currently no automated system for sending the request
to the other authorities, you must copy and paste it by hand.

I made a request off the site, how do I upload it to the archive?#

<%= site_name %> is an archive of requests made through the site,
and does not try to be an archive of all FOI requests. We'll never support uploading
other requests. For one thing, we wouldn't be able to verify that other
responses actually came from the authority. If this really matters to you,
you can always make the same request again via <%= site_name %>.

How do you moderate request annotations? #

Annotations on <%= site_name %> are to help
people get the information they want, or to give them pointers to places they
can go to help them act on it. We reserve the right to remove anything else.

Endless, political discussions are not allowed.
Post a link to a suitable forum or campaign site elsewhere.

Next, read about your privacy -->

<% @title = "Making requests" %>

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

<%= @title %> #

I'm not sure which authority to make my request to, how can I find out? #

It can be hard to untangle government's complicated structured, and work out
who knows the information that you want. Here are a few tips:

Browse or search <%= site_name %> looking for similar requests to yours.

When you've found an authority you think might have the information, use
the "home page" link on the right hand side of their page to check what they do
on their website.

Contact the authority by phone or email to ask if they hold the kind of
information you're after.

Don't worry excessively about getting the right authority. If you get it
wrong, they will transfer your request to the correct authority for you.

If you've got a thorny case, please contact us for help.

Who can make a request? #

Any person, of any nationality, anywhere in the world, however young or old can make a request under Federal Australian Freedom of Information (FOI) law.

The Freedom of Information Act simply says that "every person has a legally enforceable right to obtain access in accordance with this Act". A "person" can also be a body corporate, such as a company.

See the Attorney General's department FOI Guidelines – Fundamental principles and procedures - section 3.2 for more.

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

At the moment we aim to cover all Australian Federal public authorities. We plan to add State and Local Government authorities soon.

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 (new state or local government region etc.) of public authority to the site, we'd love
to hear from you too.

Why do you include some authorities that aren't formally subject to FOI?#

<%= site_name %> lets you make requests for information to a range of
organisations:

 Those formally subject to the FOI Act

 Those which choose to voluntarily comply with the FOI Act

 Those which aren't subject to the Act but we think should be, on grounds
  such as them having significant public responsibilities.

In the last case, we're using the site to lobby for expansion of the
scope of the FOI Act. Even if an organisation is not legally obliged to respond
to an FOI request, they can still do so voluntarily.

Why must I keep my request focused?#

Please put in your request only what is needed so that someone can
easily identify what information you are asking for. Please do
not include any of the following:

arguments about your cause

statements that could defame or insult others

If you do, we may have to remove your request to avoid problems with
libel law, which is a pain for both you and us. Short, succinct messages
make it easier for authorities to be clear what information you are
requesting, which means you will get a reply more quickly.

If you want information to support an argument or campaign, Freedom of
Information is a powerful tool. Although you may not use this site to
run your campaign, we encourage you to use it to get the information you
need. We also encourage to run your campaign elsewhere - one effective
and very easy way is to <%= link_to 'start your own blog',
"http://wordpress.com/"%>. You are welcome to link to your campaign
from this site in an annotation to your request (you can make
annotations after submitting the request).

Does it cost me anything to make a request?#

  Making an FOI request is always free. A public body may choose to impose
  certain charges to provide the information but they can only charge you if
  you have specifically agreed in advance to pay.

  The
  law contains a 'lowest reasonable cost' objective, meaning that if
  the public body chooses to impose a charge it should fairly reflect the work
  involved in providing access to documents and must not be used to discourage
  you from exercising your right of access.

  If a public body decides to charge you for access to documents there are
  certain circumstances where the
  charges may be reduced or waived, such as:

Releasing the information is in the general public interest

The charges would cause you financial hardship (e.g. you're a pensioner)

Sometimes an authority will refuse your request, saying that the cost
of handling it exceeds a level that would detriment their day to day work. At this point you can refine your
request. e.g. it would be much cheaper for an authority to tell you the amount
spent on marshmallows in the past year than in the past ten years.

How quickly will I get a response? #

  By law, the public authority must keep you informed about the progress of your FOI request.

  Within 14 days after they receive your request they must give you
  written acknowledgement and within 30 days they
  must provide you with either the documents you have asked for or a written
  decision on your request.

  For various reasons,
  this timeframe can be extended.

  <%= site_name %> will email you if you don't get a timely response.  You can
  then send the public authority a message to remind them, and tell them if they
  are breaking the law.

What if I never get a response?#

There are several things you can do if you never get a response.

Sometimes there has been a genuine problem and the authority never
    received the request. It is worth telephoning the authority and politely
    checking that they received the request. It was sent to them by email.

If they have not received it, the problem is most likely due to
    "spam filters". Refer the authority to the measures in the answer
    'I can see a request on <%= site_name %>, but we never got it by email!'
    in the FOI officers section of this help.

If you're still having no luck, then you can ask for an internal review,
    or complain to the Information Commissioner about the authority, or both.
    Read our page 'Unhappy about the response you got?'.

What if I'm not satisfied with the response? #

If you didn't get the information you asked for, or you didn't get it in time,
then read our page 'Unhappy about the response you got?'.

It says I can't re-use the information I got!#

Authorities often add legal boilerplate about the
Commonwealth Copyright Adminstration, which at first glance implies you may not
be able do anything with the information. This is likely to be incorrect as the latest Statement of IP Principles for Australian Government Agencies explictly encourages reuse.

Consistent with the need for free and open re-use and adaptation, public sector
information should be licensed by agencies under the Creative Commons BY standard
as the default.

You can, of course, write articles about the information or summarise it, or
quote parts of it. We also think you should feel free to republish the
information in full, just as we do, even though in theory you might not be
allowed to do so.  See our policy on copyright.

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

Have a look at the
Freedom of Information guidelines
pages on the Information Commissioner's website.

Can I request information about myself? #

No. Requests made using <%= site_name %> are public, made under the Freedom of
Information Act, and cannot help you find information about a private
individual.

If you see that somebody has included personal information, perhaps
unwittingly, in a request, please contact us
immediately so we can remove it.

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

<%= site_name %> 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.

Can I make the same to request to lots of authorities, e.g. all departments? #

We ask you to first send a test version of your request to a few
authorities. Their responses will help you improve the wording of your request,
so that you get the best information when you send the request to all of
the authorities. There is currently no automated system for sending the request
to the other authorities, you must copy and paste it by hand.

I made a request off the site, how do I upload it to the archive?#

<%= site_name %> is an archive of requests made through the site,
and does not try to be an archive of all FOI requests. We'll never support uploading
other requests. For one thing, we wouldn't be able to verify that other
responses actually came from the authority. If this really matters to you,
you can always make the same request again via <%= site_name %>.

How do you moderate request annotations? #

Annotations on <%= site_name %> are to help
people get the information they want, or to give them pointers to places they
can go to help them act on it. We reserve the right to remove anything else.

Endless, political discussions are not allowed.
Post a link to a suitable forum or campaign site elsewhere.

Next, read about your privacy -->


Small fix to search scaffold from Michael Genereux

Search for <%= @scaffold_plural_name.humanize.downcase %>

<%= form(@scaffold_singular_name, :action=>"results"+@scaffold_suffix, :submit_value=>"Search #{@scaffold_plural_name.humanize.downcase}") do |form|
  form << "

"
  form << "
Null Fields:	#{select('null', nil, @scaffold_nullable_fields, {}, :multiple=>true)}
\n"
  form << "
Not Null Fields:	#{select('notnull', nil, @scaffold_nullable_fields, {}, :multiple=>true)}
\n"
  form << '

'
end %>

<%= manage_link %>


ActionItem1050: fixing indentation

ActionItem1050: fixing indentation

    <title><%= page_title %></title>
    <%= meta_tags_for_article(@page) %>

    <meta http-equiv="Content-Type" content="text/html; charset=utf-8"/>
    <%= noosfero_javascript %>
    <%= import_blocks_stylesheets %>
    <%= import_controller_stylesheets %>
    <%= stylesheet_import(
          %w( common help menu article button search ),
          %w( blocks forms login-box thickbox profiles),
          template_stylesheet_path(),
          icon_theme_stylesheet_path(),
          theme_stylesheet_path(),
          pngfix_stylesheet_path()
        ) %>

  <body class="<%=
    # Identify the current controller and action for the CSS:
    " controller-"+ @controller.controller_name() +
    " action-"+ @controller.controller_name() +"-"+ @controller.action_name() +
    " template-"+ ( profile.nil? ? "default" : profile.layout_template )
    %>" onresize="registerDocumentSize()">

    Ir para o conteúdo

        <%= theme_header %>

          <% if logged_in? %>
            <%= _('Welcome, %s.') % link_to('' + user.identifier + '', user.url, :id => "homepage-link", :title => _('Go to your homepage')) %>
            <%= link_to('' + _('Administration') + '', user.admin_url, :id => "controlpanel", :title => _("Configure the system")) %>
            <%= link_to('' + _('Control panel') + '', user.admin_url, :id => "controlpanel", :title => _("Configure your personal account and content")) %>
            <%= link_to('' + _('Logout') + '', { :controller => 'account', :action => 'logout'} , :id => "logout", :title => _("Leave the system")) %>
          <% else %>
            <%= _('%s or %s') % [thickbox_inline_popup_link('' + _('Login') + '', 'inlineLoginBox', :id => 'link_login', :help => _('Click here to enter your username and password and be recognized by the system.')), link_to('' + _('Register') + '', :controller => 'account', :action => 'signup') ] %>

              <%= render :file => 'account/login' %>
              <%= thickbox_close_button _('Close') %>

          <% end %>

          <form action="/search" class="search_form" method="get" class="clean">
            <input name="query" size="15" value="<%=_('Search...')%>"
                onfocus="this.form.className='focused';
                         if(this.value=='<%=_('Search...')%>'){this.value=''}"
                onblur="this.form.className='';
                        if(/^\s*$/.test(this.value)){
                          this.value='<%=_('Search...')%>';
                          this.form.className='clean'
                        }" />

<%=_('Press Enter to send the search query.')%>

          </form>

           Title of the Site

<%= link_to '' + _('People') + '',
                            '/assets/people', :id=>'people'           %>

<%= link_to '' + _('Communities') + '',
                            '/assets/communities', :id=>'communities' %>

<%= link_to '' + _('Events') + '',
                            '/assets/events', :id=>'events'           %>

          <%= insert_boxes(yield) %>

      <%= theme_footer %>


ActionItem354: fixed a problem on the definedness of simple_search local variable on the _search_form.rhml and the hiding of the advanced options

git-svn-id: 43659daf80e124e0b603d67096418e58e4f21099@1845 3f533792-8f58-4932-b0fe-aaf55b0a4547

<% simple_search = false unless defined? simple_search %>

<% form_tag( { :action => 'index', :category_path => ( @category ? @category.explode_path : [] ) },
               :method => 'get', :class => 'search_form' ) do %>
  <%= '
%s
' % form_title if defined? form_title %>

      <%= text_field_tag 'query', @query, :id => ( lightbox? ? 'popup-search-input' : '' ), :size => 50 %>
      <%= javascript_tag '$("popup-search-input").focus()' if lightbox? %>

    <%= submit_button(:search, _('Search'), :name => :search_whole_site_no) %>
    <% if @category %>
      <%= submit_button(:search, _('Search in whole site'), :name => :search_whole_site_yes) %>
    <% end %>

  <div id='advanced-search-options' style="display: <%= simple_search ? 'none' : 'block' %>">

<%= _('Search within:') %>

        <%= _('Distance: ') %><%= text_field_tag 'radius', '',:id => 'search-radius' %>
        <%= _('From: ') %><%= text_field :region, :name, :id => 'search_region' %>

        <%= auto_complete_field('search_region', :url => {:action => 'complete_region'}) %>

<%= _('Search for:') %>

        <% @search_in.map { |t,n| [t,gettext(n)] } .
          sort_by(&:last).each do |thing, name| %>

            <%= labelled_check_box name, 'find_in[]', thing.to_s, @searching[thing.to_sym] %>

          <% end %>

  <% if simple_search %>
    <%= link_to_function(_('Advanced search'), nil, :id => 'advanced_search_link') do |page|
      page['advanced_search_link'].hide
      page['advanced-search-options'].toggle
    end %>
  <% end %>

  <% if lightbox?; button_bar do %>
  <%= lightbox_close_button _('Close') %>
  <% end; end %>

<% end %>

<% form_tag( { :action => 'index', :category_path => ( @category ? @category.explode_path : [] ) },
               :method => 'get', :class => 'search_form' ) do %>
  <%= '
%s
' % form_title if defined? form_title %>

      <%= text_field_tag 'query', @query, :id => ( lightbox? ? 'popup-search-input' : '' ), :size => 50 %>
      <%= javascript_tag '$("popup-search-input").focus()' if lightbox? %>

    <%= submit_button(:search, _('Search'), :name => :search_whole_site_no) %>
    <% if @category %>
      <%= submit_button(:search, _('Search in whole site'), :name => :search_whole_site_yes) %>
    <% end %>

  <div class="search-options search-for" id='advanced-search-options' style="display: <%= simple_search ? 'none' : 'block' %>">

<%= _('Search for:') %>

      <% @search_in.map { |t,n| [t,gettext(n)] } .
                    sort_by(&:last).each do |thing, name| %>

        <%= labelled_check_box name, 'find_in[]', thing.to_s, @searching[thing.to_sym] %>

      <% end %>

  <% if simple_search %>
    <%= link_to_function(_('Advanced search'), nil, :id => 'advanced_search_link') do |page|
      page['advanced_search_link'].hide
      page['advanced-search-options'].toggle
    end %>
  <% end %>

  <% if lightbox?; button_bar do %>
  <%= lightbox_close_button _('Close') %>
  <% end; end %>

<% end %>