@@ -302,7 +302,7 class ProjectsController < ApplicationController | |||
|
302 | 302 | @year ||= Date.today.year |
|
303 | 303 | @month ||= Date.today.month |
|
304 | 304 | @calendar = Redmine::Helpers::Calendar.new(Date.civil(@year, @month, 1), current_language, :month) |
|
305 | @with_subprojects = params[:with_subprojects].nil? ? true : (params[:with_subprojects] == '1') | |
|
305 | @with_subprojects = params[:with_subprojects].nil? ? Setting.display_subprojects_issues? : (params[:with_subprojects] == '1') | |
|
306 | 306 | events = [] |
|
307 | 307 | @project.issues_with_subprojects(@with_subprojects) do |
|
308 | 308 | events += Issue.find(:all, |
@@ -345,7 +345,7 class ProjectsController < ApplicationController | |||
|
345 | 345 | |
|
346 | 346 | @date_from = Date.civil(@year_from, @month_from, 1) |
|
347 | 347 | @date_to = (@date_from >> @months) - 1 |
|
348 | @with_subprojects = params[:with_subprojects].nil? ? true : (params[:with_subprojects] == '1') | |
|
348 | @with_subprojects = params[:with_subprojects].nil? ? Setting.display_subprojects_issues? : (params[:with_subprojects] == '1') | |
|
349 | 349 | |
|
350 | 350 | @events = [] |
|
351 | 351 | @project.issues_with_subprojects(@with_subprojects) do |
@@ -261,12 +261,19 class Query < ActiveRecord::Base | |||
|
261 | 261 | clause = '' |
|
262 | 262 | if project && !@project.active_children.empty? |
|
263 | 263 | ids = [project.id] |
|
264 |
if has_filter?("subproject_id") |
|
|
265 | # include the selected subprojects | |
|
266 | ids += values_for("subproject_id").each(&:to_i) | |
|
267 | else | |
|
268 | # include all the subprojects unless 'none' is selected | |
|
269 | ids += project.active_children.collect{|p| p.id} unless has_filter?("subproject_id") && operator_for("subproject_id") == "!*" | |
|
264 | if has_filter?("subproject_id") | |
|
265 | case operator_for("subproject_id") | |
|
266 | when '=' | |
|
267 | # include the selected subprojects | |
|
268 | ids += values_for("subproject_id").each(&:to_i) | |
|
269 | when '!*' | |
|
270 | # main project only | |
|
271 | else | |
|
272 | # all subprojects | |
|
273 | ids += project.active_children.collect{|p| p.id} | |
|
274 | end | |
|
275 | elsif Setting.display_subprojects_issues? | |
|
276 | ids += project.active_children.collect{|p| p.id} | |
|
270 | 277 | end |
|
271 | 278 | clause << "#{Issue.table_name}.project_id IN (%s)" % ids.join(',') |
|
272 | 279 | elsif project |
@@ -4,6 +4,9 | |||
|
4 | 4 | <p><label><%= l(:setting_cross_project_issue_relations) %></label> |
|
5 | 5 | <%= check_box_tag 'settings[cross_project_issue_relations]', 1, Setting.cross_project_issue_relations? %><%= hidden_field_tag 'settings[cross_project_issue_relations]', 0 %></p> |
|
6 | 6 | |
|
7 | <p><label><%= l(:setting_display_subprojects_issues) %></label> | |
|
8 | <%= check_box_tag 'settings[display_subprojects_issues]', 1, Setting.display_subprojects_issues? %><%= hidden_field_tag 'settings[display_subprojects_issues]', 0 %></p> | |
|
9 | ||
|
7 | 10 | <p><label><%= l(:setting_issues_export_limit) %></label> |
|
8 | 11 | <%= text_field_tag 'settings[issues_export_limit]', Setting.issues_export_limit, :size => 6 %></p> |
|
9 | 12 | </div> |
@@ -101,6 +101,8 issue_list_default_columns: | |||
|
101 | 101 | - subject |
|
102 | 102 | - assigned_to |
|
103 | 103 | - updated_on |
|
104 | display_subprojects_issues: | |
|
105 | default: 1 | |
|
104 | 106 | # encodings used to convert repository files content to UTF-8 |
|
105 | 107 | # multiple values accepted, comma separated |
|
106 | 108 | repositories_encodings: |
@@ -612,3 +612,4 label_chronological_order: In chronological order | |||
|
612 | 612 | field_comments_sorting: Afficher les commentaires |
|
613 | 613 | label_reverse_chronological_order: In reverse chronological order |
|
614 | 614 | label_preferences: Preferences |
|
615 | setting_display_subprojects_issues: Display subprojects issues on main projects by default |
@@ -612,3 +612,4 label_chronological_order: In chronological order | |||
|
612 | 612 | field_comments_sorting: Afficher les commentaires |
|
613 | 613 | label_reverse_chronological_order: In reverse chronological order |
|
614 | 614 | label_preferences: Preferences |
|
615 | setting_display_subprojects_issues: Display subprojects issues on main projects by default |
@@ -613,3 +613,4 label_chronological_order: In chronological order | |||
|
613 | 613 | field_comments_sorting: Afficher les commentaires |
|
614 | 614 | label_reverse_chronological_order: In reverse chronological order |
|
615 | 615 | label_preferences: Preferences |
|
616 | setting_display_subprojects_issues: Display subprojects issues on main projects by default |
@@ -208,6 +208,7 setting_protocol: Protocol | |||
|
208 | 208 | setting_per_page_options: Objects per page options |
|
209 | 209 | setting_user_format: Users display format |
|
210 | 210 | setting_activity_days_default: Days displayed on project activity |
|
211 | setting_display_subprojects_issues: Display subprojects issues on main projects by default | |
|
211 | 212 | |
|
212 | 213 | project_module_issue_tracking: Issue tracking |
|
213 | 214 | project_module_time_tracking: Time tracking |
@@ -615,3 +615,4 label_chronological_order: In chronological order | |||
|
615 | 615 | field_comments_sorting: Afficher les commentaires |
|
616 | 616 | label_reverse_chronological_order: In reverse chronological order |
|
617 | 617 | label_preferences: Preferences |
|
618 | setting_display_subprojects_issues: Display subprojects issues on main projects by default |
@@ -616,3 +616,4 label_chronological_order: In chronological order | |||
|
616 | 616 | field_comments_sorting: Afficher les commentaires |
|
617 | 617 | label_reverse_chronological_order: In reverse chronological order |
|
618 | 618 | label_preferences: Preferences |
|
619 | setting_display_subprojects_issues: Display subprojects issues on main projects by default |
@@ -208,6 +208,7 setting_protocol: Protocole | |||
|
208 | 208 | setting_per_page_options: Options d'objets affichés par page |
|
209 | 209 | setting_user_format: Format d'affichage des utilisateurs |
|
210 | 210 | setting_activity_days_default: Nombre de jours affichés sur l'activité des projets |
|
211 | setting_display_subprojects_issues: Afficher par défaut les demandes des sous-projets sur les projets principaux | |
|
211 | 212 | |
|
212 | 213 | project_module_issue_tracking: Suivi des demandes |
|
213 | 214 | project_module_time_tracking: Suivi du temps passé |
@@ -612,3 +612,4 label_chronological_order: In chronological order | |||
|
612 | 612 | field_comments_sorting: Afficher les commentaires |
|
613 | 613 | label_reverse_chronological_order: In reverse chronological order |
|
614 | 614 | label_preferences: Preferences |
|
615 | setting_display_subprojects_issues: Display subprojects issues on main projects by default |
@@ -612,3 +612,4 label_chronological_order: In chronological order | |||
|
612 | 612 | field_comments_sorting: Afficher les commentaires |
|
613 | 613 | label_reverse_chronological_order: In reverse chronological order |
|
614 | 614 | label_preferences: Preferences |
|
615 | setting_display_subprojects_issues: Display subprojects issues on main projects by default |
@@ -613,3 +613,4 label_chronological_order: In chronological order | |||
|
613 | 613 | field_comments_sorting: Afficher les commentaires |
|
614 | 614 | label_reverse_chronological_order: In reverse chronological order |
|
615 | 615 | label_preferences: Preferences |
|
616 | setting_display_subprojects_issues: Display subprojects issues on main projects by default |
@@ -612,3 +612,4 label_chronological_order: In chronological order | |||
|
612 | 612 | field_comments_sorting: Afficher les commentaires |
|
613 | 613 | label_reverse_chronological_order: In reverse chronological order |
|
614 | 614 | label_preferences: Preferences |
|
615 | setting_display_subprojects_issues: Display subprojects issues on main projects by default |
@@ -613,3 +613,4 label_chronological_order: In chronological order | |||
|
613 | 613 | field_comments_sorting: Afficher les commentaires |
|
614 | 614 | label_reverse_chronological_order: In reverse chronological order |
|
615 | 615 | label_preferences: Preferences |
|
616 | setting_display_subprojects_issues: Display subprojects issues on main projects by default |
@@ -613,3 +613,4 label_chronological_order: In chronological order | |||
|
613 | 613 | field_comments_sorting: Afficher les commentaires |
|
614 | 614 | label_reverse_chronological_order: In reverse chronological order |
|
615 | 615 | label_preferences: Preferences |
|
616 | setting_display_subprojects_issues: Display subprojects issues on main projects by default |
@@ -612,3 +612,4 label_chronological_order: In chronological order | |||
|
612 | 612 | field_comments_sorting: Afficher les commentaires |
|
613 | 613 | label_reverse_chronological_order: In reverse chronological order |
|
614 | 614 | label_preferences: Preferences |
|
615 | setting_display_subprojects_issues: Display subprojects issues on main projects by default |
@@ -612,3 +612,4 label_chronological_order: In chronological order | |||
|
612 | 612 | field_comments_sorting: Afficher les commentaires |
|
613 | 613 | label_reverse_chronological_order: In reverse chronological order |
|
614 | 614 | label_preferences: Preferences |
|
615 | setting_display_subprojects_issues: Display subprojects issues on main projects by default |
@@ -612,3 +612,4 label_chronological_order: In chronological order | |||
|
612 | 612 | field_comments_sorting: Afficher les commentaires |
|
613 | 613 | label_reverse_chronological_order: In reverse chronological order |
|
614 | 614 | label_preferences: Preferences |
|
615 | setting_display_subprojects_issues: Display subprojects issues on main projects by default |
@@ -612,3 +612,4 label_chronological_order: In chronological order | |||
|
612 | 612 | field_comments_sorting: Afficher les commentaires |
|
613 | 613 | label_reverse_chronological_order: In reverse chronological order |
|
614 | 614 | label_preferences: Preferences |
|
615 | setting_display_subprojects_issues: Display subprojects issues on main projects by default |
@@ -616,3 +616,4 label_chronological_order: In chronological order | |||
|
616 | 616 | field_comments_sorting: Afficher les commentaires |
|
617 | 617 | label_reverse_chronological_order: In reverse chronological order |
|
618 | 618 | label_preferences: Preferences |
|
619 | setting_display_subprojects_issues: Display subprojects issues on main projects by default |
@@ -613,3 +613,4 label_chronological_order: In chronological order | |||
|
613 | 613 | field_comments_sorting: Afficher les commentaires |
|
614 | 614 | label_reverse_chronological_order: In reverse chronological order |
|
615 | 615 | label_preferences: Preferences |
|
616 | setting_display_subprojects_issues: Display subprojects issues on main projects by default |
@@ -613,3 +613,4 label_chronological_order: In chronological order | |||
|
613 | 613 | field_comments_sorting: Afficher les commentaires |
|
614 | 614 | label_reverse_chronological_order: In reverse chronological order |
|
615 | 615 | label_preferences: Preferences |
|
616 | setting_display_subprojects_issues: Display subprojects issues on main projects by default |
@@ -614,3 +614,4 label_chronological_order: In chronological order | |||
|
614 | 614 | field_comments_sorting: Afficher les commentaires |
|
615 | 615 | label_reverse_chronological_order: In reverse chronological order |
|
616 | 616 | label_preferences: Preferences |
|
617 | setting_display_subprojects_issues: Display subprojects issues on main projects by default |
@@ -613,3 +613,4 label_chronological_order: In chronological order | |||
|
613 | 613 | field_comments_sorting: Afficher les commentaires |
|
614 | 614 | label_reverse_chronological_order: In reverse chronological order |
|
615 | 615 | label_preferences: Preferences |
|
616 | setting_display_subprojects_issues: Display subprojects issues on main projects by default |
@@ -613,3 +613,4 label_chronological_order: In chronological order | |||
|
613 | 613 | field_comments_sorting: Afficher les commentaires |
|
614 | 614 | label_reverse_chronological_order: In reverse chronological order |
|
615 | 615 | label_preferences: Preferences |
|
616 | setting_display_subprojects_issues: Display subprojects issues on main projects by default |
General Comments 0
You need to be logged in to leave comments.
Login now