Class: WebhookTemplate
- Inherits:
-
Template
- Object
- Template
- WebhookTemplate
- Extended by:
- FriendlyId
- Includes:
- Authorizable, Parameterizable::ByIdName, Taxonomix
- Defined in:
- app/models/webhook_template.rb
Class Method Summary collapse
- .acceptable_template_input_types ⇒ Object
-
.base_class ⇒ Object
we have to override the base_class because polymorphic associations does not detect it correctly, more details at apidock.com/rails/ActiveRecord/Associations/ClassMethods/has_many#1010-Polymorphic-has-many-within-inherited-class-gotcha.
- .default_render_scope_class ⇒ Object
- .log_render_results? ⇒ Boolean
Instance Method Summary collapse
- #support_preview? ⇒ Boolean
- #support_single_host_render? ⇒ Boolean
- #taxonomy_foreign_conditions ⇒ Object
Class Method Details
.acceptable_template_input_types ⇒ Object
50 51 52 |
# File 'app/models/webhook_template.rb', line 50 def self.acceptable_template_input_types [:user] end |
.base_class ⇒ Object
we have to override the base_class because polymorphic associations does not detect it correctly, more details at apidock.com/rails/ActiveRecord/Associations/ClassMethods/has_many#1010-Polymorphic-has-many-within-inherited-class-gotcha
16 17 18 |
# File 'app/models/webhook_template.rb', line 16 def base_class self end |
.default_render_scope_class ⇒ Object
42 43 44 |
# File 'app/models/webhook_template.rb', line 42 def self.default_render_scope_class ForemanWebhooks::Renderer::Scope::WebhookTemplate end |
.log_render_results? ⇒ Boolean
54 55 56 |
# File 'app/models/webhook_template.rb', line 54 def self.log_render_results? true end |
Instance Method Details
#support_preview? ⇒ Boolean
62 63 64 |
# File 'app/models/webhook_template.rb', line 62 def support_preview? false end |
#support_single_host_render? ⇒ Boolean
58 59 60 |
# File 'app/models/webhook_template.rb', line 58 def support_single_host_render? false end |
#taxonomy_foreign_conditions ⇒ Object
46 47 48 |
# File 'app/models/webhook_template.rb', line 46 def taxonomy_foreign_conditions { webhook_template_id: id } end |