-
Notifications
You must be signed in to change notification settings - Fork 93
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Adds external payments to invoices #309
Conversation
lib/recurly/invoice.php
Outdated
* @param Recurly_Transaction additional transaction attributes. The attributes available to set are (payment_method, collected_at, amount_in_cents, description) | ||
* @return Recurly_Transaction transaction on success | ||
*/ | ||
public function enterOfflinePayment($transaction, $client = null) { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
this shouldn't need the $client param unless it's a static method
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
It's for the tests since this does call a static method. Is there a way around that?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I could perhaps change this to
return Recurly_Transaction::_post($uri, $transaction->xml(), $this->_client);
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
yeah $this->client
should have been set when the invoice was initialized.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Okay, updated it
ca3e069
to
1d6b83e
Compare
1d6b83e
to
0e110fe
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks good
Resolves #141
Adds the ability to "Enter an offline payment for a manual invoice". If this is merged, then the code example on that page will have to be updated. This picks up on the work of @cgerrior in PR #154