Add paid flag to email subject, check receipt date in tests

This commit is contained in:
Alex Sherman 2021-05-28 13:53:14 +05:00
parent 82c048b316
commit 235ef9ba3e
5 changed files with 32 additions and 5 deletions

View file

@ -101,7 +101,8 @@ class Registrar < ApplicationRecord
)
unless payable
InvoiceMailer.invoice_email(invoice: invoice, recipient: billing_email).deliver_now
InvoiceMailer.invoice_email(invoice: invoice, recipient: billing_email, paid: !payable)
.deliver_later(wait: 1.minute)
end
SendEInvoiceJob.perform_later(invoice.id, payable)