[ARVADOS-WORKBENCH2] updated: 1.1.4-206-ge9b57c9

Git user git at public.curoverse.com
Thu Jul 5 08:31:09 EDT 2018


Summary of changes:
 src/services/groups-service/groups-service.ts       |  7 +++++++
 src/views/project-panel/project-panel-middleware.ts | 19 +++++++++----------
 2 files changed, 16 insertions(+), 10 deletions(-)

       via  e9b57c9d6025168cc29442c85fd784902007052a (commit)
       via  6d107715ed9b4ef029ba5cdf6d3839883c8333c2 (commit)
      from  ca88aa7165ef8320a0f2cc0125ec647eb31aab15 (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 e9b57c9d6025168cc29442c85fd784902007052a
Author: Michal Klobukowski <michal.klobukowski at contractors.roche.com>
Date:   Thu Jul 5 14:30:56 2018 +0200

    Stop pagination reset when sorting is toggled
    
    Feature #13703
    
    Arvados-DCO-1.1-Signed-off-by: Michal Klobukowski <michal.klobukowski at contractors.roche.com>

diff --git a/src/views/project-panel/project-panel-middleware.ts b/src/views/project-panel/project-panel-middleware.ts
index de2e3fc..a6a7256 100644
--- a/src/views/project-panel/project-panel-middleware.ts
+++ b/src/views/project-panel/project-panel-middleware.ts
@@ -41,7 +41,6 @@ export const projectPanelMiddleware: Middleware = store => next => {
                 store.dispatch(actions.REQUEST_ITEMS({ id: PROJECT_PANEL_ID }));
             }),
             TOGGLE_SORT: handleProjectPanelAction(() => {
-                store.dispatch(actions.RESET_PAGINATION({ id: PROJECT_PANEL_ID }));
                 store.dispatch(actions.REQUEST_ITEMS({ id: PROJECT_PANEL_ID }));
             }),
             SET_SEARCH_VALUE: handleProjectPanelAction(() => {
@@ -69,7 +68,7 @@ export const projectPanelMiddleware: Middleware = store => next => {
                             filters: FilterBuilder
                                 .create()
                                 .concat(FilterBuilder
-                                    .create<CollectionResource>(GroupContentsResourcePrefix.Collection)
+                                    .create()
                                     .addIsA("uuid", typeFilters.map(f => f.type)))
                                 .concat(FilterBuilder
                                     .create<ProcessResource>(GroupContentsResourcePrefix.Process)

commit 6d107715ed9b4ef029ba5cdf6d3839883c8333c2
Author: Michal Klobukowski <michal.klobukowski at contractors.roche.com>
Date:   Thu Jul 5 12:25:54 2018 +0200

    Add enum with resource prefixes
    
    Feature #13703
    
    Arvados-DCO-1.1-Signed-off-by: Michal Klobukowski <michal.klobukowski at contractors.roche.com>

diff --git a/src/services/groups-service/groups-service.ts b/src/services/groups-service/groups-service.ts
index 8c5fd8f..ea57ee0 100644
--- a/src/services/groups-service/groups-service.ts
+++ b/src/services/groups-service/groups-service.ts
@@ -46,4 +46,11 @@ export default class GroupsService extends CommonResourceService<GroupResource>
             })
             .then(CommonResourceService.mapResponseKeys);
     }
+}
+
+export enum GroupContentsResourcePrefix {
+    Collection = "collections",
+    Project = "groups",
+    Workflow = "workflows",
+    Process = "container_requests"
 }
\ No newline at end of file
diff --git a/src/views/project-panel/project-panel-middleware.ts b/src/views/project-panel/project-panel-middleware.ts
index fdd05c7..de2e3fc 100644
--- a/src/views/project-panel/project-panel-middleware.ts
+++ b/src/views/project-panel/project-panel-middleware.ts
@@ -14,7 +14,7 @@ import { DataColumns } from "../../components/data-table/data-table";
 import { ProcessResource } from "../../models/process";
 import { CollectionResource } from "../../models/collection";
 import OrderBuilder from "../../common/api/order-builder";
-import { GroupContentsResource } from "../../services/groups-service/groups-service";
+import { GroupContentsResource, GroupContentsResourcePrefix } from "../../services/groups-service/groups-service";
 
 export const projectPanelMiddleware: Middleware = store => next => {
     next(actions.SET_COLUMNS({ id: PROJECT_PANEL_ID, columns }));
@@ -69,10 +69,10 @@ export const projectPanelMiddleware: Middleware = store => next => {
                             filters: FilterBuilder
                                 .create()
                                 .concat(FilterBuilder
-                                    .create<CollectionResource>("collections")
+                                    .create<CollectionResource>(GroupContentsResourcePrefix.Collection)
                                     .addIsA("uuid", typeFilters.map(f => f.type)))
                                 .concat(FilterBuilder
-                                    .create<ProcessResource>("containerRequests")
+                                    .create<ProcessResource>(GroupContentsResourcePrefix.Process)
                                     .addIn("state", statusFilters.map(f => f.type)))
                                 .concat(getSearchFilter(dataExplorer.searchValue))
                         })
@@ -107,9 +107,9 @@ const getColumnFilters = (columns: DataColumns<ProjectPanelItem, ProjectPanelFil
 
 const getOrder = (attribute: "name" | "createdAt", direction: "asc" | "desc") =>
     [
-        OrderBuilder.create<GroupContentsResource>("collections"),
-        OrderBuilder.create<GroupContentsResource>("container_requests"),
-        OrderBuilder.create<GroupContentsResource>("groups")
+        OrderBuilder.create<GroupContentsResource>(GroupContentsResourcePrefix.Collection),
+        OrderBuilder.create<GroupContentsResource>(GroupContentsResourcePrefix.Process),
+        OrderBuilder.create<GroupContentsResource>(GroupContentsResourcePrefix.Project)
     ].reduce((acc, b) =>
         acc.concat(direction === "asc"
             ? b.addAsc(attribute)
@@ -118,9 +118,9 @@ const getOrder = (attribute: "name" | "createdAt", direction: "asc" | "desc") =>
 const getSearchFilter = (searchValue: string) =>
     searchValue
         ? [
-            FilterBuilder.create<GroupContentsResource>("collections"),
-            FilterBuilder.create<GroupContentsResource>("container_requests"),
-            FilterBuilder.create<GroupContentsResource>("groups")]
+            FilterBuilder.create<GroupContentsResource>(GroupContentsResourcePrefix.Collection),
+            FilterBuilder.create<GroupContentsResource>(GroupContentsResourcePrefix.Process),
+            FilterBuilder.create<GroupContentsResource>(GroupContentsResourcePrefix.Project)]
             .reduce((acc, b) =>
                 acc.concat(b.addILike("name", searchValue)), FilterBuilder.create())
         : FilterBuilder.create();

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


hooks/post-receive
-- 




More information about the arvados-commits mailing list