From 472d523038ec66e2d290ae779089994e39037fc4 Mon Sep 17 00:00:00 2001 From: KelvinTegelaar Date: Fri, 31 May 2024 20:42:32 +0200 Subject: [PATCH 1/4] fixes errormessages not showing up --- src/views/cipp/app-settings/SettingsGeneral.jsx | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/views/cipp/app-settings/SettingsGeneral.jsx b/src/views/cipp/app-settings/SettingsGeneral.jsx index 04446add8ceb..346f1ac3fe53 100644 --- a/src/views/cipp/app-settings/SettingsGeneral.jsx +++ b/src/views/cipp/app-settings/SettingsGeneral.jsx @@ -253,7 +253,7 @@ export function SettingsGeneral() { - {permissionsResult.data.Results?.ErrorMessages?.length > 0 || + {permissionsResult.data.Results?.ErrorMessages?.length >= 0 || (permissionsResult.data.Results?.MissingPermissions.length > 0 && ( <> From 01dc70a15eae4250304f5c6c70fb43c3a59cdb5b Mon Sep 17 00:00:00 2001 From: KelvinTegelaar Date: Fri, 31 May 2024 21:07:59 +0200 Subject: [PATCH 2/4] update settings --- src/views/cipp/app-settings/SettingsGeneral.jsx | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/views/cipp/app-settings/SettingsGeneral.jsx b/src/views/cipp/app-settings/SettingsGeneral.jsx index 346f1ac3fe53..bb0d16b4946b 100644 --- a/src/views/cipp/app-settings/SettingsGeneral.jsx +++ b/src/views/cipp/app-settings/SettingsGeneral.jsx @@ -253,7 +253,7 @@ export function SettingsGeneral() { - {permissionsResult.data.Results?.ErrorMessages?.length >= 0 || + {permissionsResult.data.Results?.ErrorMessages?.length || (permissionsResult.data.Results?.MissingPermissions.length > 0 && ( <> From 180f176fe6f1e55692de09a044973d88aaf71ad2 Mon Sep 17 00:00:00 2001 From: KelvinTegelaar Date: Fri, 31 May 2024 21:20:03 +0200 Subject: [PATCH 3/4] permissions fix --- .../cipp/app-settings/SettingsGeneral.jsx | 58 +++++++++---------- 1 file changed, 29 insertions(+), 29 deletions(-) diff --git a/src/views/cipp/app-settings/SettingsGeneral.jsx b/src/views/cipp/app-settings/SettingsGeneral.jsx index bb0d16b4946b..fc5472998bc8 100644 --- a/src/views/cipp/app-settings/SettingsGeneral.jsx +++ b/src/views/cipp/app-settings/SettingsGeneral.jsx @@ -253,37 +253,37 @@ export function SettingsGeneral() { - {permissionsResult.data.Results?.ErrorMessages?.length || - (permissionsResult.data.Results?.MissingPermissions.length > 0 && ( - + {(permissionsResult.data.Results?.ErrorMessages?.length >= 0 || + permissionsResult.data.Results?.MissingPermissions.length > 0) && ( + + <> + {permissionsResult.data.Results?.ErrorMessages?.map((m, idx) => ( +
{m}
+ ))} + + {permissionsResult.data.Results?.MissingPermissions.length > 0 && ( <> - {permissionsResult.data.Results?.ErrorMessages?.map((m, idx) => ( -
{m}
- ))} + Your Secure Application Model is missing the following permissions. See + the documentation on how to add permissions{' '} + + here + + . + + {permissionsResult.data.Results?.MissingPermissions?.map( + (r, index) => ( + {r} + ), + )} + - {permissionsResult.data.Results?.MissingPermissions.length > 0 && ( - <> - Your Secure Application Model is missing the following permissions. - See the documentation on how to add permissions{' '} - - here - - . - - {permissionsResult.data.Results?.MissingPermissions?.map( - (r, index) => ( - {r} - ), - )} - - - )} -
- ))} + )} +
+ )}
From 900c00705b2d58c5935a08ea0425464f5c5e3d3f Mon Sep 17 00:00:00 2001 From: KelvinTegelaar Date: Fri, 31 May 2024 21:29:22 +0200 Subject: [PATCH 4/4] fixed --- src/views/cipp/app-settings/SettingsGeneral.jsx | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/views/cipp/app-settings/SettingsGeneral.jsx b/src/views/cipp/app-settings/SettingsGeneral.jsx index fc5472998bc8..b5dd40624064 100644 --- a/src/views/cipp/app-settings/SettingsGeneral.jsx +++ b/src/views/cipp/app-settings/SettingsGeneral.jsx @@ -253,7 +253,7 @@ export function SettingsGeneral() { - {(permissionsResult.data.Results?.ErrorMessages?.length >= 0 || + {(permissionsResult.data.Results?.ErrorMessages?.length > 0 || permissionsResult.data.Results?.MissingPermissions.length > 0) && ( <>