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
Sales Order Payment is complicated #744
Comments
I like how trivalent logic is implemented using |
@ihor-sviziev, thank you for your note. We have plan to reducing complexity in the system. This issue will be added to our backlog. We will update you when it will be ready. Also, you may want to provide proposal on how you see this class might be refactored. Thanks. |
Internal ticket: MAGETWO-31585 |
Now this class logic looks much better, but now it still contains ~2600 lines of code, I think we may separate class functionality to two or more classes and use delegation. |
@ihor-sviziev, when we have time we try to decrease code complexity and re-implement complicated classes in sales/payment infrastructure, but this work doesn't have high priority, that's why we can't promise that suggested refactoring will be done in the near future. |
@ihor-sviziev, we've done some work around complicated Sales Order Payment. If you compare this class in develop and master branch, you will see that about 400 lines of code were removed from it. Please, look at our changes. All feedback from your side is welcome. |
@vpelipenko really good progress, now it looks better, but not enough. What I think we should improve:
|
Thank you for your submission. We recently made some changes to the way we process GitHub submissions to more quickly identify and respond to core code issues. Feature Requests and Improvements should now be submitted to the new Magento 2 Feature Requests and Improvements forum (see details here). We are closing this GitHub ticket and have moved your request to the new forum. |
- Merge Pull Request magento/graphql-ce#744 from pmclain/graphql-ce:hotfix/unset-region - Merged commits: 1. def6657 2. 5e83ddf 3. e01560c 4. 2c05ca6
For now this class is very complicated and hard to understand their logic
https://github.com/magento/magento2/blob/master/app/code/Magento/Sales/Model/Order/Payment.php#L1036
The text was updated successfully, but these errors were encountered: