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

Add tracking cart functionality #6902

Merged
merged 7 commits into from
Jun 17, 2020
Merged

Conversation

zoek1
Copy link
Contributor

@zoek1 zoek1 commented Jun 17, 2020

Description

lets just make a grants.models.CartData object in the DB and store a JSON blob in it and a FK to the user. and do a POST request

Refers/Fixes

#6892

Testing

https://www.loom.com/share/fcafdd80c7124b0891010353c59d6cb7

@codecov
Copy link

codecov bot commented Jun 17, 2020

Codecov Report

Merging #6902 into stable will decrease coverage by 8.59%.
The diff coverage is 62.96%.

Impacted file tree graph

@@            Coverage Diff             @@
##           stable    #6902      +/-   ##
==========================================
- Coverage   26.93%   18.33%   -8.60%     
==========================================
  Files         297      285      -12     
  Lines       28373    28308      -65     
  Branches     4153     4148       -5     
==========================================
- Hits         7641     5190    -2451     
- Misses      20458    23101    +2643     
+ Partials      274       17     -257     
Impacted Files Coverage Δ
app/grants/urls.py 0.00% <ø> (-100.00%) ⬇️
app/grants/views.py 16.30% <27.27%> (-3.07%) ⬇️
app/grants/admin.py 42.93% <85.71%> (+1.65%) ⬆️
app/grants/models.py 41.69% <88.88%> (-5.30%) ⬇️
app/inbox/urls.py 0.00% <0.00%> (-100.00%) ⬇️
app/avatar/urls.py 0.00% <0.00%> (-100.00%) ⬇️
app/kudos/forms.py 0.00% <0.00%> (-100.00%) ⬇️
app/dashboard/abi.py 0.00% <0.00%> (-100.00%) ⬇️
app/avatar/serializers.py 0.00% <0.00%> (-100.00%) ⬇️
app/marketing/country_codes.py 0.00% <0.00%> (-100.00%) ⬇️
... and 90 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 c6eeea4...a253e1c. Read the comment docs.

@owocki
Copy link
Contributor

owocki commented Jun 17, 2020

hmmm this seems to work, but it requires someone on the backend to reassemble the cart from the activity to make sense of it.

seems itd be easier just to have 1 helper function that takes the entire cart data, serializes it, and sends it to the backend to be stored in a blob every time something changes.

@zoek1 zoek1 changed the base branch from master to stable June 17, 2020 15:00
@owocki owocki merged commit 9986e46 into gitcoinco:stable Jun 17, 2020
@mds1 mds1 mentioned this pull request Mar 4, 2021
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.

4 participants