-
Notifications
You must be signed in to change notification settings - Fork 2.7k
[MM-36235] - Do not allow to downgrade cloud plans #8268
Conversation
const options = Object.keys(products).map((key: string) => { | ||
return {key: products[key].name, value: products[key].id}; | ||
return {key: products[key].name, value: products[key].id, price: products[key].price_per_seat}; | ||
}).sort((a, b) => a.price - b.price).filter((option) => { | ||
return option.price >= this.state.currentProduct!.price_per_seat; |
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.
@AGMETEOR this code has now changed to consider the flat_fee
subscriptions in this PR: https://github.com/mattermost/mattermost-webapp/pull/8341/files#diff-acb502910cc86e76a73b356eba7ef5024d0db3aaa31441bbe70ff3c83dc164beR193-R206
We can now update this PR and consider not allowing them to downgrade but ONLY when you are upgrading (not the initial purchase from trial given that they may be in Enterprise and can select Starter to subscribe)
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.
I have updated the code
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.
LGTM!
@stevemudie I think this is a post merge QA review candidate |
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.
Will test post merge
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.
Great work @AGMETEOR!
const flatFeeProducts: ProductOptions = []; | ||
const userBasedProducts: ProductOptions = []; |
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.
Nice 👍
Summary
Currently, if the user is subscribed in the Starter or Professional, when the admin clicks the "Upgrade" button the purchase modal shows all options. They should only be presented with the higher options to upgrade (and the current plan for comparison)
Ticket Link
MM-36235
Related PRs
webapp
Release Note