]> source.dussan.org Git - redmine.git/commitdiff
Display non working days on gantt image according to settings (#2161).
authorJean-Philippe Lang <jp_lang@yahoo.fr>
Mon, 29 Oct 2012 10:23:59 +0000 (10:23 +0000)
committerJean-Philippe Lang <jp_lang@yahoo.fr>
Mon, 29 Oct 2012 10:23:59 +0000 (10:23 +0000)
git-svn-id: svn+ssh://rubyforge.org/var/svn/redmine/trunk@10751 e93f8b46-1217-0410-a6f0-8f06a7374b81

lib/redmine/helpers/gantt.rb

index 27faf0a9687c775fbce16ad274716548334c95e6..ebc9610f08dd4e66a6fdf210f04fc8e69285f784 100644 (file)
@@ -457,7 +457,7 @@ module Redmine
           wday = @date_from.cwday
           (date_to - @date_from + 1).to_i.times do
             width =  zoom
-            gc.fill(wday == 6 || wday == 7 ? '#eee' : 'white')
+            gc.fill(non_working_week_days.include?(wday) ? '#eee' : 'white')
             gc.stroke('#ddd')
             gc.stroke_width(1)
             gc.rectangle(left, 2 * header_height, left + width, 2 * header_height + g_height - 1)