Date: 2009-03-24 00:53
Sender: David Koontz
I second this, it's a really trivial fix (but annoying since
we have this gem on multiple machines). Here's the diff.
*** freshbooks.rb.orig 2009-03-23 17:47:49.000000000 -0700
--- freshbooks.rb 2009-03-23 17:46:49.000000000 -0700
***************
*** 435,441 ****
class Recurring
! TYPE_MAPPINGS = { 'client_id' => Fixnum, 'lines' =>
Array,
'po_number' => Fixnum, 'discount' => Float, 'amount'
=> Float,
'occurrences' => Fixnum }
--- 435,441 ----
class Recurring
! TYPE_MAPPINGS = { 'recurring_id' => Fixnum, 'client_id'
=> Fixnum, 'lines' => Array,
'po_number' => Fixnum, 'discount' => Float, 'amount'
=> Float,
'occurrences' => Fixnum }
***************
*** 447,456 ****
def create
resp = FreshBooks::call_api('recurring.create', 'recurring'
=> self)
if resp.success?
! self.invoice_id = resp.elements[1].text.to_i
end
! resp.success? ? self.invoice_id : nil
end
def update
--- 447,456 ----
def create
resp = FreshBooks::call_api('recurring.create', 'recurring'
=> self)
if resp.success?
! self.recurring_id = resp.elements[1].text.to_i
end
! resp.success? ? self.recurring_id : nil
end
def update
|