Feature #14654 » 14654_v2.patch
| app/views/gantts/show.html.erb | ||
|---|---|---|
| 61 | 61 |
</p> |
| 62 | 62 | |
| 63 | 63 |
<p class="buttons"> |
| 64 |
<%= number_field_tag 'months', @gantt.months, :min => 1, :max => 24, :autocomplete => false %>
|
|
| 64 |
<%= number_field_tag 'months', @gantt.months, :min => 1, :max => [6, Setting.gantt_months_limit.to_i].max, :autocomplete => false %>
|
|
| 65 | 65 |
<%= l(:label_months_from) %> |
| 66 | 66 |
<%= select_month(@gantt.month_from, :prefix => "month", :discard_type => true) %> |
| 67 | 67 |
<%= select_year(@gantt.year_from, :prefix => "year", :discard_type => true) %> |
| app/views/settings/_issues.html.erb | ||
|---|---|---|
| 22 | 22 |
<p><%= setting_text_field :issues_export_limit, :size => 6 %></p> |
| 23 | 23 | |
| 24 | 24 |
<p><%= setting_text_field :gantt_items_limit, :size => 6 %></p> |
| 25 | ||
| 26 |
<p><%= setting_text_field :gantt_months_limit, :size => 6 %></p> |
|
| 25 | 27 |
</div> |
| 26 | 28 | |
| 27 | 29 |
<fieldset class="box"> |
| config/locales/en.yml | ||
|---|---|---|
| 447 | 447 |
setting_commit_logtime_enabled: Enable time logging |
| 448 | 448 |
setting_commit_logtime_activity_id: Activity for logged time |
| 449 | 449 |
setting_gantt_items_limit: Maximum number of items displayed on the gantt chart |
| 450 |
setting_gantt_months_limit: Maximum number of months displayed on the gantt chart |
|
| 450 | 451 |
setting_issue_group_assignment: Allow issue assignment to groups |
| 451 | 452 |
setting_default_issue_start_date_to_creation_date: Use current date as start date for new issues |
| 452 | 453 |
setting_commit_cross_project_ref: Allow issues of all the other projects to be referenced and fixed |
| config/settings.yml | ||
|---|---|---|
| 105 | 105 |
gantt_items_limit: |
| 106 | 106 |
format: int |
| 107 | 107 |
default: 500 |
| 108 |
gantt_months_limit: |
|
| 109 |
format: int |
|
| 110 |
default: 24 |
|
| 108 | 111 |
# Maximum size of files that can be displayed |
| 109 | 112 |
# inline through the file viewer (in KB) |
| 110 | 113 |
file_max_size_displayed: |
| lib/redmine/helpers/gantt.rb | ||
|---|---|---|
| 67 | 67 |
zoom = (options[:zoom] || User.current.pref[:gantt_zoom]).to_i |
| 68 | 68 |
@zoom = (zoom > 0 && zoom < 5) ? zoom : 2 |
| 69 | 69 |
months = (options[:months] || User.current.pref[:gantt_months]).to_i |
| 70 |
@months = (months > 0 && months < 25) ? months : 6
|
|
| 70 |
@months = (months > 0 && months < [6, Setting.gantt_months_limit.to_i].max + 1) ? months : 6
|
|
| 71 | 71 |
# Save gantt parameters as user preference (zoom and months count) |
| 72 | 72 |
if (User.current.logged? && (@zoom != User.current.pref[:gantt_zoom] || |
| 73 | 73 |
@months != User.current.pref[:gantt_months])) |
- « Previous
- 1
- …
- 3
- 4
- 5
- Next »