[ARVADOS-WORKBENCH2] updated: 1.1.4-440-g7ae86ef

Git user git at public.curoverse.com
Mon Jul 30 07:32:48 EDT 2018


Summary of changes:
 .env                                               |  3 +-
 src/common/api/server-api.ts                       | 21 ++++++++-----
 src/common/config.ts                               | 17 +++++++----
 src/common/labels.ts                               |  6 ++--
 src/components/data-table/data-column.ts           | 14 ++++-----
 src/components/data-table/data-table.test.tsx      |  4 +--
 src/components/data-table/data-table.tsx           |  4 +--
 src/components/tree/tree.tsx                       | 11 ++++---
 src/models/collection.ts                           |  2 +-
 src/models/container-request.ts                    |  8 ++---
 src/models/group.ts                                |  4 +--
 src/models/project.ts                              |  2 +-
 src/models/resource.ts                             | 12 ++++----
 src/models/test-utils.ts                           |  4 +--
 src/models/workflow.ts                             |  2 +-
 src/services/auth-service/auth-service.ts          | 10 ++++---
 .../favorite-service/favorite-order-builder.ts     | 12 ++++----
 src/services/groups-service/groups-service.ts      |  6 ++--
 src/services/project-service/project-service.ts    |  4 +--
 src/services/services.ts                           | 12 ++++----
 src/store/auth/auth-reducer.test.ts                |  5 ++--
 .../collection-panel/collection-panel-action.ts    |  4 +--
 .../data-explorer/data-explorer-reducer.test.tsx   |  4 +--
 src/store/details-panel/details-panel-action.ts    | 12 ++++----
 .../favorite-panel/favorite-panel-middleware.ts    | 10 +++----
 src/store/navigation/navigation-action.ts          | 13 ++++-----
 .../project-panel/project-panel-middleware.ts      | 18 ++++++------
 src/store/project/project-reducer.test.ts          | 19 +++++-------
 src/store/project/project-reducer.ts               |  8 ++---
 src/store/side-panel/side-panel-reducer.ts         | 24 +++++++--------
 .../details-panel/collection-details.tsx           |  2 +-
 .../details-panel/details-panel.tsx                |  6 ++--
 .../details-panel/process-details.tsx              |  2 +-
 .../details-panel/project-details.tsx              |  2 +-
 src/views/favorite-panel/favorite-panel-item.ts    |  2 +-
 src/views/favorite-panel/favorite-panel.tsx        | 34 +++++++++++-----------
 src/views/project-panel/project-panel-item.ts      |  2 +-
 src/views/project-panel/project-panel.tsx          | 34 +++++++++++-----------
 src/views/workbench/workbench.tsx                  | 23 ++++++++-------
 39 files changed, 196 insertions(+), 186 deletions(-)

       via  7ae86efd9905582df4191910528c3803a68ba81b (commit)
       via  750ece46ef69eec338523c63c834cd87901c1342 (commit)
       via  799fc95935bf7a51a4b1f0a224f538867d3d464d (commit)
       via  5a41552ba5844ea1f7c5065674dd812adb5915d7 (commit)
       via  f626dd268140b4ef406a2ec0c6568f6ca0298e1d (commit)
       via  a080578919155fc6f6d1be2f966951b629ae5b45 (commit)
       via  1feb5aaffe6fee4a9c8c8c64877f1da6f3490e06 (commit)
       via  f7cf9da472181411b7faaebd02008f012b247a94 (commit)
       via  362a1f5afe16f1b9c13b6d3c9fc2638ef0b7bf43 (commit)
       via  044eba18bb2cdc9d3633deef5e91b7eac2a03ac4 (commit)
       via  2badeb3fe6beb308b952ab2b7101ed4547c04e10 (commit)
      from  3ee31ce16470660d90fb870e048c2de9fcde6e47 (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 7ae86efd9905582df4191910528c3803a68ba81b
Merge: 3ee31ce 750ece4
Author: Janicki Artur <artur.janicki at contractors.roche.com>
Date:   Mon Jul 30 13:28:09 2018 +0200

    Merge branch 'master' into 13853-collection-view-info-card
    
    refs #13853
    
    Arvados-DCO-1.1-Signed-off-by: Janicki Artur <artur.janicki at contractors.roche.com>

diff --cc src/models/project.ts
index d3626d3,eaf6090..b919450
--- a/src/models/project.ts
+++ b/src/models/project.ts
@@@ -5,9 -5,5 +5,9 @@@
  import { GroupResource, GroupClass } from "./group";
  
  export interface ProjectResource extends GroupResource {
-     groupClass: GroupClass.Project;
+     groupClass: GroupClass.PROJECT;
  }
 +
 +export const getProjectUrl = (uuid: string) => {
 +    return `/projects/${uuid}`;
 +};
diff --cc src/services/services.ts
index f0afd76,a08ed3c..e0d15cc
--- a/src/services/services.ts
+++ b/src/services/services.ts
@@@ -9,8 -9,8 +9,8 @@@ import { ProjectService } from "./proje
  import { LinkService } from "./link-service/link-service";
  import { FavoriteService } from "./favorite-service/favorite-service";
  
- export const authService = new AuthService(serverApi);
- export const groupsService = new GroupsService(serverApi);
- export const projectService = new ProjectService(serverApi);
- export const linkService = new LinkService(serverApi);
- export const favoriteService = new FavoriteService(linkService, groupsService);
+ export const authService = new AuthService(authClient, apiClient);
+ export const groupsService = new GroupsService(apiClient);
+ export const projectService = new ProjectService(apiClient);
+ export const linkService = new LinkService(apiClient);
 -export const favoriteService = new FavoriteService(linkService, groupsService);
++export const favoriteService = new FavoriteService(linkService, groupsService);
diff --cc src/store/collection-panel/collection-panel-action.ts
index c2684e0,0000000..3c66016
mode 100644,000000..100644
--- a/src/store/collection-panel/collection-panel-action.ts
+++ b/src/store/collection-panel/collection-panel-action.ts
@@@ -1,30 -1,0 +1,30 @@@
 +// Copyright (C) The Arvados Authors. All rights reserved.
 +//
 +// SPDX-License-Identifier: AGPL-3.0
 +
 +import { unionize, ofType, UnionOf } from "unionize";
 +import { CommonResourceService } from "../../common/api/common-resource-service";
++import { apiClient } from "../../common/api/server-api";
 +import { Dispatch } from "redux";
- import { serverApi } from "../../common/api/server-api";
 +import { ResourceKind } from "../../models/resource";
 +import { CollectionResource } from "../../models/collection";
 +
 +export const collectionPanelActions = unionize({
 +    LOAD_COLLECTION: ofType<{ uuid: string, kind: ResourceKind }>(),
 +    LOAD_COLLECTION_SUCCESS: ofType<{ item: CollectionResource }>(),
 +}, { tag: 'type', value: 'payload' });
 +
 +export type CollectionPanelAction = UnionOf<typeof collectionPanelActions>;
 +
 +export const loadCollection = (uuid: string, kind: ResourceKind) =>
 +    (dispatch: Dispatch) => {
 +        dispatch(collectionPanelActions.LOAD_COLLECTION({ uuid, kind }));
-         return new CommonResourceService(serverApi, "collections")
++        return new CommonResourceService(apiClient, "collections")
 +            .get(uuid)
 +            .then(item => {
 +                dispatch(collectionPanelActions.LOAD_COLLECTION_SUCCESS({ item: item as CollectionResource }));
 +            });
 +    };
 +
 +
 +
diff --cc src/store/navigation/navigation-action.ts
index d65685d,5208623..f8687ed
--- a/src/store/navigation/navigation-action.ts
+++ b/src/store/navigation/navigation-action.ts
@@@ -16,8 -14,8 +16,8 @@@ import { getProjectUrl } from "../../mo
  
  export const getResourceUrl = <T extends Resource>(resource: T): string => {
      switch (resource.kind) {
-         case ResourceKind.Project: return getProjectUrl(resource.uuid);
-         case ResourceKind.Collection: return getCollectionUrl(resource.uuid);
 -        case ResourceKind.PROJECT: return `/projects/${resource.uuid}`;
 -        case ResourceKind.COLLECTION: return `/collections/${resource.uuid}`;
++        case ResourceKind.PROJECT: return getProjectUrl(resource.uuid);
++        case ResourceKind.COLLECTION: return getCollectionUrl(resource.uuid);
          default: return resource.href;
      }
  };
diff --cc src/views/workbench/workbench.tsx
index 6c7f85d,3637528..e252440
--- a/src/views/workbench/workbench.tsx
+++ b/src/views/workbench/workbench.tsx
@@@ -231,21 -227,10 +231,22 @@@ export const Workbench = withStyles(sty
                  );
              }
  
 +            renderCollectionPanel = (props: RouteComponentProps<{ id: string }>) => <CollectionPanel 
