Skip to content
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

6pm-3: Buy and Sell working through Swagger/Backend #60

Closed
wants to merge 28 commits into from

Conversation

sophiajmoore
Copy link
Contributor

@sophiajmoore sophiajmoore commented Mar 14, 2022

Overview

This PR adds the functionality of buy and sell to the backend and can be used through Swagger. The proper equations for buy and sell (using the weighted scale when selling) are not implemented at the moment through this PR.

All that has been changed is that the backend was pulled from PR #58 , and the frontend code is from main.

Issues Addressed

#14 is partially addressed in this PR

Details

The two images below show that "Buy" is working.
Screen Shot 2022-03-13 at 5 33 29 PM
Screen Shot 2022-03-13 at 5 33 54 PM

The images below show that "Sell" is working.
Screen Shot 2022-03-13 at 5 35 20 PM
Screen Shot 2022-03-13 at 5 35 31 PM

sophiajmoore and others added 28 commits March 10, 2022 15:53
…e sense to save a usercommons to a nonexistent commons
… to match with the way they are called from playpage
@codecov
Copy link

codecov bot commented Mar 14, 2022

Codecov Report

Merging #60 (5623337) into main (b4f5ce2) will decrease coverage by 11.13%.
The diff coverage is 100.00%.

❗ Current head 5623337 differs from pull request most recent head cdd6c4f. Consider uploading reports for the commit cdd6c4f to get more accurate results

Impacted file tree graph

@@              Coverage Diff              @@
##               main      #60       +/-   ##
=============================================
- Coverage     81.09%   69.96%   -11.14%     
- Complexity       75       79        +4     
=============================================
  Files            52       21       -31     
  Lines           439      273      -166     
  Branches         12       12               
=============================================
- Hits            356      191      -165     
+ Misses           83       82        -1     
Impacted Files Coverage Δ
...156/happiercows/controllers/CommonsController.java 100.00% <100.00%> (ø)
...156/happiercows/controllers/ProfitsController.java 100.00% <100.00%> (ø)
...happiercows/controllers/UserCommonsController.java 100.00% <100.00%> (ø)
...ontend/src/main/components/Commons/CommonsTable.js
frontend/src/main/pages/HomePage.js
...rontend/src/main/components/Commons/CommonsPlay.js
frontend/src/main/components/Profile/RoleBadge.js
frontend/src/main/pages/ProfilePage.js
frontend/src/main/components/OurTable.js
...ontend/src/main/layouts/BasicLayout/BasicLayout.js
... and 24 more

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update b4f5ce2...cdd6c4f. Read the comment docs.

@sophiajmoore sophiajmoore reopened this Mar 14, 2022
@sophiajmoore sophiajmoore temporarily deployed to team04-w22-6pm-3 March 14, 2022 00:45 Inactive
@sophiajmoore sophiajmoore reopened this Mar 14, 2022
@eambriz27 eambriz27 temporarily deployed to team04-w22-6pm-3-qa March 14, 2022 02:18 Inactive
@sophiajmoore sophiajmoore deleted the sm-rl-backend-buyandsell branch March 14, 2022 04:04
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

4 participants