foodsoft/plugins/bnn_upload/app/overrides/models/order_override.rb

9 lines
222 B
Ruby
Raw Normal View History

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