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: update ConfigPolicies with docs link [CM-558] #10055

Merged
merged 5 commits into from
Oct 22, 2024
Merged

feat: update ConfigPolicies with docs link [CM-558] #10055

merged 5 commits into from
Oct 22, 2024

Conversation

johnkim-det
Copy link
Contributor

@johnkim-det johnkim-det commented Oct 15, 2024

Ticket

CM-558

Description

Adds docs link to Alert component, per JIRA ticket.

Also includes other ConfigPolicies changes:

  • Make sure that visiting the /policies route directly still checks permissions.
  • Remove "Global" from alert messages.

Screenshot 2024-10-15 at 10 34 34 AM
Screenshot 2024-10-15 at 10 34 24 AM
Screenshot 2024-10-15 at 10 34 08 AM
Screenshot 2024-10-15 at 10 34 04 AM

Test Plan

in EE only, should see valid docs link in Alert on Config Policies page and Config Policies tab on Workspace Details page. Admin should see the link in the Alert with the "Apply" button. Non-admin should see the link in the Alert without the "Apply" button.

Checklist

  • Changes have been manually QA'd
  • New features have been approved by the corresponding PM
  • User-facing API changes have the "User-facing API Change" label
  • Release notes have been added as a separate file under docs/release-notes/
    See Release Note for details.
  • Licenses have been included for new code which was copied and/or modified from any external code

@johnkim-det johnkim-det requested a review from a team as a code owner October 15, 2024 14:37
@johnkim-det johnkim-det requested a review from gt2345 October 15, 2024 14:37
@cla-bot cla-bot bot added the cla-signed label Oct 15, 2024
Copy link

netlify bot commented Oct 15, 2024

Deploy Preview for determined-ui ready!

Name Link
🔨 Latest commit 3b317fc
🔍 Latest deploy log https://app.netlify.com/sites/determined-ui/deploys/67101d3646f8b90008a87166
😎 Deploy Preview https://deploy-preview-10055--determined-ui.netlify.app
📱 Preview on mobile
Toggle QR Code...

QR Code

Use your smartphone camera to open QR code link.

To edit notification comments on pull requests, go to your Netlify site configuration.

Comment on lines +95 to +96
? 'Configuration policies are being applied to the cluster.'
: 'Configuration policies are being applied to the workspace.';
Copy link
Contributor Author

@johnkim-det johnkim-det Oct 15, 2024

Choose a reason for hiding this comment

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

Removed "Global" because it's incorrect for workspaces, and seemed unnecessary for cluster, @tara-det-ai lmk if that's a problem

Comment on lines +166 to +171
const docsLink = (
<Link external path={paths.docs('/manage/config-policies.html')} popout>
Learn more
</Link>
);

Copy link
Contributor Author

Choose a reason for hiding this comment

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

this PR is merge blocked on #9969, which will add this page to the docs

Copy link
Contributor

Choose a reason for hiding this comment

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

@johnkim-det johnkim-det requested a review from kkunapuli October 15, 2024 14:39
Copy link

codecov bot commented Oct 15, 2024

Codecov Report

Attention: Patch coverage is 47.36842% with 20 lines in your changes missing coverage. Please review.

Project coverage is 50.59%. Comparing base (2356f91) to head (3b317fc).
Report is 32 commits behind head on main.

Files with missing lines Patch % Lines
webui/react/src/pages/ConfigPoliciesPage.tsx 0.00% 12 Missing and 1 partial ⚠️
webui/react/src/components/ConfigPolicies.tsx 72.00% 7 Missing ⚠️
Additional details and impacted files
@@            Coverage Diff             @@
##             main   #10055      +/-   ##
==========================================
- Coverage   54.62%   50.59%   -4.03%     
==========================================
  Files        1260      950     -310     
  Lines      157621   129012   -28609     
  Branches     3632     3633       +1     
==========================================
- Hits        86102    65280   -20822     
+ Misses      71385    63598    -7787     
  Partials      134      134              
Flag Coverage Δ
harness ?
web 54.37% <47.36%> (-0.01%) ⬇️

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

Files with missing lines Coverage Δ
webui/react/src/components/ConfigPolicies.tsx 73.55% <72.00%> (-0.33%) ⬇️
webui/react/src/pages/ConfigPoliciesPage.tsx 0.00% <0.00%> (ø)

... and 310 files with indirect coverage changes

@johnkim-det johnkim-det requested a review from tara-hpe October 15, 2024 14:45
@johnkim-det
Copy link
Contributor Author

added additional fix here to disable Apply button on successful submit

Copy link
Contributor

@tara-hpe tara-hpe left a comment

Choose a reason for hiding this comment

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

LGTM

@johnkim-det johnkim-det merged commit 1f2bea0 into main Oct 22, 2024
82 of 94 checks passed
@johnkim-det johnkim-det deleted the CM-558 branch October 22, 2024 15:47
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants