Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

feat(site): show license utilization in general settings#15683

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 ourterms of service andprivacy statement. We’ll occasionally send you account related emails.

Already on GitHub?Sign in to your account

Merged
SasSwart merged 5 commits intomainfromjjs/15297
Dec 2, 2024

Conversation

SasSwart
Copy link
Contributor

@SasSwartSasSwart commentedNov 29, 2024
edited
Loading

This PR is the first iteration towards#15297

We cannot yet show license utilization over time, so we show current license utilization.
This is because we don't track user states over time. We only track the current user state. A graph over time filtering by active users would therefore not account for day to day changes in user state and be inaccurate.
DB schema migrations and related updates will follow that allow us to show license utilization over time.

image

@SasSwartSasSwart marked this pull request as ready for reviewNovember 29, 2024 09:38
@github-actionsGitHub Actions
Copy link

github-actionsbot commentedNov 29, 2024
edited
Loading


✔️ PR 15683 Updated successfully.
🚀 Access the credentialshere.

cc:@SasSwart

github-actions[bot] reacted with rocket emoji

@SasSwartSasSwart requested review fromjohnstcn and removed request forBrunoQuaresmaNovember 29, 2024 11:10
Comment on lines 84 to 85
{entitlements!.features.user_limit.actual}/
{entitlements!.features.user_limit.limit} users)
Copy link
Member

Choose a reason for hiding this comment

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

Would it make sense to give these a similar treatment tolicenseUtilizationPercentage and check if we can evaluate them based on whetherentitlements is nil?

Copy link
Member

@mafredrimafredri left a comment

Choose a reason for hiding this comment

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

Just a minor suggestion, otherwise LGTM (deferring approval for fe).

entitlements?.features?.user_limit?.limit
? entitlements.features.user_limit.actual /
entitlements.features.user_limit.limit
: undefined;
Copy link
Member

@mafredrimafredriNov 29, 2024
edited
Loading

Choose a reason for hiding this comment

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

Suggestion: Instead of just doing the percentage here, we could prepare the data format in a more convenient way to use in the template:

constlicenseInfo=entitlements?.features?.user_limit?.actual&&entitlements?.features?.user_limit?.limit?{valid:true,actual:entitlements.features.user_limit.actual,limit:entitlements.features.user_limit.limit} :{valid:false,actual:0,limit:0,};

Might not need to even init the actual/limit for the zero case but added it just in case.

Copy link
Member

@johnstcnjohnstcn left a comment

Choose a reason for hiding this comment

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

Approving to unblock.

Copy link
Collaborator

@BrunoQuaresmaBrunoQuaresma left a comment

Choose a reason for hiding this comment

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

It looks good to me. Thanks for digging into the problem and finding the right solution.

One minor thing, that we can do after merge, is to improve the design a bit. cc.:@chrifro

chrifro reacted with thumbs up emoji
Copy link
Member

@aslilacaslilac left a comment

Choose a reason for hiding this comment

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

nice!

@@ -42,6 +42,7 @@ const meta: Meta<typeof GeneralSettingsPageView> = {
deploymentDAUs: MockDeploymentDAUResponse,
invalidExperiments: [],
safeExperiments: [],
entitlements: undefined,
Copy link
Member

Choose a reason for hiding this comment

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

Suggested change
entitlements: undefined,

undefined is JavaScript's equivalent to a zero value, this doesn't do anything

…ralSettingsPageView.tsxCo-authored-by: ケイラ <mckayla@hey.com>
@SasSwartSasSwart merged commit7e1ac2e intomainDec 2, 2024
28 checks passed
@SasSwartSasSwart deleted the jjs/15297 branchDecember 2, 2024 19:27
stirby pushed a commit that referenced this pull requestDec 2, 2024
This PR is the first iteration towards#15297We cannot yet show license utilization over time, so we show currentlicense utilization.This is because we don't track user states over time. We only track thecurrent user state. A graph over time filtering by active users wouldtherefore not account for day to day changes in user state and beinaccurate.DB schema migrations and related updates will follow that allow us toshow license utilization over time.![image](https://github.com/user-attachments/assets/91bd6e8c-e74c-4ef5-aa6b-271fd245da37)---------Co-authored-by: ケイラ <mckayla@hey.com>(cherry picked from commit7e1ac2e)
stirby added a commit that referenced this pull requestDec 3, 2024
-#15589-#15683-#15671---------Co-authored-by: Hugo Dutka <hugo@coder.com>Co-authored-by: Sas Swart <sas.swart.cdk@gmail.com>Co-authored-by: Spike Curtis <spike@coder.com>Co-authored-by: Cian Johnston <cian@coder.com>
Sign up for freeto join this conversation on GitHub. Already have an account?Sign in to comment
Reviewers

@mafredrimafredrimafredri left review comments

@aslilacaslilacaslilac approved these changes

@BrunoQuaresmaBrunoQuaresmaBrunoQuaresma approved these changes

@johnstcnjohnstcnjohnstcn approved these changes

Assignees

@SasSwartSasSwart

Labels
None yet
Projects
None yet
Milestone
No milestone
Development

Successfully merging this pull request may close these issues.

5 participants
@SasSwart@mafredri@aslilac@BrunoQuaresma@johnstcn

[8]ページ先頭

©2009-2025 Movatter.jp