mirror of
https://github.com/windmill-labs/windmill.git
synced 2026-11-28 08:06:16 +00:00
feat: open a group's access from the groups page
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
co-authored by
Claude Opus 5.5
parent
1de7c5e3e4
commit
a3e115516f
@@ -7,6 +7,7 @@
|
||||
import { Button, Drawer, DrawerContent, Skeleton } from '$lib/components/common'
|
||||
import Dropdown from '$lib/components/DropdownV2.svelte'
|
||||
import GroupEditorDrawer from '$lib/components/GroupEditorDrawer.svelte'
|
||||
import AccessDrawer from '$lib/components/AccessDrawer.svelte'
|
||||
import InstanceGroupEditor from '$lib/components/InstanceGroupEditor.svelte'
|
||||
import GroupInfo from '$lib/components/GroupInfo.svelte'
|
||||
import PageHeader from '$lib/components/PageHeader.svelte'
|
||||
@@ -14,7 +15,7 @@
|
||||
import { userStore, workspaceStore, roleCapabilities } from '$lib/stores'
|
||||
import { useEditRights } from '$lib/operatorWriteRights'
|
||||
import { latestRequest } from '$lib/utils/latestRequest'
|
||||
import { Pen, Plus, Trash } from 'lucide-svelte'
|
||||
import { Pen, Plus, ShieldCheck, Trash } from 'lucide-svelte'
|
||||
import DataTable from '$lib/components/table/DataTable.svelte'
|
||||
import Head from '$lib/components/table/Head.svelte'
|
||||
import Cell from '$lib/components/table/Cell.svelte'
|
||||
@@ -32,6 +33,7 @@
|
||||
let groups: Group[] | undefined = $state(undefined)
|
||||
let instanceGroups: InstanceGroupWithWorkspaces[] | undefined = $state(undefined)
|
||||
let groupEditorDrawer: GroupEditorDrawer | undefined = $state()
|
||||
let accessDrawer: AccessDrawer | undefined = $state()
|
||||
|
||||
const groupLoads = latestRequest()
|
||||
async function loadGroups(): Promise<void> {
|
||||
@@ -61,6 +63,7 @@
|
||||
</script>
|
||||
|
||||
<GroupEditorDrawer bind:this={groupEditorDrawer} onSaved={loadGroups} />
|
||||
<AccessDrawer bind:this={accessDrawer} />
|
||||
|
||||
<Drawer bind:this={instanceGroupDrawer}>
|
||||
<DrawerContent
|
||||
@@ -153,6 +156,12 @@
|
||||
<Cell last actions shouldStopPropagation>
|
||||
<Dropdown
|
||||
items={[
|
||||
{
|
||||
displayName: 'Access',
|
||||
icon: ShieldCheck,
|
||||
hide: !($userStore?.is_admin || $userStore?.groups.includes(name)),
|
||||
action: () => accessDrawer?.open(`g/${name}`, 'group')
|
||||
},
|
||||
{
|
||||
displayName: 'Manage group',
|
||||
icon: Pen,
|
||||
|
||||
Reference in New Issue
Block a user