annotate .svn/pristine/d6/d6ec7da458d1a6039ba94f943e025c4cbc9d1f92.svn-base @ 1082:997f6d7738f7 bug_531

In repo controller entry action, show the page for the file even if it's binary (so user still has access to history etc links). This makes it possible to use the entry action as the default when a file is clicked on
author Chris Cannam <chris.cannam@soundsoftware.ac.uk>
date Thu, 22 Nov 2012 18:04:17 +0000
parents cbb26bc654de
children
rev   line source
Chris@909 1 <fieldset id="date-range" class="collapsible">
Chris@909 2 <legend onclick="toggleFieldset(this);"><%= l(:label_date_range) %></legend>
Chris@909 3 <div>
Chris@909 4 <p>
Chris@909 5 <%= label_tag "period_type_list", l(:description_date_range_list), :class => "hidden-for-sighted" %>
Chris@909 6 <%= radio_button_tag 'period_type', '1', !@free_period, :onclick => 'Form.Element.disable("from");Form.Element.disable("to");Form.Element.enable("period");', :id => "period_type_list"%>
Chris@909 7 <%= select_tag 'period', options_for_period_select(params[:period]),
Chris@909 8 :onchange => 'this.form.submit();',
Chris@909 9 :onfocus => '$("period_type_1").checked = true;',
Chris@909 10 :disabled => @free_period %>
Chris@909 11 </p>
Chris@909 12 <p>
Chris@909 13 <%= label_tag "period_type_interval", l(:description_date_range_interval), :class => "hidden-for-sighted" %>
Chris@909 14 <%= radio_button_tag 'period_type', '2', @free_period, :onclick => 'Form.Element.enable("from");Form.Element.enable("to");Form.Element.disable("period");', :id => "period_type_interval" %>
Chris@909 15 <span onclick="$('period_type_2').checked = true;">
Chris@909 16 <%= l(:label_date_from_to,
Chris@909 17 :start => ((label_tag "from", l(:description_date_from), :class => "hidden-for-sighted") +
Chris@909 18 text_field_tag('from', @from, :size => 10, :disabled => !@free_period) + calendar_for('from')),
Chris@909 19 :end => ((label_tag "to", l(:description_date_to), :class => "hidden-for-sighted") +
Chris@909 20 text_field_tag('to', @to, :size => 10, :disabled => !@free_period) + calendar_for('to'))) %>
Chris@909 21 </span>
Chris@909 22 </p>
Chris@909 23 </div>
Chris@909 24 </fieldset>
Chris@909 25 <p class="buttons">
Chris@909 26 <%= link_to_function l(:button_apply), '$("query_form").submit()', :class => 'icon icon-checked' %>
Chris@909 27 <%= link_to l(:button_clear), {:controller => controller_name, :action => action_name, :project_id => @project, :issue_id => @issue}, :class => 'icon icon-reload' %>
Chris@909 28 </p>
Chris@909 29
Chris@909 30 <div class="tabs">
Chris@909 31 <% url_params = @free_period ? { :from => @from, :to => @to } : { :period => params[:period] } %>
Chris@909 32 <ul>
Chris@909 33 <li><%= link_to(l(:label_details), url_params.merge({:controller => 'timelog', :action => 'index', :project_id => @project, :issue_id => @issue }),
Chris@909 34 :class => (@controller.action_name == 'index' ? 'selected' : nil)) %></li>
Chris@909 35 <li><%= link_to(l(:label_report), url_params.merge({:controller => 'time_entry_reports', :action => 'report', :project_id => @project, :issue_id => @issue}),
Chris@909 36 :class => (@controller.action_name == 'report' ? 'selected' : nil)) %></li>
Chris@909 37 </ul>
Chris@909 38 </div>