Sha256: d8695edba8a6883777cb2f46746720bc7a4e511900238d6b8e5c23751945527b

Contents?: true

Size: 651 Bytes

Versions: 3

Compression:

Stored size: 651 Bytes

Contents

module Spree
  class PagSeguroController < Spree::CheckoutController
    protect_from_forgery :except => [:confirm]
    skip_before_filter :persist_gender
    
    def notify
      email = Spree::PagSeguro::Config.email
      token = Spree::PagSeguro::Config.token
      notification_code = params[:notificationCode]
      notification = PagSeguro::Notification.new(email, token, notification_code)
      raise "###########################\n\n\n\n\n#{notification.inspect}\n\n\n\n\n###########################"
      if notification.approved?
        order = Spree::Order.find(notification.id)
      end
    end
    
    def callback
    end
  end
end

Version data entries

3 entries across 3 versions & 1 rubygems

Version Path
spree_pag_seguro-1.0.0.beta9 app/controllers/spree/pag_seguro_controller.rb
spree_pag_seguro-1.0.0.beta8 app/controllers/spree/pag_seguro_controller.rb
spree_pag_seguro-1.0.0.beta7 app/controllers/spree/pag_seguro_controller.rb