fix: add isCreator role by default when creating new role

This commit is contained in:
kasia.oczkowska
2024-10-11 15:18:24 +01:00
parent fac4339207
commit 7885de36a9
5 changed files with 79 additions and 21 deletions

View File

@@ -25,7 +25,6 @@ function PermissionSettings(props) {
subject,
actions,
conditions,
defaultChecked,
} = props;
const formatMessage = useFormatMessage();
const { getValues, resetField } = useFormContext();
@@ -106,7 +105,6 @@ function PermissionSettings(props) {
dataTest={`${
condition.key
}-${action.key.toLowerCase()}-checkbox`}
defaultValue={defaultChecked}
disabled={
getValues(
`${fieldPrefix}.${action.key}.value`,
@@ -144,7 +142,6 @@ PermissionSettings.propTypes = {
fieldPrefix: PropTypes.string.isRequired,
subject: PropTypes.string.isRequired,
open: PropTypes.bool,
defaultChecked: PropTypes.bool,
actions: PropTypes.arrayOf(
PropTypes.shape({
label: PropTypes.string,