Module: ZendeskAPI::Conditions
- Included in:
- Automation, Trigger, View
- Defined in:
- lib/zendesk_api/resources.rb
Instance Method Summary collapse
- #add_all_condition(field, operator, value) ⇒ Object
- #add_any_condition(field, operator, value) ⇒ Object
- #all_conditions=(all_conditions) ⇒ Object
- #any_conditions=(any_conditions) ⇒ Object
Instance Method Details
#add_all_condition(field, operator, value) ⇒ Object
507 508 509 510 511 |
# File 'lib/zendesk_api/resources.rb', line 507 def add_all_condition(field, operator, value) self.conditions ||= {} self.conditions[:all] ||= [] self.conditions[:all] << { :field => field, :operator => operator, :value => value } end |
#add_any_condition(field, operator, value) ⇒ Object
513 514 515 516 517 |
# File 'lib/zendesk_api/resources.rb', line 513 def add_any_condition(field, operator, value) self.conditions ||= {} self.conditions[:any] ||= [] self.conditions[:any] << { :field => field, :operator => operator, :value => value } end |
#all_conditions=(all_conditions) ⇒ Object
497 498 499 500 |
# File 'lib/zendesk_api/resources.rb', line 497 def all_conditions=(all_conditions) self.conditions ||= {} self.conditions[:all] = all_conditions end |
#any_conditions=(any_conditions) ⇒ Object
502 503 504 505 |
# File 'lib/zendesk_api/resources.rb', line 502 def any_conditions=(any_conditions) self.conditions ||= {} self.conditions[:any] = any_conditions end |