Skip to content

Commit

Permalink
feat: disable yaml network edit for restricted permissions
Browse files Browse the repository at this point in the history
Signed-off-by: Mason Hu <[email protected]>
  • Loading branch information
MasWho committed Feb 19, 2025
1 parent a6894e0 commit 82aac9b
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions src/pages/networks/forms/NetworkForm.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -321,6 +321,8 @@ const NetworkForm: FC<Props> = ({
ensureEditMode(formik);
void formik.setFieldValue("yaml", yaml);
}}
readOnly={!!formik.values.editRestriction}
readOnlyMessage={{ value: formik.values.editRestriction ?? "" }}
>
<YamlNotification
entity="network"
Expand Down

0 comments on commit 82aac9b

Please sign in to comment.