Revision 442:753f1380d6bc vendor/plugins/acts_as_customizable/lib/.svn/text-base

View differences:

vendor/plugins/acts_as_customizable/lib/.svn/text-base/acts_as_customizable.rb.svn-base
1
# redMine - project management software
2
# Copyright (C) 2006-2008  Jean-Philippe Lang
1
# Redmine - project management software
2
# Copyright (C) 2006-2011  Jean-Philippe Lang
3 3
#
4 4
# This program is free software; you can redistribute it and/or
5 5
# modify it under the terms of the GNU General Public License
......
75 75
        end
76 76
        
77 77
        def custom_field_values
78
          @custom_field_values ||= available_custom_fields.collect { |x| custom_values.detect { |v| v.custom_field == x } || custom_values.build(:custom_field => x, :value => nil) }
78
          @custom_field_values ||= available_custom_fields.collect { |x| custom_values.detect { |v| v.custom_field == x } || custom_values.build(:customized => self, :custom_field => x, :value => nil) }
79 79
        end
80 80
        
81 81
        def visible_custom_field_values

Also available in: Unified diff