mirror of
https://github.com/internetee/registry.git
synced 2025-08-01 15:34:41 +02:00
Migrate refresh status notes to CheckForceDeleteLift
job
This commit is contained in:
parent
c6ff1ad300
commit
71d1e9bf47
5 changed files with 75 additions and 56 deletions
|
@ -35,8 +35,6 @@ class ValidationEvent < ApplicationRecord
|
|||
scope :smtp, -> { where('event_data @> ?', { 'check_level': 'smtp' }.to_json) }
|
||||
scope :by_object, ->(object) { where(validation_eventable: object) }
|
||||
|
||||
after_create :check_force_delete_lift
|
||||
|
||||
def self.validated_ids_by(klass)
|
||||
old_records
|
||||
.successful
|
||||
|
@ -59,10 +57,4 @@ class ValidationEvent < ApplicationRecord
|
|||
def object
|
||||
validation_eventable
|
||||
end
|
||||
|
||||
private
|
||||
|
||||
def check_force_delete_lift
|
||||
CheckForceDeleteLiftJob.perform_later(id, object.id) if object.need_to_lift_force_delete?
|
||||
end
|
||||
end
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue