ransack 1.8.3 → 2.3.0
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +5 -5
- data/.gitignore +3 -0
- data/.travis.yml +26 -63
- data/CHANGELOG.md +187 -24
- data/CONTRIBUTING.md +9 -0
- data/Gemfile +5 -20
- data/README.md +163 -40
- data/Rakefile +1 -22
- data/lib/ransack/adapters/active_record/base.rb +11 -2
- data/lib/ransack/adapters/active_record/context.rb +178 -168
- data/lib/ransack/adapters/active_record/ransack/constants.rb +6 -3
- data/lib/ransack/adapters/active_record/ransack/context.rb +10 -16
- data/lib/ransack/adapters/active_record/ransack/nodes/condition.rb +3 -3
- data/lib/ransack/adapters/active_record/ransack/translate.rb +1 -5
- data/lib/ransack/adapters/active_record/ransack/visitor.rb +23 -0
- data/lib/ransack/adapters/active_record.rb +0 -9
- data/lib/ransack/adapters.rb +2 -0
- data/lib/ransack/configuration.rb +30 -4
- data/lib/ransack/constants.rb +4 -1
- data/lib/ransack/context.rb +29 -24
- data/lib/ransack/helpers/form_builder.rb +15 -3
- data/lib/ransack/helpers/form_helper.rb +8 -3
- data/lib/ransack/locale/ar.yml +70 -0
- data/lib/ransack/locale/az.yml +70 -0
- data/lib/ransack/locale/bg.yml +70 -0
- data/lib/ransack/locale/ca.yml +70 -0
- data/lib/ransack/locale/el.yml +70 -0
- data/lib/ransack/locale/es.yml +22 -22
- data/lib/ransack/locale/fa.yml +70 -0
- data/lib/ransack/locale/fi.yml +71 -0
- data/lib/ransack/locale/it.yml +70 -0
- data/lib/ransack/locale/nl.yml +4 -4
- data/lib/ransack/locale/ru.yml +70 -0
- data/lib/ransack/locale/tr.yml +70 -0
- data/lib/ransack/locale/zh-CN.yml +12 -12
- data/lib/ransack/nodes/attribute.rb +1 -1
- data/lib/ransack/nodes/grouping.rb +2 -7
- data/lib/ransack/nodes/value.rb +74 -68
- data/lib/ransack/predicate.rb +11 -19
- data/lib/ransack/search.rb +1 -1
- data/lib/ransack/translate.rb +115 -115
- data/lib/ransack/version.rb +1 -1
- data/lib/ransack/visitor.rb +1 -12
- data/lib/ransack.rb +5 -2
- data/logo/ransack-h.png +0 -0
- data/logo/ransack-h.svg +34 -0
- data/logo/ransack-v.png +0 -0
- data/logo/ransack-v.svg +34 -0
- data/logo/ransack.png +0 -0
- data/logo/ransack.svg +21 -0
- data/polyamorous/lib/polyamorous/activerecord_5.0_ruby_2/join_association.rb +2 -0
- data/polyamorous/lib/polyamorous/activerecord_5.0_ruby_2/join_dependency.rb +2 -0
- data/polyamorous/lib/polyamorous/activerecord_5.1_ruby_2/join_association.rb +31 -0
- data/polyamorous/lib/polyamorous/activerecord_5.1_ruby_2/join_dependency.rb +112 -0
- data/polyamorous/lib/polyamorous/activerecord_5.2.0_ruby_2/join_association.rb +31 -0
- data/polyamorous/lib/polyamorous/activerecord_5.2.0_ruby_2/join_dependency.rb +112 -0
- data/polyamorous/lib/polyamorous/activerecord_5.2.0_ruby_2/reflection.rb +12 -0
- data/polyamorous/lib/polyamorous/activerecord_5.2.1_ruby_2/join_association.rb +22 -0
- data/polyamorous/lib/polyamorous/activerecord_5.2.1_ruby_2/join_dependency.rb +81 -0
- data/polyamorous/lib/polyamorous/activerecord_5.2.1_ruby_2/reflection.rb +2 -0
- data/polyamorous/lib/polyamorous/activerecord_6.0_ruby_2/join_association.rb +2 -0
- data/polyamorous/lib/polyamorous/activerecord_6.0_ruby_2/join_dependency.rb +81 -0
- data/polyamorous/lib/polyamorous/activerecord_6.0_ruby_2/reflection.rb +2 -0
- data/polyamorous/lib/polyamorous/activerecord_6.1_ruby_2/join_association.rb +2 -0
- data/polyamorous/lib/polyamorous/activerecord_6.1_ruby_2/join_dependency.rb +2 -0
- data/polyamorous/lib/polyamorous/activerecord_6.1_ruby_2/reflection.rb +2 -0
- data/polyamorous/lib/polyamorous/join.rb +70 -0
- data/polyamorous/lib/polyamorous/swapping_reflection_class.rb +11 -0
- data/polyamorous/lib/polyamorous/tree_node.rb +7 -0
- data/polyamorous/lib/polyamorous/version.rb +3 -0
- data/polyamorous/lib/polyamorous.rb +29 -0
- data/polyamorous/polyamorous.gemspec +35 -0
- data/ransack.gemspec +9 -10
- data/spec/helpers/polyamorous_helper.rb +28 -0
- data/spec/ransack/adapters/active_record/base_spec.rb +74 -0
- data/spec/ransack/adapters/active_record/context_spec.rb +44 -6
- data/spec/ransack/configuration_spec.rb +17 -2
- data/spec/ransack/helpers/form_builder_spec.rb +3 -15
- data/spec/ransack/helpers/form_helper_spec.rb +88 -151
- data/spec/ransack/join_association_spec.rb +28 -0
- data/spec/ransack/join_dependency_spec.rb +97 -0
- data/spec/ransack/join_spec.rb +19 -0
- data/spec/ransack/predicate_spec.rb +16 -2
- data/spec/ransack/search_spec.rb +32 -3
- data/spec/spec_helper.rb +5 -0
- data/spec/support/schema.rb +45 -21
- metadata +81 -67
- data/lib/ransack/adapters/active_record/3.0/compat.rb +0 -179
- data/lib/ransack/adapters/active_record/3.0/context.rb +0 -203
- data/lib/ransack/adapters/active_record/3.1/context.rb +0 -212
- data/lib/ransack/adapters/active_record/3.2/context.rb +0 -44
- data/lib/ransack/adapters/active_record/compat.rb +0 -14
- data/lib/ransack/adapters/mongoid/3.2/.gitkeep +0 -0
- data/lib/ransack/adapters/mongoid/attributes/attribute.rb +0 -37
- data/lib/ransack/adapters/mongoid/attributes/order_predications.rb +0 -17
- data/lib/ransack/adapters/mongoid/attributes/predications.rb +0 -141
- data/lib/ransack/adapters/mongoid/base.rb +0 -134
- data/lib/ransack/adapters/mongoid/context.rb +0 -212
- data/lib/ransack/adapters/mongoid/inquiry_hash.rb +0 -23
- data/lib/ransack/adapters/mongoid/ransack/constants.rb +0 -88
- data/lib/ransack/adapters/mongoid/ransack/context.rb +0 -60
- data/lib/ransack/adapters/mongoid/ransack/nodes/condition.rb +0 -27
- data/lib/ransack/adapters/mongoid/ransack/translate.rb +0 -13
- data/lib/ransack/adapters/mongoid/ransack/visitor.rb +0 -24
- data/lib/ransack/adapters/mongoid/table.rb +0 -35
- data/lib/ransack/adapters/mongoid.rb +0 -15
- data/spec/mongoid/adapters/mongoid/base_spec.rb +0 -314
- data/spec/mongoid/adapters/mongoid/context_spec.rb +0 -56
- data/spec/mongoid/configuration_spec.rb +0 -162
- data/spec/mongoid/dependencies_spec.rb +0 -8
- data/spec/mongoid/helpers/ransack_helper.rb +0 -11
- data/spec/mongoid/nodes/condition_spec.rb +0 -49
- data/spec/mongoid/nodes/grouping_spec.rb +0 -13
- data/spec/mongoid/predicate_spec.rb +0 -155
- data/spec/mongoid/search_spec.rb +0 -445
- data/spec/mongoid/support/mongoid.yml +0 -11
- data/spec/mongoid/support/schema.rb +0 -135
- data/spec/mongoid/translate_spec.rb +0 -14
- data/spec/mongoid_spec_helper.rb +0 -63
- data/spec/ransack/dependencies_spec.rb +0 -12
data/lib/ransack/nodes/value.rb
CHANGED
@@ -23,87 +23,93 @@ module Ransack
|
|
23
23
|
end
|
24
24
|
|
25
25
|
def cast(type)
|
26
|
-
|
27
|
-
|
28
|
-
|
29
|
-
|
30
|
-
|
31
|
-
|
32
|
-
|
33
|
-
|
34
|
-
|
35
|
-
|
36
|
-
|
37
|
-
|
38
|
-
|
39
|
-
|
40
|
-
|
41
|
-
|
42
|
-
|
26
|
+
case type
|
27
|
+
when :date
|
28
|
+
cast_to_date(value)
|
29
|
+
when :datetime, :timestamp, :time
|
30
|
+
cast_to_time(value)
|
31
|
+
when :boolean
|
32
|
+
cast_to_boolean(value)
|
33
|
+
when :integer
|
34
|
+
cast_to_integer(value)
|
35
|
+
when :float
|
36
|
+
cast_to_float(value)
|
37
|
+
when :decimal
|
38
|
+
cast_to_decimal(value)
|
39
|
+
when :money
|
40
|
+
cast_to_money(value)
|
41
|
+
else
|
42
|
+
cast_to_string(value)
|
43
|
+
end
|
44
|
+
end
|
43
45
|
|
44
|
-
|
45
|
-
|
46
|
-
|
47
|
-
|
48
|
-
|
49
|
-
|
50
|
-
|
51
|
-
|
52
|
-
|
53
|
-
|
46
|
+
def cast_to_date(val)
|
47
|
+
if val.respond_to?(:to_date)
|
48
|
+
val.to_date rescue nil
|
49
|
+
else
|
50
|
+
y, m, d = *[val].flatten
|
51
|
+
m ||= 1
|
52
|
+
d ||= 1
|
53
|
+
Date.new(y,m,d) rescue nil
|
54
|
+
end
|
55
|
+
end
|
54
56
|
|
55
|
-
|
56
|
-
|
57
|
-
|
58
|
-
|
59
|
-
|
60
|
-
|
61
|
-
|
62
|
-
|
63
|
-
|
64
|
-
|
57
|
+
def cast_to_time(val)
|
58
|
+
if val.is_a?(Array)
|
59
|
+
Time.zone.local(*val) rescue nil
|
60
|
+
else
|
61
|
+
unless val.acts_like?(:time)
|
62
|
+
val = val.is_a?(String) ? Time.zone.parse(val) : val.to_time rescue val
|
63
|
+
end
|
64
|
+
val.in_time_zone rescue nil
|
65
|
+
end
|
66
|
+
end
|
65
67
|
|
66
|
-
|
67
|
-
|
68
|
-
|
69
|
-
|
70
|
-
|
71
|
-
|
72
|
-
|
73
|
-
|
74
|
-
|
68
|
+
def cast_to_boolean(val)
|
69
|
+
if Constants::TRUE_VALUES.include?(val)
|
70
|
+
true
|
71
|
+
elsif Constants::FALSE_VALUES.include?(val)
|
72
|
+
false
|
73
|
+
else
|
74
|
+
nil
|
75
|
+
end
|
76
|
+
end
|
75
77
|
|
76
|
-
|
77
|
-
|
78
|
-
|
78
|
+
def cast_to_string(val)
|
79
|
+
val.respond_to?(:to_s) ? val.to_s : String.new(val)
|
80
|
+
end
|
79
81
|
|
80
|
-
|
81
|
-
|
82
|
-
|
82
|
+
def cast_to_integer(val)
|
83
|
+
val.blank? ? nil : val.to_i
|
84
|
+
end
|
83
85
|
|
84
|
-
|
85
|
-
|
86
|
-
|
86
|
+
def cast_to_float(val)
|
87
|
+
val.blank? ? nil : val.to_f
|
88
|
+
end
|
87
89
|
|
88
|
-
|
89
|
-
|
90
|
-
|
91
|
-
|
92
|
-
|
93
|
-
|
94
|
-
|
95
|
-
|
96
|
-
|
97
|
-
end
|
90
|
+
def cast_to_decimal(val)
|
91
|
+
if val.blank?
|
92
|
+
nil
|
93
|
+
elsif val.class == BigDecimal
|
94
|
+
val
|
95
|
+
elsif val.respond_to?(:to_d)
|
96
|
+
val.to_d
|
97
|
+
else
|
98
|
+
val.to_s.to_d
|
98
99
|
end
|
100
|
+
end
|
101
|
+
|
102
|
+
def cast_to_money(val)
|
103
|
+
val.blank? ? nil : val.to_f.to_s
|
104
|
+
end
|
99
105
|
|
100
106
|
def inspect
|
101
107
|
"Value <#{value}>"
|
102
108
|
end
|
103
109
|
|
104
|
-
|
105
|
-
|
106
|
-
|
110
|
+
def array_of_arrays?(val)
|
111
|
+
Array === val && Array === val.first
|
112
|
+
end
|
107
113
|
end
|
108
114
|
end
|
109
115
|
end
|
data/lib/ransack/predicate.rb
CHANGED
@@ -9,34 +9,26 @@ module Ransack
|
|
9
9
|
Ransack.predicates.keys
|
10
10
|
end
|
11
11
|
|
12
|
-
def names_by_decreasing_length
|
13
|
-
names.sort { |a, b| b.length <=> a.length }
|
14
|
-
end
|
15
|
-
|
16
12
|
def named(name)
|
17
13
|
Ransack.predicates[name.to_s]
|
18
14
|
end
|
19
15
|
|
20
16
|
def detect_and_strip_from_string!(str)
|
21
|
-
|
22
|
-
str.sub! /_#{p}$/, ''.freeze
|
23
|
-
p
|
24
|
-
end
|
17
|
+
detect_from_string str, chomp: true
|
25
18
|
end
|
26
19
|
|
27
|
-
def detect_from_string(str)
|
28
|
-
|
29
|
-
end
|
20
|
+
def detect_from_string(str, chomp: false)
|
21
|
+
return unless str
|
30
22
|
|
31
|
-
|
32
|
-
|
33
|
-
|
34
|
-
|
35
|
-
|
23
|
+
Ransack.predicates.sorted_names_with_underscores.each do |predicate, underscored|
|
24
|
+
if str.end_with? underscored
|
25
|
+
str.chomp! underscored if chomp
|
26
|
+
return predicate
|
27
|
+
end
|
28
|
+
end
|
36
29
|
|
37
|
-
|
38
|
-
|
39
|
-
# end
|
30
|
+
nil
|
31
|
+
end
|
40
32
|
|
41
33
|
end
|
42
34
|
|
data/lib/ransack/search.rb
CHANGED
@@ -123,7 +123,7 @@ module Ransack
|
|
123
123
|
private
|
124
124
|
|
125
125
|
def add_scope(key, args)
|
126
|
-
sanitized_args = if Ransack.options[:sanitize_scope_args]
|
126
|
+
sanitized_args = if Ransack.options[:sanitize_scope_args] && !@context.ransackable_scope_skip_sanitize_args?(key, @context.object)
|
127
127
|
sanitized_scope_args(args)
|
128
128
|
else
|
129
129
|
args
|
data/lib/ransack/translate.rb
CHANGED
@@ -6,151 +6,151 @@ I18n.load_path += Dir[
|
|
6
6
|
|
7
7
|
module Ransack
|
8
8
|
module Translate
|
9
|
-
|
10
|
-
|
11
|
-
|
12
|
-
|
13
|
-
def self.predicate(key, options = {})
|
14
|
-
I18n.translate(:"ransack.predicates.#{key}", :default => key.to_s)
|
15
|
-
end
|
16
|
-
|
17
|
-
def self.attribute(key, options = {})
|
18
|
-
unless context = options.delete(:context)
|
19
|
-
raise ArgumentError, "A context is required to translate attributes"
|
9
|
+
class << self
|
10
|
+
def word(key, options = {})
|
11
|
+
I18n.translate(:"ransack.#{key}", default: key.to_s)
|
20
12
|
end
|
21
13
|
|
22
|
-
|
23
|
-
|
24
|
-
base_ancestors = base_class.ancestors.select {
|
25
|
-
|x| x.respond_to?(:model_name)
|
26
|
-
}
|
27
|
-
predicate = Predicate.detect_from_string(original_name)
|
28
|
-
attributes_str = original_name.sub(/_#{predicate}$/, ''.freeze)
|
29
|
-
attribute_names = attributes_str.split(/_and_|_or_/)
|
30
|
-
combinator = attributes_str.match(/_and_/) ? :and : :or
|
31
|
-
defaults = base_ancestors.map do |klass|
|
32
|
-
"ransack.attributes.#{i18n_key(klass)}.#{original_name}".to_sym
|
14
|
+
def predicate(key, options = {})
|
15
|
+
I18n.translate(:"ransack.predicates.#{key}", default: key.to_s)
|
33
16
|
end
|
34
17
|
|
35
|
-
|
36
|
-
|
37
|
-
|
18
|
+
def attribute(key, options = {})
|
19
|
+
unless context = options.delete(:context)
|
20
|
+
raise ArgumentError, "A context is required to translate attributes"
|
21
|
+
end
|
38
22
|
|
39
|
-
|
40
|
-
|
41
|
-
|
23
|
+
original_name = key.to_s
|
24
|
+
base_class = context.klass
|
25
|
+
base_ancestors = base_class.ancestors.select {
|
26
|
+
|x| x.respond_to?(:model_name)
|
27
|
+
}
|
28
|
+
attributes_str = original_name.dup # will be modified by ⬇
|
29
|
+
predicate = Predicate.detect_and_strip_from_string!(attributes_str)
|
30
|
+
attribute_names = attributes_str.split(/_and_|_or_/)
|
31
|
+
combinator = attributes_str =~ /_and_/ ? :and : :or
|
32
|
+
defaults = base_ancestors.map do |klass|
|
33
|
+
"ransack.attributes.#{i18n_key(klass)}.#{original_name}".to_sym
|
34
|
+
end
|
42
35
|
|
43
|
-
|
44
|
-
|
45
|
-
|
46
|
-
else
|
47
|
-
defaults << "%{attributes}".freeze
|
48
|
-
end
|
36
|
+
translated_names = attribute_names.map do |name|
|
37
|
+
attribute_name(context, name, options[:include_associations])
|
38
|
+
end
|
49
39
|
|
50
|
-
|
51
|
-
|
52
|
-
|
53
|
-
end
|
40
|
+
interpolations = {
|
41
|
+
attributes: translated_names.join(" #{Translate.word(combinator)} ")
|
42
|
+
}
|
54
43
|
|
55
|
-
|
56
|
-
|
57
|
-
|
44
|
+
if predicate
|
45
|
+
defaults << "%{attributes} %{predicate}".freeze
|
46
|
+
interpolations[:predicate] = Translate.predicate(predicate)
|
47
|
+
else
|
48
|
+
defaults << "%{attributes}".freeze
|
49
|
+
end
|
50
|
+
|
51
|
+
defaults << options.delete(:default) if options[:default]
|
52
|
+
options.reverse_merge! count: 1, default: defaults
|
53
|
+
I18n.translate(defaults.shift, options.merge(interpolations))
|
58
54
|
end
|
59
55
|
|
60
|
-
|
61
|
-
|
62
|
-
|
63
|
-
:"#{context.klass.i18n_scope}.models.#{i18n_key(context.klass)}"]
|
64
|
-
else
|
65
|
-
[:"ransack.associations.#{i18n_key(context.klass)}.#{key}"]
|
56
|
+
def association(key, options = {})
|
57
|
+
unless context = options.delete(:context)
|
58
|
+
raise ArgumentError, "A context is required to translate associations"
|
66
59
|
end
|
67
|
-
defaults << context.traverse(key).model_name.human
|
68
|
-
options = { :count => 1, :default => defaults }
|
69
|
-
I18n.translate(defaults.shift, options)
|
70
|
-
end
|
71
60
|
|
72
|
-
|
61
|
+
defaults =
|
62
|
+
if key.blank?
|
63
|
+
[:"ransack.models.#{i18n_key(context.klass)}",
|
64
|
+
:"#{context.klass.i18n_scope}.models.#{i18n_key(context.klass)}"]
|
65
|
+
else
|
66
|
+
[:"ransack.associations.#{i18n_key(context.klass)}.#{key}"]
|
67
|
+
end
|
68
|
+
defaults << context.traverse(key).model_name.human
|
69
|
+
options = { :count => 1, :default => defaults }
|
70
|
+
I18n.translate(defaults.shift, options)
|
71
|
+
end
|
73
72
|
|
74
|
-
|
75
|
-
@context, @name = context, name
|
76
|
-
@assoc_path = context.association_path(name)
|
77
|
-
@attr_name = @name.sub(/^#{@assoc_path}_/, ''.freeze)
|
78
|
-
associated_class = @context.traverse(@assoc_path) if @assoc_path.present?
|
79
|
-
@include_associated = include_associations && associated_class
|
73
|
+
private
|
80
74
|
|
81
|
-
|
82
|
-
|
83
|
-
|
75
|
+
def attribute_name(context, name, include_associations = nil)
|
76
|
+
@context, @name = context, name
|
77
|
+
@assoc_path = context.association_path(name)
|
78
|
+
@attr_name = @name.sub(/^#{@assoc_path}_/, ''.freeze)
|
79
|
+
associated_class = @context.traverse(@assoc_path) if @assoc_path.present?
|
80
|
+
@include_associated = include_associations && associated_class
|
84
81
|
|
85
|
-
|
86
|
-
|
82
|
+
defaults = default_attribute_name << fallback_args
|
83
|
+
options = { count: 1, default: defaults }
|
84
|
+
interpolations = build_interpolations(associated_class)
|
87
85
|
|
88
|
-
|
89
|
-
|
90
|
-
end
|
86
|
+
I18n.translate(defaults.shift, options.merge(interpolations))
|
87
|
+
end
|
91
88
|
|
92
|
-
|
93
|
-
|
94
|
-
'%{association_name} %{attr_fallback_name}'.freeze
|
95
|
-
else
|
96
|
-
'%{attr_fallback_name}'.freeze
|
89
|
+
def default_attribute_name
|
90
|
+
["ransack.attributes.#{i18n_key(@context.klass)}.#{@name}".to_sym]
|
97
91
|
end
|
98
|
-
end
|
99
92
|
|
100
|
-
|
101
|
-
|
102
|
-
|
103
|
-
|
104
|
-
|
105
|
-
|
106
|
-
|
93
|
+
def fallback_args
|
94
|
+
if @include_associated
|
95
|
+
'%{association_name} %{attr_fallback_name}'.freeze
|
96
|
+
else
|
97
|
+
'%{attr_fallback_name}'.freeze
|
98
|
+
end
|
99
|
+
end
|
107
100
|
|
108
|
-
|
109
|
-
|
110
|
-
|
111
|
-
|
101
|
+
def build_interpolations(associated_class)
|
102
|
+
{
|
103
|
+
attr_fallback_name: attr_fallback_name(associated_class),
|
104
|
+
association_name: association_name
|
105
|
+
}.reject { |_, value| value.nil? }
|
106
|
+
end
|
107
|
+
|
108
|
+
def attr_fallback_name(associated_class)
|
109
|
+
I18n.t(
|
110
|
+
:"ransack.attributes.#{fallback_class(associated_class)}.#{@attr_name}",
|
111
|
+
default: default_interpolation(associated_class)
|
112
112
|
)
|
113
|
-
|
113
|
+
end
|
114
114
|
|
115
|
-
|
116
|
-
|
117
|
-
|
115
|
+
def fallback_class(associated_class)
|
116
|
+
i18n_key(associated_class || @context.klass)
|
117
|
+
end
|
118
118
|
|
119
|
-
|
120
|
-
|
121
|
-
|
119
|
+
def association_name
|
120
|
+
association(@assoc_path, context: @context) if @include_associated
|
121
|
+
end
|
122
122
|
|
123
|
-
|
124
|
-
|
125
|
-
|
126
|
-
|
127
|
-
|
128
|
-
|
129
|
-
|
130
|
-
end
|
123
|
+
def default_interpolation(associated_class)
|
124
|
+
[
|
125
|
+
associated_attribute(associated_class),
|
126
|
+
".attributes.#{@attr_name}".to_sym,
|
127
|
+
@attr_name.humanize
|
128
|
+
].flatten
|
129
|
+
end
|
131
130
|
|
132
|
-
|
133
|
-
|
134
|
-
|
135
|
-
|
136
|
-
|
131
|
+
def associated_attribute(associated_class)
|
132
|
+
if associated_class
|
133
|
+
translated_attribute(associated_class)
|
134
|
+
else
|
135
|
+
translated_ancestor_attributes
|
136
|
+
end
|
137
137
|
end
|
138
|
-
end
|
139
138
|
|
140
|
-
|
141
|
-
|
139
|
+
def translated_attribute(associated_class)
|
140
|
+
key = "#{associated_class.i18n_scope}.attributes.#{
|
142
141
|
i18n_key(associated_class)}.#{@attr_name}"
|
143
|
-
|
144
|
-
|
142
|
+
["#{key}.one".to_sym, key.to_sym]
|
143
|
+
end
|
145
144
|
|
146
|
-
|
147
|
-
|
148
|
-
|
149
|
-
|
150
|
-
|
145
|
+
def translated_ancestor_attributes
|
146
|
+
@context.klass.ancestors
|
147
|
+
.select { |ancestor| ancestor.respond_to?(:model_name) }
|
148
|
+
.map { |ancestor| translated_attribute(ancestor) }
|
149
|
+
end
|
151
150
|
|
152
|
-
|
153
|
-
|
151
|
+
def i18n_key(klass)
|
152
|
+
raise "not implemented"
|
153
|
+
end
|
154
154
|
end
|
155
155
|
end
|
156
156
|
end
|
data/lib/ransack/version.rb
CHANGED
data/lib/ransack/visitor.rb
CHANGED
@@ -31,17 +31,7 @@ module Ransack
|
|
31
31
|
|
32
32
|
def visit_or(object)
|
33
33
|
nodes = object.values.map { |o| accept(o) }.compact
|
34
|
-
|
35
|
-
|
36
|
-
if nodes.size > 1
|
37
|
-
nodes.inject(&:or)
|
38
|
-
else
|
39
|
-
nodes.first
|
40
|
-
end
|
41
|
-
end
|
42
|
-
|
43
|
-
def visit_Ransack_Nodes_Sort(object)
|
44
|
-
object.attr.send(object.dir) if object.valid?
|
34
|
+
nodes.inject(&:or)
|
45
35
|
end
|
46
36
|
|
47
37
|
def quoted?(object)
|
@@ -57,6 +47,5 @@ module Ransack
|
|
57
47
|
klass.name.gsub(Constants::TWO_COLONS, Constants::UNDERSCORE)
|
58
48
|
}"
|
59
49
|
end
|
60
|
-
|
61
50
|
end
|
62
51
|
end
|
data/lib/ransack.rb
CHANGED
@@ -1,6 +1,7 @@
|
|
1
1
|
require 'active_support/core_ext'
|
2
2
|
require 'ransack/configuration'
|
3
3
|
require 'ransack/adapters'
|
4
|
+
require 'polyamorous'
|
4
5
|
|
5
6
|
Ransack::Adapters.object_mapper.require_constants
|
6
7
|
|
@@ -14,7 +15,7 @@ Ransack.configure do |config|
|
|
14
15
|
config.add_predicate name, :arel_predicate => name
|
15
16
|
end
|
16
17
|
Ransack::Constants::DERIVED_PREDICATES.each do |args|
|
17
|
-
config.add_predicate
|
18
|
+
config.add_predicate(*args)
|
18
19
|
end
|
19
20
|
end
|
20
21
|
|
@@ -26,4 +27,6 @@ require 'ransack/translate'
|
|
26
27
|
|
27
28
|
Ransack::Adapters.object_mapper.require_adapter
|
28
29
|
|
29
|
-
|
30
|
+
ActiveSupport.on_load(:action_controller) do
|
31
|
+
ActionController::Base.helper Ransack::Helpers::FormHelper
|
32
|
+
end
|
data/logo/ransack-h.png
ADDED
Binary file
|
data/logo/ransack-h.svg
ADDED
@@ -0,0 +1,34 @@
|
|
1
|
+
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
|
2
|
+
<!DOCTYPE svg PUBLIC "-//W3C//DTD SVG 1.1//EN" "http://www.w3.org/Graphics/SVG/1.1/DTD/svg11.dtd">
|
3
|
+
<svg width="100%" height="100%" viewBox="0 0 519 114" version="1.1" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" xml:space="preserve" xmlns:serif="http://www.serif.com/" style="fill-rule:evenodd;clip-rule:evenodd;stroke-linejoin:round;stroke-miterlimit:1.41421;">
|
4
|
+
<g transform="matrix(1,0,0,1,-1217.17,-115.878)">
|
5
|
+
<g transform="matrix(1,0,0,1,1076.45,0)">
|
6
|
+
<g transform="matrix(1,0,0,1,-38.0018,0)">
|
7
|
+
<g transform="matrix(0.952133,0,0,0.952133,-804.114,-1490.95)">
|
8
|
+
<path d="M1032.25,1692.74C1032.25,1689.9 1034.55,1687.61 1037.38,1687.61C1052.29,1687.61 1094.52,1687.61 1094.52,1687.61L1094.52,1687.61C1117.36,1687.65 1135.89,1706.2 1135.89,1729.05C1135.89,1741.48 1128.4,1752.63 1119.73,1760.23C1119.73,1760.23 1136.6,1789.45 1143.57,1801.53C1144.18,1802.58 1144.18,1803.88 1143.57,1804.94C1142.96,1806 1141.83,1806.65 1140.61,1806.65C1130.61,1806.65 1110.85,1806.65 1104.56,1806.65C1103.34,1806.65 1102.21,1806 1101.6,1804.94C1097.46,1797.77 1081.71,1770.49 1081.71,1770.49L1073.76,1770.49C1073.76,1770.49 1073.76,1792.44 1073.76,1802.14C1073.76,1803.34 1073.29,1804.48 1072.44,1805.33C1071.6,1806.17 1070.45,1806.65 1069.25,1806.65C1061.27,1806.65 1044.74,1806.65 1036.76,1806.65C1035.56,1806.65 1034.41,1806.17 1033.57,1805.33C1032.72,1804.48 1032.25,1803.34 1032.25,1802.14C1032.25,1783.5 1032.25,1712.5 1032.25,1692.74Z" style="fill:url(#_Linear1);"/>
|
9
|
+
<clipPath id="_clip2">
|
10
|
+
<path d="M1032.25,1692.74C1032.25,1689.9 1034.55,1687.61 1037.38,1687.61C1052.29,1687.61 1094.52,1687.61 1094.52,1687.61L1094.52,1687.61C1117.36,1687.65 1135.89,1706.2 1135.89,1729.05C1135.89,1741.48 1128.4,1752.63 1119.73,1760.23C1119.73,1760.23 1136.6,1789.45 1143.57,1801.53C1144.18,1802.58 1144.18,1803.88 1143.57,1804.94C1142.96,1806 1141.83,1806.65 1140.61,1806.65C1130.61,1806.65 1110.85,1806.65 1104.56,1806.65C1103.34,1806.65 1102.21,1806 1101.6,1804.94C1097.46,1797.77 1081.71,1770.49 1081.71,1770.49L1073.76,1770.49C1073.76,1770.49 1073.76,1792.44 1073.76,1802.14C1073.76,1803.34 1073.29,1804.48 1072.44,1805.33C1071.6,1806.17 1070.45,1806.65 1069.25,1806.65C1061.27,1806.65 1044.74,1806.65 1036.76,1806.65C1035.56,1806.65 1034.41,1806.17 1033.57,1805.33C1032.72,1804.48 1032.25,1803.34 1032.25,1802.14C1032.25,1783.5 1032.25,1712.5 1032.25,1692.74Z"/>
|
11
|
+
</clipPath>
|
12
|
+
<g clip-path="url(#_clip2)">
|
13
|
+
<g transform="matrix(1.05537,0,0,1.05537,-56.2001,-93.6352)">
|
14
|
+
<path d="M1090.07,1757.11C1087.62,1757.78 1085.05,1758.14 1082.39,1758.14C1066.34,1758.14 1053.3,1745.1 1053.3,1729.05C1053.3,1712.99 1066.34,1699.96 1082.39,1699.96C1098.45,1699.96 1111.49,1712.99 1111.49,1729.05C1111.49,1738.8 1106.68,1747.44 1099.3,1752.72C1099.3,1752.72 1110.29,1771.75 1116.66,1782.78C1117.57,1784.36 1117.57,1786.31 1116.66,1787.89C1115.75,1789.47 1114.06,1790.44 1112.23,1790.44C1112.23,1790.44 1112.23,1790.44 1112.23,1790.44C1110.43,1790.44 1108.76,1789.48 1107.86,1787.92C1103.37,1780.15 1090.07,1757.11 1090.07,1757.11ZM1082.52,1708.18C1084.31,1708.32 1084.32,1708.88 1084.66,1709.62C1085.4,1711.22 1084.12,1713.13 1081.99,1713.18C1073.82,1713.44 1066.55,1720.54 1066.53,1729.05C1066.53,1729.05 1066.41,1730.38 1065.53,1731.04C1063.81,1732.34 1061.32,1730.94 1061.59,1727.44C1062.36,1717.22 1071.49,1708.34 1082.13,1708.18C1082.26,1708.18 1082.39,1708.18 1082.52,1708.18Z" style="fill:rgb(52,52,107);fill-opacity:0.4;"/>
|
15
|
+
</g>
|
16
|
+
<path d="M1090.07,1757.11C1087.62,1757.78 1085.05,1758.14 1082.39,1758.14C1066.34,1758.14 1053.3,1745.1 1053.3,1729.05C1053.3,1712.99 1066.34,1699.96 1082.39,1699.96C1098.45,1699.96 1111.49,1712.99 1111.49,1729.05C1111.49,1738.8 1106.68,1747.44 1099.3,1752.72C1099.3,1752.72 1110.19,1771.58 1116.57,1782.63C1117.5,1784.24 1117.5,1786.23 1116.57,1787.84C1115.64,1789.45 1113.92,1790.44 1112.06,1790.44C1112.06,1790.44 1112.06,1790.44 1112.06,1790.44C1110.36,1790.44 1108.79,1789.54 1107.94,1788.07C1103.54,1780.44 1090.07,1757.11 1090.07,1757.11ZM1082.52,1708.18C1084.31,1708.32 1084.32,1708.88 1084.66,1709.62C1085.4,1711.22 1084.12,1713.13 1081.99,1713.18C1073.82,1713.44 1066.55,1720.54 1066.53,1729.05C1066.53,1729.05 1066.41,1730.38 1065.53,1731.04C1063.81,1732.34 1061.32,1730.94 1061.59,1727.44C1062.36,1717.22 1071.49,1708.34 1082.13,1708.18C1082.26,1708.18 1082.39,1708.18 1082.52,1708.18Z" style="fill:rgb(251,248,255);"/>
|
17
|
+
</g>
|
18
|
+
</g>
|
19
|
+
<g transform="matrix(1,0,0,1,-37.1645,15.0997)">
|
20
|
+
<path d="M399.069,182.651L389.349,168.611L388.773,168.611L378.621,168.611L378.621,182.651L366.957,182.651L366.957,132.251L388.773,132.251C393.237,132.251 397.113,132.995 400.401,134.483C403.689,135.971 406.221,138.083 407.997,140.819C409.773,143.555 410.661,146.795 410.661,150.539C410.661,154.283 409.761,157.511 407.961,160.223C406.161,162.935 403.605,165.011 400.293,166.451L411.597,182.651L399.069,182.651ZM398.853,150.539C398.853,147.707 397.941,145.535 396.117,144.023C394.293,142.511 391.629,141.755 388.125,141.755L378.621,141.755L378.621,159.323L388.125,159.323C391.629,159.323 394.293,158.555 396.117,157.019C397.941,155.483 398.853,153.323 398.853,150.539Z" style="fill:rgb(5,5,14);fill-rule:nonzero;"/>
|
21
|
+
<path d="M453.069,171.851L429.669,171.851L425.205,182.651L413.253,182.651L435.717,132.251L447.237,132.251L469.773,182.651L457.533,182.651L453.069,171.851ZM449.397,162.995L441.405,143.699L433.413,162.995L449.397,162.995Z" style="fill:rgb(5,5,14);fill-rule:nonzero;"/>
|
22
|
+
<path d="M521.253,132.251L521.253,182.651L511.677,182.651L486.549,152.051L486.549,182.651L475.029,182.651L475.029,132.251L484.677,132.251L509.733,162.851L509.733,132.251L521.253,132.251Z" style="fill:rgb(5,5,14);fill-rule:nonzero;"/>
|
23
|
+
<path d="M549.765,183.515C545.781,183.515 541.929,182.975 538.209,181.895C534.489,180.815 531.501,179.411 529.245,177.683L533.205,168.899C535.365,170.483 537.933,171.755 540.909,172.715C543.885,173.675 546.861,174.155 549.837,174.155C553.149,174.155 555.597,173.663 557.181,172.679C558.765,171.695 559.557,170.387 559.557,168.755C559.557,167.555 559.089,166.559 558.153,165.767C557.217,164.975 556.017,164.339 554.553,163.859C553.089,163.379 551.109,162.851 548.613,162.275C544.773,161.363 541.629,160.451 539.181,159.539C536.733,158.627 534.633,157.163 532.881,155.147C531.129,153.131 530.253,150.443 530.253,147.083C530.253,144.155 531.045,141.503 532.629,139.127C534.213,136.751 536.601,134.867 539.793,133.475C542.985,132.083 546.885,131.387 551.493,131.387C554.709,131.387 557.853,131.771 560.925,132.539C563.997,133.307 566.685,134.411 568.989,135.851L565.389,144.707C560.733,142.067 556.077,140.747 551.421,140.747C548.157,140.747 545.745,141.275 544.185,142.331C542.625,143.387 541.845,144.779 541.845,146.507C541.845,148.235 542.745,149.519 544.545,150.359C546.345,151.199 549.093,152.027 552.789,152.843C556.629,153.755 559.773,154.667 562.221,155.579C564.669,156.491 566.769,157.931 568.521,159.899C570.273,161.867 571.149,164.531 571.149,167.891C571.149,170.771 570.345,173.399 568.737,175.775C567.129,178.151 564.717,180.035 561.501,181.427C558.285,182.819 554.373,183.515 549.765,183.515Z" style="fill:rgb(5,5,14);fill-rule:nonzero;"/>
|
24
|
+
<path d="M612.333,171.851L588.933,171.851L584.469,182.651L572.517,182.651L594.981,132.251L606.501,132.251L629.037,182.651L616.797,182.651L612.333,171.851ZM608.661,162.995L600.669,143.699L592.677,162.995L608.661,162.995Z" style="fill:rgb(5,5,14);fill-rule:nonzero;"/>
|
25
|
+
<path d="M657.693,183.515C652.557,183.515 647.913,182.399 643.761,180.167C639.609,177.935 636.345,174.839 633.969,170.879C631.593,166.919 630.405,162.443 630.405,157.451C630.405,152.459 631.593,147.983 633.969,144.023C636.345,140.063 639.609,136.967 643.761,134.735C647.913,132.503 652.581,131.387 657.765,131.387C662.133,131.387 666.081,132.155 669.609,133.691C673.137,135.227 676.101,137.435 678.501,140.315L671.013,147.227C667.605,143.291 663.381,141.323 658.341,141.323C655.221,141.323 652.437,142.007 649.989,143.375C647.541,144.743 645.633,146.651 644.265,149.099C642.897,151.547 642.213,154.331 642.213,157.451C642.213,160.571 642.897,163.355 644.265,165.803C645.633,168.251 647.541,170.159 649.989,171.527C652.437,172.895 655.221,173.579 658.341,173.579C663.381,173.579 667.605,171.587 671.013,167.603L678.501,174.515C676.101,177.443 673.125,179.675 669.573,181.211C666.021,182.747 662.061,183.515 657.693,183.515Z" style="fill:rgb(5,5,14);fill-rule:nonzero;"/>
|
26
|
+
<path d="M704.709,162.851L697.941,169.907L697.941,182.651L686.349,182.651L686.349,132.251L697.941,132.251L697.941,155.795L720.261,132.251L733.221,132.251L712.341,154.715L734.445,182.651L720.837,182.651L704.709,162.851Z" style="fill:rgb(5,5,14);fill-rule:nonzero;"/>
|
27
|
+
</g>
|
28
|
+
</g>
|
29
|
+
</g>
|
30
|
+
</g>
|
31
|
+
<defs>
|
32
|
+
<linearGradient id="_Linear1" x1="0" y1="0" x2="1" y2="0" gradientUnits="userSpaceOnUse" gradientTransform="matrix(121.538,125.482,-125.482,121.538,1032.25,1687.61)"><stop offset="0" style="stop-color:rgb(132,132,220);stop-opacity:1"/><stop offset="1" style="stop-color:rgb(51,51,180);stop-opacity:1"/></linearGradient>
|
33
|
+
</defs>
|
34
|
+
</svg>
|
data/logo/ransack-v.png
ADDED
Binary file
|
data/logo/ransack-v.svg
ADDED
@@ -0,0 +1,34 @@
|
|
1
|
+
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
|
2
|
+
<!DOCTYPE svg PUBLIC "-//W3C//DTD SVG 1.1//EN" "http://www.w3.org/Graphics/SVG/1.1/DTD/svg11.dtd">
|
3
|
+
<svg width="100%" height="100%" viewBox="0 0 291 223" version="1.1" xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink" xml:space="preserve" xmlns:serif="http://www.serif.com/" style="fill-rule:evenodd;clip-rule:evenodd;stroke-linejoin:round;stroke-miterlimit:1.41421;">
|
4
|
+
<g transform="matrix(1,0,0,1,-1132.77,-491.089)">
|
5
|
+
<g transform="matrix(1,0,0,1,1076.45,0)">
|
6
|
+
<g transform="matrix(1.25996,0,0,1.25996,-1171.73,-1635.23)">
|
7
|
+
<path d="M1032.25,1691.49C1032.25,1689.34 1033.99,1687.61 1036.13,1687.61C1049.74,1687.61 1094.52,1687.61 1094.52,1687.61L1094.52,1687.61C1117.36,1687.65 1135.89,1706.2 1135.89,1729.05C1135.89,1741.48 1128.4,1752.63 1119.73,1760.23C1119.73,1760.23 1137.85,1791.63 1144.29,1802.78C1144.75,1803.58 1144.75,1804.56 1144.29,1805.36C1143.83,1806.16 1142.98,1806.65 1142.05,1806.65C1132.41,1806.65 1110.05,1806.65 1104.08,1806.65C1103.15,1806.65 1102.3,1806.16 1101.84,1805.36C1098.12,1798.91 1081.71,1770.49 1081.71,1770.49L1073.76,1770.49C1073.76,1770.49 1073.76,1794.23 1073.76,1803.24C1073.76,1805.12 1072.24,1806.65 1070.35,1806.65C1062.55,1806.65 1043.46,1806.65 1035.66,1806.65C1034.75,1806.65 1033.89,1806.29 1033.25,1805.65C1032.61,1805.01 1032.25,1804.14 1032.25,1803.24C1032.25,1786.12 1032.25,1709.65 1032.25,1691.49Z" style="fill:url(#_Linear1);"/>
|
8
|
+
<clipPath id="_clip2">
|
9
|
+
<path d="M1032.25,1691.49C1032.25,1689.34 1033.99,1687.61 1036.13,1687.61C1049.74,1687.61 1094.52,1687.61 1094.52,1687.61L1094.52,1687.61C1117.36,1687.65 1135.89,1706.2 1135.89,1729.05C1135.89,1741.48 1128.4,1752.63 1119.73,1760.23C1119.73,1760.23 1137.85,1791.63 1144.29,1802.78C1144.75,1803.58 1144.75,1804.56 1144.29,1805.36C1143.83,1806.16 1142.98,1806.65 1142.05,1806.65C1132.41,1806.65 1110.05,1806.65 1104.08,1806.65C1103.15,1806.65 1102.3,1806.16 1101.84,1805.36C1098.12,1798.91 1081.71,1770.49 1081.71,1770.49L1073.76,1770.49C1073.76,1770.49 1073.76,1794.23 1073.76,1803.24C1073.76,1805.12 1072.24,1806.65 1070.35,1806.65C1062.55,1806.65 1043.46,1806.65 1035.66,1806.65C1034.75,1806.65 1033.89,1806.29 1033.25,1805.65C1032.61,1805.01 1032.25,1804.14 1032.25,1803.24C1032.25,1786.12 1032.25,1709.65 1032.25,1691.49Z"/>
|
10
|
+
</clipPath>
|
11
|
+
<g clip-path="url(#_clip2)">
|
12
|
+
<g transform="matrix(1.05537,0,0,1.05537,-56.2001,-93.6352)">
|
13
|
+
<path d="M1090.07,1757.11C1087.62,1757.78 1085.05,1758.14 1082.39,1758.14C1066.34,1758.14 1053.3,1745.1 1053.3,1729.05C1053.3,1712.99 1066.34,1699.96 1082.39,1699.96C1098.45,1699.96 1111.49,1712.99 1111.49,1729.05C1111.49,1738.8 1106.68,1747.44 1099.3,1752.72C1099.3,1752.72 1110.29,1771.75 1116.66,1782.78C1117.57,1784.36 1117.57,1786.31 1116.66,1787.89C1115.75,1789.47 1114.06,1790.44 1112.23,1790.44C1112.23,1790.44 1112.23,1790.44 1112.23,1790.44C1110.43,1790.44 1108.76,1789.48 1107.86,1787.92C1103.37,1780.15 1090.07,1757.11 1090.07,1757.11ZM1082.52,1708.18C1084.31,1708.32 1084.32,1708.88 1084.66,1709.62C1085.4,1711.22 1084.12,1713.13 1081.99,1713.18C1073.82,1713.44 1066.55,1720.54 1066.53,1729.05C1066.53,1729.05 1066.41,1730.38 1065.53,1731.04C1063.81,1732.34 1061.32,1730.94 1061.59,1727.44C1062.36,1717.22 1071.49,1708.34 1082.13,1708.18C1082.26,1708.18 1082.39,1708.18 1082.52,1708.18Z" style="fill:rgb(52,52,107);fill-opacity:0.4;"/>
|
14
|
+
</g>
|
15
|
+
<path d="M1090.07,1757.11C1087.62,1757.78 1085.05,1758.14 1082.39,1758.14C1066.34,1758.14 1053.3,1745.1 1053.3,1729.05C1053.3,1712.99 1066.34,1699.96 1082.39,1699.96C1098.45,1699.96 1111.49,1712.99 1111.49,1729.05C1111.49,1738.8 1106.68,1747.44 1099.3,1752.72C1099.3,1752.72 1110.19,1771.58 1116.57,1782.63C1117.5,1784.24 1117.5,1786.23 1116.57,1787.84C1115.64,1789.45 1113.92,1790.44 1112.06,1790.44C1112.06,1790.44 1112.06,1790.44 1112.06,1790.44C1110.36,1790.44 1108.79,1789.54 1107.94,1788.07C1103.54,1780.44 1090.07,1757.11 1090.07,1757.11ZM1082.52,1708.18C1084.31,1708.32 1084.32,1708.88 1084.66,1709.62C1085.4,1711.22 1084.12,1713.13 1081.99,1713.18C1073.82,1713.44 1066.55,1720.54 1066.53,1729.05C1066.53,1729.05 1066.41,1730.38 1065.53,1731.04C1063.81,1732.34 1061.32,1730.94 1061.59,1727.44C1062.36,1717.22 1071.49,1708.34 1082.13,1708.18C1082.26,1708.18 1082.39,1708.18 1082.52,1708.18Z" style="fill:rgb(251,248,255);"/>
|
16
|
+
</g>
|
17
|
+
</g>
|
18
|
+
</g>
|
19
|
+
<g transform="matrix(1,0,0,1,1076.45,0)">
|
20
|
+
<g transform="matrix(0.789583,0,0,0.789583,-233.422,568.437)">
|
21
|
+
<path d="M399.069,182.651L389.349,168.611L388.773,168.611L378.621,168.611L378.621,182.651L366.957,182.651L366.957,132.251L388.773,132.251C393.237,132.251 397.113,132.995 400.401,134.483C403.689,135.971 406.221,138.083 407.997,140.819C409.773,143.555 410.661,146.795 410.661,150.539C410.661,154.283 409.761,157.511 407.961,160.223C406.161,162.935 403.605,165.011 400.293,166.451L411.597,182.651L399.069,182.651ZM398.853,150.539C398.853,147.707 397.941,145.535 396.117,144.023C394.293,142.511 391.629,141.755 388.125,141.755L378.621,141.755L378.621,159.323L388.125,159.323C391.629,159.323 394.293,158.555 396.117,157.019C397.941,155.483 398.853,153.323 398.853,150.539Z" style="fill:rgb(5,5,14);fill-rule:nonzero;"/>
|
22
|
+
<path d="M453.069,171.851L429.669,171.851L425.205,182.651L413.253,182.651L435.717,132.251L447.237,132.251L469.773,182.651L457.533,182.651L453.069,171.851ZM449.397,162.995L441.405,143.699L433.413,162.995L449.397,162.995Z" style="fill:rgb(5,5,14);fill-rule:nonzero;"/>
|
23
|
+
<path d="M521.253,132.251L521.253,182.651L511.677,182.651L486.549,152.051L486.549,182.651L475.029,182.651L475.029,132.251L484.677,132.251L509.733,162.851L509.733,132.251L521.253,132.251Z" style="fill:rgb(5,5,14);fill-rule:nonzero;"/>
|
24
|
+
<path d="M549.765,183.515C545.781,183.515 541.929,182.975 538.209,181.895C534.489,180.815 531.501,179.411 529.245,177.683L533.205,168.899C535.365,170.483 537.933,171.755 540.909,172.715C543.885,173.675 546.861,174.155 549.837,174.155C553.149,174.155 555.597,173.663 557.181,172.679C558.765,171.695 559.557,170.387 559.557,168.755C559.557,167.555 559.089,166.559 558.153,165.767C557.217,164.975 556.017,164.339 554.553,163.859C553.089,163.379 551.109,162.851 548.613,162.275C544.773,161.363 541.629,160.451 539.181,159.539C536.733,158.627 534.633,157.163 532.881,155.147C531.129,153.131 530.253,150.443 530.253,147.083C530.253,144.155 531.045,141.503 532.629,139.127C534.213,136.751 536.601,134.867 539.793,133.475C542.985,132.083 546.885,131.387 551.493,131.387C554.709,131.387 557.853,131.771 560.925,132.539C563.997,133.307 566.685,134.411 568.989,135.851L565.389,144.707C560.733,142.067 556.077,140.747 551.421,140.747C548.157,140.747 545.745,141.275 544.185,142.331C542.625,143.387 541.845,144.779 541.845,146.507C541.845,148.235 542.745,149.519 544.545,150.359C546.345,151.199 549.093,152.027 552.789,152.843C556.629,153.755 559.773,154.667 562.221,155.579C564.669,156.491 566.769,157.931 568.521,159.899C570.273,161.867 571.149,164.531 571.149,167.891C571.149,170.771 570.345,173.399 568.737,175.775C567.129,178.151 564.717,180.035 561.501,181.427C558.285,182.819 554.373,183.515 549.765,183.515Z" style="fill:rgb(5,5,14);fill-rule:nonzero;"/>
|
25
|
+
<path d="M612.333,171.851L588.933,171.851L584.469,182.651L572.517,182.651L594.981,132.251L606.501,132.251L629.037,182.651L616.797,182.651L612.333,171.851ZM608.661,162.995L600.669,143.699L592.677,162.995L608.661,162.995Z" style="fill:rgb(5,5,14);fill-rule:nonzero;"/>
|
26
|
+
<path d="M657.693,183.515C652.557,183.515 647.913,182.399 643.761,180.167C639.609,177.935 636.345,174.839 633.969,170.879C631.593,166.919 630.405,162.443 630.405,157.451C630.405,152.459 631.593,147.983 633.969,144.023C636.345,140.063 639.609,136.967 643.761,134.735C647.913,132.503 652.581,131.387 657.765,131.387C662.133,131.387 666.081,132.155 669.609,133.691C673.137,135.227 676.101,137.435 678.501,140.315L671.013,147.227C667.605,143.291 663.381,141.323 658.341,141.323C655.221,141.323 652.437,142.007 649.989,143.375C647.541,144.743 645.633,146.651 644.265,149.099C642.897,151.547 642.213,154.331 642.213,157.451C642.213,160.571 642.897,163.355 644.265,165.803C645.633,168.251 647.541,170.159 649.989,171.527C652.437,172.895 655.221,173.579 658.341,173.579C663.381,173.579 667.605,171.587 671.013,167.603L678.501,174.515C676.101,177.443 673.125,179.675 669.573,181.211C666.021,182.747 662.061,183.515 657.693,183.515Z" style="fill:rgb(5,5,14);fill-rule:nonzero;"/>
|
27
|
+
<path d="M704.709,162.851L697.941,169.907L697.941,182.651L686.349,182.651L686.349,132.251L697.941,132.251L697.941,155.795L720.261,132.251L733.221,132.251L712.341,154.715L734.445,182.651L720.837,182.651L704.709,162.851Z" style="fill:rgb(5,5,14);fill-rule:nonzero;"/>
|
28
|
+
</g>
|
29
|
+
</g>
|
30
|
+
</g>
|
31
|
+
<defs>
|
32
|
+
<linearGradient id="_Linear1" x1="0" y1="0" x2="1" y2="0" gradientUnits="userSpaceOnUse" gradientTransform="matrix(121.538,125.482,-125.482,121.538,1032.25,1687.61)"><stop offset="0" style="stop-color:rgb(132,132,220);stop-opacity:1"/><stop offset="1" style="stop-color:rgb(51,51,180);stop-opacity:1"/></linearGradient>
|
33
|
+
</defs>
|
34
|
+
</svg>
|
data/logo/ransack.png
ADDED
Binary file
|