ResourceIsAdmin,
ResourceUsername
} from "views-components/data-explorer/renderers";
-import { navigateTo } from "store/navigation/navigation-action";
+import { navigateToUserProfile } from "store/navigation/navigation-action";
import { ContextMenuKind } from "views-components/context-menu/context-menu";
import { DataTableDefaultView } from 'components/data-table-default-view/data-table-default-view';
import { createTree } from 'models/tree';
interface UserPanelActionProps {
openUserCreateDialog: () => void;
- handleRowDoubleClick: (uuid: string) => void;
+ handleRowClick: (uuid: string) => void;
onContextMenu: (event: React.MouseEvent<HTMLElement>, item: any) => void;
}
const mapDispatchToProps = (dispatch: Dispatch) => ({
openUserCreateDialog: () => dispatch<any>(openUserCreateDialog()),
- handleRowDoubleClick: (uuid: string) => dispatch<any>(navigateTo(uuid)),
+ handleRowClick: (uuid: string) => dispatch<any>(navigateToUserProfile(uuid)),
onContextMenu: (event: React.MouseEvent<HTMLElement>, item: any) => dispatch<any>(openContextMenu(event, item))
});
render() {
const { value } = this.state;
return <Paper className={this.props.classes.root}>
- <Tabs value={value} onChange={this.handleChange} fullWidth>
+ <Tabs value={value} onChange={this.handleChange} variant={"fullWidth"}>
<Tab label="USERS" />
<Tab label="ACTIVITY" disabled />
</Tabs>
<div className={this.props.classes.content}>
<DataExplorer
id={USERS_PANEL_ID}
- onRowClick={noop}
+ onRowClick={this.props.handleRowClick}
onRowDoubleClick={noop}
onContextMenu={this.handleContextMenu}
contextMenuColumn={true}
}
handleContextMenu = (event: React.MouseEvent<HTMLElement>, resourceUuid: string) => {
+ event.stopPropagation();
const resource = getResource<UserResource>(resourceUuid)(this.props.resources);
if (resource) {
this.props.onContextMenu(event, {