summaryrefslogtreecommitdiffstats
path: root/app
diff options
context:
space:
mode:
authorJean-Philippe Lang <jp_lang@yahoo.fr>2013-01-20 12:30:40 +0000
committerJean-Philippe Lang <jp_lang@yahoo.fr>2013-01-20 12:30:40 +0000
commit237f297f03e2f3fac6a41b3c0dadec6d85bcfb12 (patch)
tree20d3ca02e3460c34bd33549a32a7aba6b5f29e2a /app
parent30801ca96805a78016a625fefde9f99f51042c78 (diff)
downloadredmine-237f297f03e2f3fac6a41b3c0dadec6d85bcfb12.tar.gz
redmine-237f297f03e2f3fac6a41b3c0dadec6d85bcfb12.zip
Gantt progress lines (#12122).
Patch by Toshi MARUYAMA. git-svn-id: svn+ssh://rubyforge.org/var/svn/redmine/trunk@11210 e93f8b46-1217-0410-a6f0-8f06a7374b81
Diffstat (limited to 'app')
-rw-r--r--app/views/gantts/show.html.erb39
1 files changed, 38 insertions, 1 deletions
diff --git a/app/views/gantts/show.html.erb b/app/views/gantts/show.html.erb
index caec4c3c2..463e0f1b0 100644
--- a/app/views/gantts/show.html.erb
+++ b/app/views/gantts/show.html.erb
@@ -12,6 +12,39 @@
<%= render :partial => 'queries/filters', :locals => {:query => @query} %>
</div>
</fieldset>
+<fieldset id="filters" class="collapsible">
+ <legend onclick="toggleFieldset(this);"><%= l(:label_display) %></legend>
+ <div>
+ <table>
+ <tr>
+ <td>
+ <fieldset>
+ <legend><%= l(:label_related_issues) %></legend>
+ <label>
+ <%= check_box_tag "draw_rels", params["draw_rels"], true %>
+ <% rels = [IssueRelation::TYPE_BLOCKS, IssueRelation::TYPE_PRECEDES] %>
+ <% rels.each do |rel| %>
+ <% color = Redmine::Helpers::Gantt::DRAW_TYPES[rel][:color] %>
+ <%= content_tag(:span, '&nbsp;&nbsp;&nbsp;'.html_safe,
+ :style => "background-color: #{color}") %>
+ <%= l(IssueRelation::TYPES[rel][:name]) %>
+ <% end %>
+ </label>
+ </fieldset>
+ </td>
+ <td>
+ <fieldset>
+ <legend><%= l(:label_gantt_progress_line) %></legend>
+ <label>
+ <%= check_box_tag "draw_progress_line", params[:draw_progress_line], false %>
+ <%= l(:label_display) %>
+ </label>
+ </fieldset>
+ </td>
+ </tr>
+ </table>
+ </div>
+</fieldset>
<p class="contextual">
<%= gantt_zoom_link(@gantt, :in) %>
@@ -229,7 +262,7 @@
style += "width:10px;"
style += "border-left: 1px dashed red;"
%>
- <%= content_tag(:div, '&nbsp;'.html_safe, :style => style) %>
+ <%= content_tag(:div, '&nbsp;'.html_safe, :style => style, :id => 'today_line') %>
<% end %>
<%
style = ""
@@ -279,4 +312,8 @@
var issue_relation_type = <%= raw Redmine::Helpers::Gantt::DRAW_TYPES.to_json %>;
$(document).ready(drawGanttHandler);
$(window).resize(drawGanttHandler);
+ $(function() {
+ $("#draw_rels").change(drawGanttHandler);
+ $("#draw_progress_line").change(drawGanttHandler);
+ });
<% end %>