module BestBoy::Eventable::ClassMethods
Attributes
best_boy_disable_callbacks[RW]
Public Instance Methods
has_a_best_boy(options={})
click to toggle source
# File lib/best_boy/eventable.rb, line 9 def has_a_best_boy(options={}) # constants # # self.best_boy_disable_callbacks = options[:disable_callbacks] # associations # # has_many :best_boy_events, as: :owner, class_name: "BestBoy::Event", dependent: :nullify # callbacks # # after_create :trigger_best_boy_create_event after_destroy :trigger_best_boy_destroy_event end