Project

General

Profile

Patch #29406 » reports_controller.rb.patch

Pavel Rosický, 2018-08-18 15:08

View differences:

reports_controller.rb (working copy)
21 21

  
22 22
  def issue_report
23 23
    @trackers = @project.rolled_up_trackers(false).visible
24
    @versions = @project.shared_versions.sort
25
    @priorities = IssuePriority.all.reverse
24
    @versions = @project.shared_versions.sorted
25
    @priorities = IssuePriority.sorted
26 26
    @categories = @project.issue_categories
27
    @assignees = (Setting.issue_group_assignment? ? @project.principals : @project.users).sort
28
    @authors = @project.users.sort
27
    @assignees = (Setting.issue_group_assignment? ? @project.principals : @project.users).sorted
28
    @authors = @project.users.sorted
29 29
    @subprojects = @project.descendants.visible
30 30

  
31 31
    @issues_by_tracker = Issue.by_tracker(@project)
......
48 48
      @report_title = l(:field_tracker)
49 49
    when "version"
50 50
      @field = "fixed_version_id"
51
      @rows = @project.shared_versions.sort
51
      @rows = @project.shared_versions.sorted
52 52
      @data = Issue.by_version(@project)
53 53
      @report_title = l(:field_version)
54 54
    when "priority"
55 55
      @field = "priority_id"
56
      @rows = IssuePriority.all.reverse
56
      @rows = IssuePriority.sorted
57 57
      @data = Issue.by_priority(@project)
58 58
      @report_title = l(:field_priority)
59 59
    when "category"
......
63 63
      @report_title = l(:field_category)
64 64
    when "assigned_to"
65 65
      @field = "assigned_to_id"
66
      @rows = (Setting.issue_group_assignment? ? @project.principals : @project.users).sort
66
      @rows = (Setting.issue_group_assignment? ? @project.principals : @project.users).sorted
67 67
      @data = Issue.by_assigned_to(@project)
68 68
      @report_title = l(:field_assigned_to)
69 69
    when "author"
70 70
      @field = "author_id"
71
      @rows = @project.users.sort
71
      @rows = @project.users.sorted
72 72
      @data = Issue.by_author(@project)
73 73
      @report_title = l(:field_author)
74 74
    when "subproject"
(4-4/6)