X-Git-Url: https://git.arvados.org/arvados-workbench2.git/blobdiff_plain/b1b507febf56cb0622d3599ec68f276d9e0ce3d5..ff8e2c5d55ac3bf5d897c774879f5f544b518553:/src/views/group-details-panel/group-details-panel.tsx

diff --git a/src/views/group-details-panel/group-details-panel.tsx b/src/views/group-details-panel/group-details-panel.tsx
index 940f9d06..f81c2404 100644
--- a/src/views/group-details-panel/group-details-panel.tsx
+++ b/src/views/group-details-panel/group-details-panel.tsx
@@ -11,11 +11,13 @@ import { ResourceUuid, ResourceFirstName, ResourceLastName, ResourceEmail, Resou
 import { createTree } from '~/models/tree';
 import { noop } from 'lodash/fp';
 import { RootState } from '~/store/store';
-import { GROUP_DETAILS_PANEL_ID } from '~/store/group-details-panel/group-details-panel-actions';
+import { GROUP_DETAILS_PANEL_ID, openAddGroupMembersDialog } from '~/store/group-details-panel/group-details-panel-actions';
 import { openContextMenu } from '~/store/context-menu/context-menu-actions';
 import { ResourcesState, getResource } from '~/store/resources/resources';
 import { ContextMenuKind } from '~/views-components/context-menu/context-menu';
 import { PermissionResource } from '~/models/permission';
+import { Grid, Button } from '@material-ui/core';
+import { AddIcon } from '~/components/icon/icon';
 
 export enum GroupDetailsPanelColumnNames {
     FIRST_NAME = "First name",
@@ -71,10 +73,12 @@ const mapStateToProps = (state: RootState) => {
 
 const mapDispatchToProps = {
     onContextMenu: openContextMenu,
+    onAddUser: openAddGroupMembersDialog,
 };
 
-export interface GroupDetailsPanelProps { 
+export interface GroupDetailsPanelProps {
     onContextMenu: (event: React.MouseEvent<HTMLElement>, item: any) => void;
+    onAddUser: () => void;
     resources: ResourcesState;
 }
 
@@ -91,7 +95,18 @@ export const GroupDetailsPanel = connect(
                     onRowDoubleClick={noop}
                     onContextMenu={this.handleContextMenu}
                     contextMenuColumn={true}
-                    hideColumnSelector />
+                    hideColumnSelector
+                    hideSearchInput
+                    actions={
+                        <Grid container justify='flex-end'>
+                            <Button
+                                variant="contained"
+                                color="primary"
+                                onClick={this.props.onAddUser}>
+                                <AddIcon /> Add user
+                        </Button>
+                        </Grid>
+                    } />
             );
         }
 
