2023-02-23 00:14:00 +01:00
|
|
|
Order.class_eval do
|
2023-02-17 13:16:03 +01:00
|
|
|
def send_to_supplier!(user, options = {})
|
|
|
|
Mailer.deliver_now_with_default_locale do
|
|
|
|
Mailer.order_result_supplier(user, self, options)
|
|
|
|
end
|
|
|
|
update!(last_sent_mail: Time.now)
|
|
|
|
end
|
|
|
|
end
|