1
0
Fork 0
mirror of synced 2024-06-30 03:50:37 +12:00

Fix user groups already assigned to an app not being filtered out

This commit is contained in:
Andrew Kingston 2022-09-23 15:42:44 +01:00
parent f6b52cf3f0
commit 5282bb29a3

View file

@ -39,6 +39,7 @@
$: fixedAppId = apps.getProdAppID(app.devId)
$: availableUsers = getAvailableUsers($usersFetch.rows, appUsers, data)
$: availableGroups = getAvailableGroups($groups, app.appId, search, data)
$: console.log(availableGroups)
$: valid = data?.length && !data?.some(x => !x.id?.length || !x.role?.length)
$: optionSections = {
...($licensing.groupsEnabled &&
@ -114,7 +115,7 @@
return (allGroups || []).filter(group => {
// Filter out assigned groups
const appIds = groups.actions.getGroupAppIds(group)
if (appIds.includes(appId)) {
if (appIds.includes(`app_${appId}`)) {
return false
}