Last active
August 29, 2015 14:20
-
-
Save benmacleod/259c0b96e958f8cc4d81 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# This is what my params looks like | |
{:group_id=>86, | |
:payer_id=>1982, | |
:account_type=>"standard", | |
:sms_credit_price_ex_tax=>"0.025", | |
:auto_purchase_sms_credits_amount=>1000, | |
:setup_invoice=>true, | |
:locale=>"en-GB", | |
:timezone=>"London", | |
:pays_subscription=>true, | |
:periodic_charges_attributes=> | |
[{:start_date=>2015-05-01 00:00:00 +0000, | |
:price_ex_tax=>65, :currency => :gbp ], | |
:users_attributes=>[{:name=>"tal_chesterle", | |
:email=>"ManagerChesterLeSt226@tattsgroup.com", | |
:password=>"ManagerChesterLeSt226@tattsgroup.com", | |
:password_confirmation=>"ManagerChesterLeSt226@tattsgroup.com"}], | |
:name=>"226 Quicksilver Chester Le St", | |
:email=>"ManagerChesterLeSt226@tattsgroup.com", | |
:public_email=>"ManagerChesterLeSt226@tattsgroup.com", | |
:contact_name=>"Beth Jones", | |
:public_phone=>"01405 762061", | |
:phone=>"01405 762061"} | |
# I want to create subscription for accounts | |
# | |
# It generates error when it tries to add tax. The following error pops up when I run a = Account.new(params): | |
# RuntimeError: unknown currency nil | |
# from /app/app/models/concerns/monetizable.rb:34:in `tax_rate' | |
# from /app/app/models/concerns/monetizable.rb:53:in `value_plus_tax' | |
# from /app/app/models/concerns/monetizable.rb:97:in `block (2 levels) in <module:Monetizable>' |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment