[ARVADOS-WORKBENCH2] updated: 1.3.1-451-g2a60ee74
Git user
git at public.curoverse.com
Mon May 13 20:30:44 UTC 2019
Summary of changes:
src/views/search-results-panel/search-results-panel-view.tsx | 10 ++++++++--
src/views/search-results-panel/search-results-panel.tsx | 3 ++-
2 files changed, 10 insertions(+), 3 deletions(-)
via 2a60ee742601aec7a0bc6ee832da39d834d82eb7 (commit)
from 59000cfd2934a50da18b5e70fd14f12abd020eb7 (commit)
Those revisions listed above that are new to this repository have
not appeared on any other notification email; so we list those
revisions in full, below.
commit 2a60ee742601aec7a0bc6ee832da39d834d82eb7
Author: Peter Amstutz <pamstutz at veritasgenetics.com>
Date: Mon May 13 16:15:47 2019 -0400
15064: Send user home for multi-site search.
Arvados-DCO-1.1-Signed-off-by: Peter Amstutz <pamstutz at veritasgenetics.com>
diff --git a/src/views/search-results-panel/search-results-panel-view.tsx b/src/views/search-results-panel/search-results-panel-view.tsx
index 06312799..df6a7e8c 100644
--- a/src/views/search-results-panel/search-results-panel-view.tsx
+++ b/src/views/search-results-panel/search-results-panel-view.tsx
@@ -41,6 +41,7 @@ export interface SearchResultsPanelDataProps {
user: User;
sessions: Session[];
remoteHostsConfig: { [key: string]: Config };
+ localCluster: string;
}
export interface SearchResultsPanelActionProps {
@@ -118,6 +119,7 @@ export const searchResultsPanelColumns: DataColumns<string> = [
];
export const SearchResultsPanelView = (props: SearchResultsPanelProps) => {
+ const homeCluster = props.user.uuid.substr(0, 5);
return <DataExplorer
id={SEARCH_RESULTS_PANEL_ID}
onRowClick={props.onItemClick}
@@ -125,6 +127,10 @@ export const SearchResultsPanelView = (props: SearchResultsPanelProps) => {
onContextMenu={props.onContextMenu}
contextMenuColumn={true}
hideSearchInput
- header={<p>Searching {props.sessions.filter((ss) => ss.loggedIn).map((ss) => <span key={ss.clusterId}> {ss.clusterId}</span>)}
- </p>} />;
+ header={
+ props.localCluster === homeCluster ?
+ <p>Searching clusters: {props.sessions.filter((ss) => ss.loggedIn).map((ss) => <span key={ss.clusterId}> {ss.clusterId}</span>)}</p> :
+ <p>Searching local cluster {props.localCluster} only. To search multiple clusters, <a href={props.remoteHostsConfig[homeCluster] && props.remoteHostsConfig[homeCluster].workbench2Url}> start from your home Workbench.</a></p>
+ }
+ />;
};
diff --git a/src/views/search-results-panel/search-results-panel.tsx b/src/views/search-results-panel/search-results-panel.tsx
index 8fa0828b..bde7207a 100644
--- a/src/views/search-results-panel/search-results-panel.tsx
+++ b/src/views/search-results-panel/search-results-panel.tsx
@@ -16,7 +16,8 @@ const mapStateToProps = (rootState: RootState) => {
return {
user: rootState.auth.user,
sessions: rootState.auth.sessions,
- remoteHostsConfig: rootState.auth.remoteHostsConfig
+ remoteHostsConfig: rootState.auth.remoteHostsConfig,
+ localCluster: rootState.auth.localCluster,
};
};
-----------------------------------------------------------------------
hooks/post-receive
--
More information about the arvados-commits
mailing list