-                 onItemRouteChange={(collectionId) => this.props.dispatch<any>(loadCollection(collectionId, ResourceKind.Collection))}
++                onItemRouteChange={(collectionId) => this.props.dispatch<any>(loadCollection(collectionId, ResourceKind.COLLECTION))}
 +                onContextMenu={(event, item) => {
 +                    this.openContextMenu(event, {
 +                        uuid: item.uuid,
 +                        name: item.name,
 +                        kind: ContextMenuKind.COLLECTION
 +                    });
 +                }}
 +                {...props} />
 +
              renderProjectPanel = (props: RouteComponentProps<{ id: string }>) => <ProjectPanel
                  onItemRouteChange={itemId => this.props.dispatch<any>(setProjectItem(itemId, ItemMode.ACTIVE))}
                  onContextMenu={(event, item) => {
-                     const kind = item.kind === ResourceKind.Project ? ContextMenuKind.PROJECT : ContextMenuKind.RESOURCE;
++
+                     const kind = item.kind === ResourceKind.PROJECT ? ContextMenuKind.PROJECT : ContextMenuKind.RESOURCE;
                      this.openContextMenu(event, {
                          uuid: item.uuid,
                          name: item.name,
@@@ -257,14 -242,8 +258,15 @@@
                      this.props.dispatch<any>(loadDetails(item.uuid, item.kind as ResourceKind));
                  }}
                  onItemDoubleClick={item => {
 -                    this.props.dispatch<any>(setProjectItem(item.uuid, ItemMode.ACTIVE));
 -                    this.props.dispatch<any>(loadDetails(item.uuid, ResourceKind.PROJECT));
 +                    switch (item.kind) {
-                         case ResourceKind.Collection:
++                        case ResourceKind.COLLECTION:
 +                            this.props.dispatch<any>(loadCollection(item.uuid, item.kind as ResourceKind));
 +                            this.props.dispatch(push(getCollectionUrl(item.uuid)));
 +                        default: 
 +                            this.props.dispatch<any>(setProjectItem(item.uuid, ItemMode.ACTIVE));
 +                            this.props.dispatch<any>(loadDetails(item.uuid, item.kind as ResourceKind));
 +                    }
++
                  }}
                  {...props} />
  
@@@ -283,15 -262,9 +285,16 @@@
                      this.props.dispatch<any>(loadDetails(item.uuid, item.kind as ResourceKind));
                  }}
                  onItemDoubleClick={item => {
 -                    this.props.dispatch<any>(loadDetails(item.uuid, ResourceKind.PROJECT));
 -                    this.props.dispatch<any>(setProjectItem(item.uuid, ItemMode.ACTIVE));
 -                    this.props.dispatch<any>(sidePanelActions.TOGGLE_SIDE_PANEL_ITEM_ACTIVE(SidePanelIdentifiers.PROJECTS));
 +                    switch (item.kind) {
-                         case ResourceKind.Collection:
++                        case ResourceKind.COLLECTION:
 +                            this.props.dispatch<any>(loadCollection(item.uuid, item.kind as ResourceKind));
 +                            this.props.dispatch(push(getCollectionUrl(item.uuid)));
 +                        default:
-                             this.props.dispatch<any>(loadDetails(item.uuid, ResourceKind.Project));
++                            this.props.dispatch<any>(loadDetails(item.uuid, ResourceKind.PROJECT));
 +                            this.props.dispatch<any>(setProjectItem(item.uuid, ItemMode.ACTIVE));
-                             this.props.dispatch<any>(sidePanelActions.TOGGLE_SIDE_PANEL_ITEM_ACTIVE(SidePanelIdentifiers.Projects));
++                            this.props.dispatch<any>(sidePanelActions.TOGGLE_SIDE_PANEL_ITEM_ACTIVE(SidePanelIdentifiers.PROJECTS));
 +                    }
++
                  }}
                  {...props} />
  

-----------------------------------------------------------------------


hooks/post-receive
-- 




More information about the arvados-commits mailing list