Skip to content
This repository has been archived by the owner on Apr 14, 2023. It is now read-only.

Products invisible in Admin Order view / Crash in the log #159

Closed
mntmn opened this issue Mar 16, 2018 · 9 comments
Closed

Products invisible in Admin Order view / Crash in the log #159

mntmn opened this issue Mar 16, 2018 · 9 comments

Comments

@mntmn
Copy link

mntmn commented Mar 16, 2018

The first real order just came in in my production shop using solidus_paypal_braintree. But in the admin interface, the "Cart" section of the order does not show any products. The products show up on the "cancel items", though.

The error in the log is ActionView::Template::Error (undefined method 'month' for #<SolidusPaypalBraintree::Source:0x007fa5b89db808>)

I attached the trace: month-crash.log

Versions:

gem 'solidus', '2.5.0.beta2'
gem 'deface'
gem 'solidus_auth_devise', '2.1.0'
gem 'solidus_paypal_braintree', github: 'solidusio/solidus_paypal_braintree', branch: :master
@chaumo
Copy link

chaumo commented Mar 26, 2018

same issue here after updating to solidus 2.5.0.rc1

@octave
Copy link

octave commented Apr 8, 2018

Same after upgrade to 2.5.0

@octave
Copy link

octave commented Apr 17, 2018

Did anyone find a workaround for this issue?

@hefan
Copy link

hefan commented Apr 18, 2018

the reason for this is explained here solidusio/solidus#2512

in short: the payment source does not provide all attributes needed. my workaround is to set dummies for all those fields needed.

SolidusPaypalBraintree::Source.class_eval do

  def name() "Solidus PayPal Braintree" end
  def month() nil end
  def year() nil end
  def card_type() nil end
  def cc_type() nil end
  def gateway_customer_profile_id() nil end
  def gateway_payment_profile_id() nil end

end

but i guess it is fixed in the solidus api master
https://github.com/solidusio/solidus/pull/2513/files

@octave
Copy link

octave commented Apr 18, 2018

@hefan Nice thank you for your help!

@octave
Copy link

octave commented May 14, 2018

@hefan I have a new error now after upgrading to 2.6.0rc1 when viewing an order in the admin:

ActionView::Template::Error (Missing partial spree/api/payments/source_views/_paypal_braintree with {:locale=>[:en], :formats=>[:json], :variants=>[], :handlers=>[:jbuilder]}

Do you know what could be the reason? Thanks!

@octave
Copy link

octave commented May 14, 2018

It seems like the path used to be spree/admin/ instead of spree/api.

@octave
Copy link

octave commented May 14, 2018

Same error in solidus_gateway: solidusio/solidus_gateway#81

@kennyadsl
Copy link
Member

This has been fixed in a recent change

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

5 participants