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

feat: Add Stripe_id to Django Admin #1104

Merged
merged 3 commits into from
Jan 17, 2025
Merged

Conversation

ajay-sentry
Copy link
Contributor

@ajay-sentry ajay-sentry commented Jan 16, 2025

Purpose/Motivation

This PR adds the ability to add and update a stripe_id for a plan on django admin. The field is not required, as it's not used for free plans.

This will allow us to remove these things:

STRIPE_PLAN_IDS = {
"users-pr-inappm": "price_1Gv2B8GlVGuVgOrkFnLunCgc",
"users-pr-inappy": "price_1Gv2COGlVGuVgOrkuOYVLIj7",
"users-sentrym": "price_1MlY9yGlVGuVgOrkHluurBtJ",
"users-sentryy": "price_1MlYAYGlVGuVgOrke9SdbBUn",
"users-enterprisey": "price_1LmjzwGlVGuVgOrkIwlM46EU",
"users-enterprisem": "price_1LmjypGlVGuVgOrkzKtNqhwW",
"users-teamm": "price_1NqPKdGlVGuVgOrkm9OFvtz8",
"users-teamy": "price_1NrlXiGlVGuVgOrkgMTw5yno",
}
STRIPE_PLAN_VALS = {
"price_1Gv2B8GlVGuVgOrkFnLunCgc": "users-pr-inappm",
"price_1Gv2COGlVGuVgOrkuOYVLIj7": "users-pr-inappy",
"price_1MlY9yGlVGuVgOrkHluurBtJ": "users-sentrym",
"price_1MlYAYGlVGuVgOrke9SdbBUn": "users-sentryy",
"price_1LmjzwGlVGuVgOrkIwlM46EU": "users-enterprisey",
"price_1LmjypGlVGuVgOrkzKtNqhwW": "users-enterprisem",
"price_1NqPKdGlVGuVgOrkm9OFvtz8": "users-teamm",
"price_1NrlXiGlVGuVgOrkgMTw5yno": "users-teamy",
}

Screenshot 2025-01-16 at 2 26 05 PM Screenshot 2025-01-16 at 2 27 03 PM

Legal Boilerplate

Look, I get it. The entity doing business as "Sentry" was incorporated in the State of Delaware in 2015 as Functional Software, Inc. In 2022 this entity acquired Codecov and as result Sentry is going to need some rights from me in order to utilize my contributions in this PR. So here's the deal: I retain all rights, title and interest in and to my contributions, and by keeping this boilerplate intact I confirm that Sentry can use, modify, copy, and redistribute my contributions, under Sentry's choice of terms.

Copy link
Contributor

github-actions bot commented Jan 16, 2025

This PR includes changes to shared. Please review them here: codecov/shared@b38e7f3...fe16480

"is_active",
"tier",
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

added tier and reordered the "billing" parts of the plan to be next to each other for slightly easier readability

@codecov-notifications
Copy link

codecov-notifications bot commented Jan 16, 2025

Codecov Report

All modified and coverable lines are covered by tests ✅

✅ All tests successful. No failed tests found.

📢 Thoughts on this report? Let us know!

Copy link
Contributor

✅ All tests successful. No failed tests were found.

📣 Thoughts on this report? Let Codecov know! | Powered by Codecov

Copy link

codecov bot commented Jan 16, 2025

Codecov Report

All modified and coverable lines are covered by tests ✅

Project coverage is 96.09%. Comparing base (bf0f1b2) to head (ba75daf).
Report is 1 commits behind head on main.

✅ All tests successful. No failed tests found.

Additional details and impacted files
@@           Coverage Diff           @@
##             main    #1104   +/-   ##
=======================================
  Coverage   96.09%   96.09%           
=======================================
  Files         832      832           
  Lines       19501    19501           
=======================================
  Hits        18740    18740           
  Misses        761      761           
Flag Coverage Δ
unit 96.01% <ø> (ø)
unit-latest-uploader 96.01% <ø> (ø)

Flags with carried forward coverage won't be shown. Click here to find out more.

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

@ajay-sentry ajay-sentry added this pull request to the merge queue Jan 17, 2025
Merged via the queue into main with commit ab5c1ff Jan 17, 2025
18 of 19 checks passed
@ajay-sentry ajay-sentry deleted the Ajay/add-stripe-id-django-admin branch January 17, 2025 00:50
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.

2 participants