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 enforcement of seats to EE #15734
Conversation
Co-authored-by: Gustav Hansen <gu@stav.dev>
Codecov ReportBase: 58.41% // Head: 58.46% // Increases project coverage by
Additional details and impacted files@@ Coverage Diff @@
## releases/4.7.0 #15734 +/- ##
==================================================
+ Coverage 58.41% 58.46% +0.04%
==================================================
Files 1545 1552 +7
Lines 38203 38305 +102
Branches 7514 7536 +22
==================================================
+ Hits 22317 22395 +78
- Misses 13593 13617 +24
Partials 2293 2293
Flags with carried forward coverage won't be shown. Click here to find out more.
Help us with your feedback. Take ten seconds to tell us how you rate us. Have a feature suggestion? Share it here. ☔ View full report at Codecov. |
Co-authored-by: Josh Ellis <josh.ellis@strapi.io>
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 think for me the main thing that is missing is some tests for the hooks:
- useLicenseLimitNotification
- useLicenseLimits
andAdminSeatInfo
/CreateAction
– I don't think this would take too long to be honest
I've left some suggestions about imports, may seem superfluous but eventually we will stop supporting the direct import paths as they're not necessary for bundle size anymore :)
packages/core/admin/ee/admin/pages/SettingsPage/pages/Users/ListPage/CreateAction/index.js
Outdated
Show resolved
Hide resolved
packages/core/admin/ee/admin/pages/SettingsPage/pages/Users/ListPage/CreateAction/index.js
Outdated
Show resolved
Hide resolved
...min/ee/admin/pages/SettingsPage/pages/ApplicationInfosPage/components/AdminSeatInfo/index.js
Outdated
Show resolved
Hide resolved
...min/ee/admin/pages/SettingsPage/pages/ApplicationInfosPage/components/AdminSeatInfo/index.js
Outdated
Show resolved
Hide resolved
…stPage/CreateAction/index.js Co-authored-by: Josh <37798644+joshuaellis@users.noreply.github.com>
…stPage/CreateAction/index.js Co-authored-by: Josh <37798644+joshuaellis@users.noreply.github.com>
…ionInfosPage/components/AdminSeatInfo/index.js Co-authored-by: Josh <37798644+joshuaellis@users.noreply.github.com>
…ionInfosPage/components/AdminSeatInfo/index.js Co-authored-by: Josh <37798644+joshuaellis@users.noreply.github.com>
packages/core/admin/admin/src/components/Notifications/Notification/index.js
Show resolved
Hide resolved
packages/core/admin/ee/admin/pages/SettingsPage/pages/Users/ListPage/CreateAction/index.js
Outdated
Show resolved
Hide resolved
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.
Apart from the URLs mention, from an FE perspective I'm happy with this :)
Hey @joshuaellis the plans for urls was to create a small app that would redirect users to the correct payment portal depending on cloud/self hosted and if they wanted to pay by card/wire transfer. The app would have eventually grown into strapi portal that would be a wrapper for strapi services payments, but in the beginning it would be just redirecting. We started working on it on Monday, so I pushed the code to strap/portal repo. Feel free to check it out if you want, it's a simple next app |
@joshuaellis & @gu-stav I added rbac checks to avoid making an API call that wouldn't work. As the code was only using hooks I went with the useQuery @Marc-Roig & @Convly I updated the backend code and fixed a few things. You can look at the commits to see the differences. |
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.
FE looks good to me
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, what I miss are some tests, that we could add in another PR.
💯 |
😌 |
What does it do?
PR adds enforcement of seats workflow to the Admin package and adds several changes to the core strapi package in order to accommodate enforcement of seats workflow.
Why is it needed?
These changes will enforce the number of users in EE mode in accordance with the project license.
How to test it?
Run the branch in development with the license: run
examples/getstarted
for server andpackages/core/admin
for admin panel. You will have to setpermittedSeats
to a chosen number manually, just search for the variable name. Then, try to add more users than thepermitteSeats
number.