Fix quote mailer preview to use the latest quote notification (#36373)
This commit is contained in:
@@ -35,7 +35,9 @@ class NotificationMailerPreview < ActionMailer::Preview
|
||||
|
||||
# Preview this email at http://localhost:3000/rails/mailers/notification_mailer/quote
|
||||
def quote
|
||||
activity = Quote.first
|
||||
notification = Notification.where(type: 'quote').order(:created_at).last
|
||||
activity = notification.activity
|
||||
|
||||
mailer_for(activity.quoted_account, activity).quote
|
||||
end
|
||||
|
||||
|
||||
Reference in New Issue
Block a user