-
Notifications
You must be signed in to change notification settings - Fork 1.4k
[PM-19180] Calculate sales tax correctly for sponsored plans #14129
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
base: main
Are you sure you want to change the base?
Conversation
Codecov ReportAttention: Patch coverage is
✅ All tests successful. No failed tests found.
Additional details and impacted files@@ Coverage Diff @@
## main #14129 +/- ##
==========================================
- Coverage 37.00% 36.99% -0.01%
==========================================
Files 3192 3192
Lines 92161 92159 -2
Branches 16545 16544 -1
==========================================
- Hits 34102 34098 -4
- Misses 55523 55525 +2
Partials 2536 2536 ☔ View full report in Codecov by Sentry. 🚀 New features to boost your workflow:
|
|
Great job, no security vulnerabilities found in this Pull Request |
@@ -682,11 +688,6 @@ export class OrganizationPlansComponent implements OnInit, OnDestroy { | |||
} | |||
|
|||
private refreshSalesTax(): void { | |||
if (this.formGroup.controls.plan.value == PlanType.Free) { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Removing this portion of code, wouldn't affect free. Were you able to test for free plan
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@cyprain-okeke It is not being called when the Free
plan is selected, likely because also all the billing address fields are unavailable. This results in an invalid form for the required address fields and won't calculate the sales tax.
🎟️ Tracking
https://bitwarden.atlassian.net/browse/PM-19180
📔 Objective
Sponsored organizations are created in two steps. The sponsorship is the second step where the familiy organization is converted into a family for enterprise organization which is free. Given how the code is otherwise written in the backend related to sponsorships, this proves rather challenging.
We also know we will still need to continue to charge sales tax correctly if the user buys additional storage. And we need to use the
PlanType
to correctly determine whether the product is for personal use or business use to apply to correct automatic tax rules in Stripe.Related: bitwarden/server#5611
📸 Screenshots
See https://bitwarden.atlassian.net/browse/PM-19180
⏰ Reminders before review
🦮 Reviewer guidelines
:+1:
) or similar for great changes:memo:
) or ℹ️ (:information_source:
) for notes or general info:question:
) for questions:thinking:
) or 💭 (:thought_balloon:
) for more open inquiry that's not quite a confirmed issue and could potentially benefit from discussion:art:
) for suggestions / improvements:x:
) or:warning:
) for more significant problems or concerns needing attention:seedling:
) or ♻️ (:recycle:
) for future improvements or indications of technical debt:pick:
) for minor or nitpick changes