X-Git-Url: https://git.arvados.org/arvados-workbench2.git/blobdiff_plain/75e44c796b346740fd52908bef24d913e4e084ae..9eaee66663fa21962f46e301ba6257ab63a9b10c:/src/views/trash-panel/trash-panel.tsx diff --git a/src/views/trash-panel/trash-panel.tsx b/src/views/trash-panel/trash-panel.tsx index 420d650d..a0cf3e4f 100644 --- a/src/views/trash-panel/trash-panel.tsx +++ b/src/views/trash-panel/trash-panel.tsx @@ -63,20 +63,20 @@ export const ResourceRestore = const resource = getResource(props.uuid)(state.resources); return { resource, dispatch: props.dispatch }; })((props: { resource?: TrashableResource, dispatch?: Dispatch }) => - { - if (props.resource && props.dispatch) { - props.dispatch(toggleTrashed( - props.resource.kind, - props.resource.uuid, - props.resource.ownerUuid, - props.resource.isTrashed - )); - } - }}> - + + { + if (props.resource && props.dispatch) { + props.dispatch(toggleTrashed( + props.resource.kind, + props.resource.uuid, + props.resource.ownerUuid, + props.resource.isTrashed + )); + }}} + > - - + + ); export const trashPanelColumns: DataColumns = [ @@ -99,11 +99,6 @@ export const trashPanelColumns: DataColumns = [ selected: true, type: ResourceKind.COLLECTION }, - { - name: resourceLabel(ResourceKind.PROCESS), - selected: true, - type: ResourceKind.PROCESS - }, { name: resourceLabel(ResourceKind.PROJECT), selected: true, @@ -160,23 +155,17 @@ export const TrashPanel = withStyles(styles)( }))( class extends React.Component { render() { - return this.hasAnyTrashedResources() - ? } /> - : ; - } - - hasAnyTrashedResources = () => { - // TODO: implement check if there is anything in the trash, - // without taking pagination into the account - return true; + return + } />; } handleContextMenu = (event: React.MouseEvent, resourceUuid: string) => { @@ -191,6 +180,7 @@ export const TrashPanel = withStyles(styles)( menuKind: ContextMenuKind.TRASH })); } + this.props.dispatch(loadDetailsPanel(resourceUuid)); } handleRowDoubleClick = (uuid: string) => {