filters replaced on issues list

git-svn-id: http://redmine.rubyforge.org/svn/branches/work@80 e93f8b46-1217-0410-a6f0-8f06a7374b81
This commit is contained in:
Jean-Philippe Lang committed 2006-12-10 16:14:02 +00:00
1 parent da91e5e95a
commit 638ce18d4a
6 files changed
+55 -16

No files matched your search

+2 -2
View File
@@ -1,7 +1,7 @@
class Query < ActiveRecord::Base
serialize :filters
validates_presence_of :name
validates_presence_of :name, :on => :save
@@operators = { "=" => "Egal",
"!" => "Different",
@@ -56,7 +56,7 @@ class Query < ActiveRecord::Base
def add_filter(field, operator, values)
# values must be an array
return unless values and values.is_a? Array
return unless values and values.is_a? Array # and !values.first.empty?
# check if field is defined as an available filter
if @@available_filters.has_key? field
filter_options = @@available_filters[field]