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
Refatoração do método POST em carrinhos-controller #303
Refatoração do método POST em carrinhos-controller #303
Conversation
@edumaxsantos conseguiria atualizar a sua branch com a branch principal ( git remote add upstream git@github.com:ServeRest/ServeRest.git
git fetch upstream
git rebase upstream/trunk
git push --force-with-lease origin refactoring/controllers |
First change to refactor carrinhos-controller. Moved repeated code to a function. re ServeRest#208
…otal and quantidadeTotal re ServeRest#208
Removed usage of Object.assign inside pos method as part of the refactoring
When calculating quantidadeTotal we need to update quantidade to the new value. Now we have produtosService.updateQuantidade() that will handle that for us.
dc0b758
to
670f80f
Compare
Realizei os comandos que solicitou. Tudo certo? |
Acabei de revisar, ótima alteração @edumaxsantos, reduziu a complexidade da controller de carrinhos, obrigado pelo PR e desculpe pela demora em revisar. @all-contributors please add @edumaxsantos for code |
@all-contributors please add @edumaxsantos for code |
I've put up a pull request to add @edumaxsantos! 🎉 |
🎉 This PR is included in version 2.26.1 🎉 The release is available on: Your semantic-release bot 📦🚀 |
Description
Como discutido em #208, dei início na refatoração do método POST utilizado para cadastrar um carrinho.
How can the user experience this change?
N/A
Documentation
N/A
Related Issues
Related to #208
PR Tasks