mirror of
https://github.com/openfoodfoundation/openfoodnetwork
synced 2026-03-27 06:05:19 +00:00
Bring core/lib/spree/core/ext/active_record.rb to OFN and add it to Spree::Order, the only place where it is used
This commit is contained in:
@@ -378,6 +378,13 @@ Spree::Order.class_eval do
|
||||
address
|
||||
end
|
||||
|
||||
# Update attributes of a record in the database without callbacks, validations etc.
|
||||
# This was originally a ext to ActiveRecord in Spree but only used for Spree::Order
|
||||
def update_attributes_without_callbacks(attributes)
|
||||
assign_attributes(attributes)
|
||||
Spree::Order.where(id: id).update_all(attributes)
|
||||
end
|
||||
|
||||
private
|
||||
|
||||
def adjustments_fetcher
|
||||
|
||||
Reference in New Issue
Block a user