-
-
Notifications
You must be signed in to change notification settings - Fork 825
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
[ref] Extract activity payment creation #13695
Conversation
(Standard links)
|
4ea4506
to
6eb1966
Compare
THis is likely not it's last resting place but it does make the functions involved a lot simpler now
6eb1966
to
3d6a264
Compare
test this please |
2 similar comments
test this please |
test this please |
@eileenmcnaughton two points:
|
@monishdeb so in terms of 1 - this was just intended as a small step - not necessarily the final form of the function. I think addActivityForPayment should be re-merged back into recordPaymentActivity & the function cleaned up as the next step in terms of 2 - I guess my worry is just that it's a behaviour change if we always create activities - & I feel like some wider buy in is needed |
@monishdeb shall we merge this - I think your comments were along the lines of 'could go further' - which I agree with but this seems like a step in the right direction |
umm yeah rightful step, ok I am gonna merge this! As reviewed earlier, nothing changes since then and all the code is safely shipped to this new fn. Merging now. |
Overview
Minor code cleanup
Before
Code less readable
After
code more readable
Technical Details
I suspect this might also go on the payment class but that might be next - it could also do with a another round of tidy up since it's 2 functions when only one is needed
Comments
The following doesn't block merging this change which is a refactor - but it is commentary on possible next steps
Should the payment.create bao call this? I feel like maybe it should call this if it doesn't result in completetransaction (which would have other activities ) - in our ideal flow we would create an order (pending) process a payment & add a payment when it's complete (potentially completing the order) - if these things happen all at the same time it might be odd to have too many activities created