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

model setup for donation tracking #4838

Merged
merged 4 commits into from
Jul 28, 2019
Merged

model setup for donation tracking #4838

merged 4 commits into from
Jul 28, 2019

Conversation

danlipert
Copy link
Contributor

Description

This PR adds the model to track the optional donations made through new and legacy grants.

Refers/Fixes

#4724

Testing

Just the model setup, so no testing (other than the syntax is clean and the server boots)

@thelostone-mc
Copy link
Member

@danlipert still a WIP ?

@codecov
Copy link

codecov bot commented Jul 22, 2019

Codecov Report

Merging #4838 into master will increase coverage by 0.06%.
The diff coverage is 88.88%.

Impacted file tree graph

@@            Coverage Diff            @@
##           master   #4838      +/-   ##
=========================================
+ Coverage   30.64%   30.7%   +0.06%     
=========================================
  Files         216     216              
  Lines       17411   17425      +14     
  Branches     2364    2363       -1     
=========================================
+ Hits         5336    5351      +15     
+ Misses      11860   11859       -1     
  Partials      215     215
Impacted Files Coverage Δ
app/grants/models.py 59.51% <88.88%> (+1.68%) ⬆️
app/kudos/views.py 21.55% <0%> (-0.05%) ⬇️

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 0d96b67...eefd6f6. Read the comment docs.

@danlipert
Copy link
Contributor Author

Some notes for the follow on PRs:

New Grants

For new grants, the donations are made in two different ways: first, for a one-time contribution to a grant, the one-time donation is made in the frontend via the splitter contract. For this use case, we'll just need to POST the donation data when the one-time contribution is made.

For recurring subscriptions, donations are made with each individual contribution. For this use case, we'll need to add code to the subminer that records the donation data each time a subscription is mined.

Legacy Grants

For legacy grants, the donations made through recurring subscriptions and one-time contributions are treated the same - both are made via single transactions and will be recorded via POSTing the donation data when the one-time contribution is made.

@danlipert
Copy link
Contributor Author

@danlipert still a WIP ?

Dang you're fast! Should be good to review now, but will hold off on adding the migration until we get closer to merging.

@danlipert
Copy link
Contributor Author

@danlipert still a WIP ?

Dang you're fast! Should be good to review now, but will hold off on adding the migration until we get closer to merging.

nevermind on holding off the migration, I see that it missing causes the tests to fail

@thelostone-mc thelostone-mc merged commit ac0248e into master Jul 28, 2019
danlipert added a commit that referenced this pull request Jul 29, 2019
@thelostone-mc thelostone-mc deleted the grants-data branch June 27, 2020 00:43
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants