ruckus / quickbooks-ruby

Quickbooks Online REST API V3 - Ruby
MIT License
374 stars 302 forks source link

Unable to use allow_ipn_payment? on invoice #474

Closed ponnuchamy51 closed 5 years ago

ponnuchamy51 commented 5 years ago

Unable to create invoice with allow_online_ach_payment this option. For this i am getting syntax error while using

invoice.allow_online_ach_payment? = true

i am using 389 branch

syntax error, unexpected '='

For THIS invoice = Quickbooks::Service::Invoice.new invoice.allow_online_ach_payment? = true

ruckus commented 5 years ago

You should be setting that method on the model, not the service object.

So instead of:

invoice = Quickbooks::Service::Invoice.new
invoice.allow_online_ach_payment? = true

Try this:

invoice = Quickbooks::Model::Invoice.new
invoice.allow_online_ach_payment = true # notice the writer does not have '?'