@@ -22,7 +22,7 @@ class CustomField < ActiveRecord::Base
22
22
include Redmine ::SubclassFactory
23
23
24
24
has_many :enumerations ,
25
- lambda { order ( :position ) } ,
25
+ lambda { order ( :position ) } ,
26
26
:class_name => 'CustomFieldEnumeration' ,
27
27
:dependent => :delete_all
28
28
has_many :custom_values , :dependent => :delete_all
@@ -35,7 +35,7 @@ class CustomField < ActiveRecord::Base
35
35
validates_uniqueness_of :name , :scope => :type
36
36
validates_length_of :name , :maximum => 30
37
37
validates_length_of :regexp , maximum : 255
38
- validates_inclusion_of :field_format , :in => Proc . new { Redmine ::FieldFormat . available_formats }
38
+ validates_inclusion_of :field_format , :in => Proc . new { Redmine ::FieldFormat . available_formats }
39
39
validate :validate_custom_field
40
40
41
41
before_validation :set_searchable
@@ -49,7 +49,7 @@ class CustomField < ActiveRecord::Base
49
49
end
50
50
end
51
51
52
- scope :sorted , lambda { order ( :position ) }
52
+ scope :sorted , lambda { order ( :position ) }
53
53
scope :visible , lambda { |*args |
54
54
user = args . shift || User . current
55
55
if user . admin?
0 commit comments