impressionist
impressionist copied to clipboard
How to create model callbacks?
I'm using active record ORM. Is there any way to create callbacks for impression model? I want to run a background job on after create callback.
I need to do this as well. Has anyone been able to. I tried making a basic model like below but it seems to get ignored by Rails.
class Impression < ApplicationRecord
belongs_to :thing, optional: true
end