2021-01-27 11:29:24 -05:00
|
|
|
# frozen_string_literal: true
|
|
|
|
|
|
|
|
class ShelvedNotification < ActiveRecord::Base
|
2024-08-26 22:56:00 -04:00
|
|
|
self.ignored_columns = [
|
2024-10-15 04:58:57 -04:00
|
|
|
:old_notification_id, # TODO: Remove once 20240829140226_drop_old_notification_id_columns has been promoted to pre-deploy
|
2024-08-26 22:56:00 -04:00
|
|
|
]
|
|
|
|
|
2021-01-27 11:29:24 -05:00
|
|
|
belongs_to :notification
|
|
|
|
|
|
|
|
def process
|
|
|
|
NotificationEmailer.process_notification(notification, no_delay: true)
|
|
|
|
end
|
|
|
|
end
|
2021-07-05 18:14:15 -04:00
|
|
|
|
|
|
|
# == Schema Information
|
|
|
|
#
|
|
|
|
# Table name: shelved_notifications
|
|
|
|
#
|
2024-08-26 23:15:03 -04:00
|
|
|
# id :bigint not null, primary key
|
|
|
|
# notification_id :bigint not null
|
2021-07-05 18:14:15 -04:00
|
|
|
#
|
|
|
|
# Indexes
|
|
|
|
#
|
|
|
|
# index_shelved_notifications_on_notification_id (notification_id)
|
|
|
|
#
|