##// END OF EJS Templates
Make sure that we don't set the done ratio to a value > 100% (#15870)....
Jean-Philippe Lang -
r12394:6f1cda4852fd
parent child
Show More
@@ -1364,6 +1364,7 class Issue < ActiveRecord::Base
1364 "* (CASE WHEN is_closed = #{connection.quoted_true} THEN 100 ELSE COALESCE(done_ratio, 0) END)").to_f
1364 "* (CASE WHEN is_closed = #{connection.quoted_true} THEN 100 ELSE COALESCE(done_ratio, 0) END)").to_f
1365 progress = done / (average * leaves_count)
1365 progress = done / (average * leaves_count)
1366 p.done_ratio = progress.round
1366 p.done_ratio = progress.round
1367 p.done_ratio = 100 if p.done_ratio > 100
1367 end
1368 end
1368 end
1369 end
1369
1370
General Comments 0
You need to be logged in to leave comments. Login now