Sha256: 4b714e5a840b8f01a6d79b114ea1238e938cd7db43e52777f3d302f2a84c487d
Contents?: true
Size: 407 Bytes
Versions: 2
Compression:
Stored size: 407 Bytes
Contents
class Webhooks::Outgoing::EventType < ActiveHash::Base include ActiveHash::Associations self.data = YAML.load_file("config/models/webhooks/outgoing/event_types.yml").map do |topic, events| events.map { |event| event == "crud" ? ["created", "updated", "deleted"] : event }.flatten.map { |event| {id: "#{topic}.#{event}"} } end.flatten def name id end def label_string id end end
Version data entries
2 entries across 2 versions & 1 rubygems
Version | Path |
---|---|
bullet_train-outgoing_webhooks-1.0.1 | lib/models/webhooks/outgoing/event_type.rb |
bullet_train-outgoing_webhooks-1.0.0 | lib/models/webhooks/outgoing/event_type.rb |