Class: ForestAdminDatasourceToolkit::Components::Query::ConditionTree::ConditionTreeEquivalent
- Inherits:
-
Object
- Object
- ForestAdminDatasourceToolkit::Components::Query::ConditionTree::ConditionTreeEquivalent
- Defined in:
- lib/forest_admin_datasource_toolkit/components/query/condition_tree/condition_tree_equivalent.rb
Class Method Summary collapse
- .equivalent_tree?(operator, filter_operators, column_type) ⇒ Boolean
- .get_equivalent_tree(leaf, operators, column_type, timezone) ⇒ Object
Class Method Details
.equivalent_tree?(operator, filter_operators, column_type) ⇒ Boolean
12 13 14 15 16 |
# File 'lib/forest_admin_datasource_toolkit/components/query/condition_tree/condition_tree_equivalent.rb', line 12 def self.equivalent_tree?(operator, filter_operators, column_type) return true if filter_operators.include?(operator) !get_replacer(operator, filter_operators, column_type).nil? end |
.get_equivalent_tree(leaf, operators, column_type, timezone) ⇒ Object
6 7 8 9 10 |
# File 'lib/forest_admin_datasource_toolkit/components/query/condition_tree/condition_tree_equivalent.rb', line 6 def self.get_equivalent_tree(leaf, operators, column_type, timezone) operator = leaf.operator get_replacer(operator, operators, column_type).call(leaf, timezone) end |