-
Notifications
You must be signed in to change notification settings - Fork 108
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
Wrong state of Payment after approveAndDeposit #11
Comments
I need to think more about this, but it's the same in websphere. |
indeet i see .. anyways tnx a lot! |
I only use PayPal at the moment. |
This was closed as a 'works as intended', with the link to the web sphere docs. I can't find anything in the linked websphere doc about STATE_DEPOSITED or STATE_DEPOSITING. For example, doDeposit in the php PluginController switches the payment from STATE_APPROVED to STATE_DEPOSITING before running the inner plugin action. Then if the resulting processed amount, plus any previously deposited amount, equals the payments approved amount after a successfull response it transitions again to STATE_DEPOSITED compare to the linked websphere docs for doDeposit: PPC makes sure that: PaymentInstruction is in STATE_VALID set depositing amount in Payment reset Payment depositing amount by the requested amount Basically, i'm trying to figure out how STATE_DEPOSITED fits into the system. Its referenced exactly one time outside of a test case, and once a payment gets into STATE_DEPOSITED its no longer possible to reverse it, because reverseDeposit requires the payment to be STATE_APPROVED, not STATE_DEPOSITED. |
This is additionally shown in the 'state machine' graph provided by ibm: http://i.imgur.com/1mp8t.png |
This seems like an inconsistency to me. We probably need to adjust the state after the approveAndDeposit method to DEPOSITED, and also the state that is required by the reverseDeposit method. DEPOSITING was introduced to allow a PENDING transaction to complete successfully. For example, after the user has done something (visited an URL, etc.). |
That makes sense. I will write and test a patch along that line of thought this week. |
We have a related problem in #34 |
@schmittjoh, any news? I belive this is crucial for all of us. |
I think no-one is working on this atm, so you could write up a patch if you like. |
I'll work on it then. Thanks! |
Hi,
i am using approveAndDeposit, and it works like a charm except for the payment status afterwards.
Money is beeing approved and deposited but state is STATE_APPROVED
i think thats due to
https://github.com/schmittjoh/JMSPaymentCoreBundle/blob/master/PluginController/PluginController.php#L331
musnt that be STATE_DEPOSITED?
as far as i understood state transition is to APPROVED after approving and DEPOSITED after succ depositing or?
since its done in one flow with approveAndDeposit i would assume to have state DEPOSITED afterwards ?
cheers phil
The text was updated successfully, but these errors were encountered: