feat: 🎸 Add capabilities to managed groups
Add capabilities to managed groups
This commit is contained in:
1 parent
7c762c1050
commit
8a11a76b49
7 files changed
+78
-21
No files matched your search
@@ -21,7 +21,13 @@ export default class ScopesScopeAuthMethodsAuthMethodManagedGroupsRoute extends
|
||||
model() {
|
||||
const authMethod = this.modelFor('scopes.scope.auth-methods.auth-method');
|
||||
const { id: auth_method_id } = authMethod;
|
||||
return this.store.query('managed-group', { auth_method_id });
|
||||
const canListManagedGroups = this.can.can('list collection', authMethod, {
|
||||
collection: 'managed-groups',
|
||||
});
|
||||
|
||||
if (canListManagedGroups) {
|
||||
return this.store.query('managed-group', { auth_method_id });
|
||||
}
|
||||
}
|
||||
|
||||
// =actions
|
||||
|
||||
Reference in new issue
Block a user