Fixes Workflow.count_by_tracker_and_role.
git-svn-id: http://redmine.rubyforge.org/svn/trunk@1917 e93f8b46-1217-0410-a6f0-8f06a7374b81
This commit is contained in:
parent
3544d6398a
commit
b0e62e37ae
|
@ -32,7 +32,7 @@ class Workflow < ActiveRecord::Base
|
||||||
trackers.each do |tracker|
|
trackers.each do |tracker|
|
||||||
t = []
|
t = []
|
||||||
roles.each do |role|
|
roles.each do |role|
|
||||||
row = counts.detect {|c| c['role_id'] == role.id.to_s && c['tracker_id'] = tracker.id.to_s}
|
row = counts.detect {|c| c['role_id'] == role.id.to_s && c['tracker_id'] == tracker.id.to_s}
|
||||||
t << [role, (row.nil? ? 0 : row['c'].to_i)]
|
t << [role, (row.nil? ? 0 : row['c'].to_i)]
|
||||||
end
|
end
|
||||||
result << [tracker, t]
|
result << [tracker, t]
|
||||||
|
|
Loading…
Reference in New Issue