Skip to content

Instantly share code, notes, and snippets.

Created October 8, 2014 18:23
Show Gist options
  • Save anonymous/4a8e9efcd34d3be70591 to your computer and use it in GitHub Desktop.
Save anonymous/4a8e9efcd34d3be70591 to your computer and use it in GitHub Desktop.
Spree::CheckoutController.class_eval do
def update_with_marketplace_sync
if @order.completed?
# Тут используешь @order или @current_order пока он ещё не обнулён и всё другое
end
update_without_marketplace_sync
end
alias_method_chain :update, :marketplace_sync
end
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment