[ARVADOS-WORKBENCH2] updated: 1.2.0-220-g97de0bf

Git user git at public.curoverse.com
Thu Aug 30 09:34:37 EDT 2018


Summary of changes:
 .../details-attribute/details-attribute.tsx        |  4 +-
 .../subprocess-filter/subprocess-filter.tsx        | 54 +++++++++++++
 src/models/container-request.ts                    | 19 +++--
 src/models/container.ts                            | 38 +++++++++
 src/models/mount-types.ts                          | 56 +++++++++++++
 src/models/resource.ts                             | 13 +++-
 src/models/runtime-constraints.ts                  | 10 +++
 src/models/scheduling-parameters.ts                |  9 +++
 src/routes/routes.ts                               | 25 +++---
 .../container-request-service.ts}                  | 26 +++----
 .../container-service.ts}                          | 26 +++----
 src/services/services.ts                           | 35 +++++----
 .../collection-panel-files-actions.ts              |  2 -
 .../collections/collection-partial-copy-actions.ts |  2 +-
 src/store/navigation/navigation-action.ts          |  6 +-
 src/store/processes/process.ts                     | 47 +++++++++++
 src/store/processes/processes-actions.ts           | 52 +++++++++++++
 src/store/resources/resources.ts                   | 10 ++-
 src/store/workbench/workbench-actions.ts           | 13 ++++
 .../details-panel/process-details.tsx              |  4 +-
 ...dialog.ts => files-upload-collection-dialog.ts} |  4 +-
 .../dialog-forms/partial-copy-collection-dialog.ts |  8 +-
 .../process-information-card.ts                    | 24 ------
 .../process-panel/process-information-card.tsx     | 25 +++---
 src/views/process-panel/process-panel-root.tsx     | 91 ++++++++++++++++++++++
 src/views/process-panel/process-panel.tsx          | 53 +++++--------
 .../process-panel/process-subprocesses-card.tsx    |  2 +-
 src/views/process-panel/subprocesses-card.tsx      | 46 +++++++++++
 src/views/workbench/workbench.tsx                  | 13 ++--
 29 files changed, 564 insertions(+), 153 deletions(-)
 create mode 100644 src/components/subprocess-filter/subprocess-filter.tsx
 create mode 100644 src/models/container.ts
 create mode 100644 src/models/mount-types.ts
 create mode 100644 src/models/runtime-constraints.ts
 create mode 100644 src/models/scheduling-parameters.ts
 copy src/services/{keep-service/keep-service.ts => container-request-service/container-request-service.ts} (55%)
 copy src/services/{keep-service/keep-service.ts => container-service/container-service.ts} (59%)
 create mode 100644 src/store/processes/process.ts
 create mode 100644 src/store/processes/processes-actions.ts
 rename src/views-components/dialog-forms/{upload-collection-files-dialog.ts => files-upload-collection-dialog.ts} (81%)
 delete mode 100644 src/views-components/process-information-card/process-information-card.ts
 create mode 100644 src/views/process-panel/process-panel-root.tsx
 create mode 100644 src/views/process-panel/subprocesses-card.tsx

       via  97de0bf90660e72220f350483981e35d53a5998f (commit)
       via  cba0f400f56889778321bdc0fdcf6cee236f6a79 (commit)
       via  9b28d6d29d9609adc86e3fdc136873c3cf6114ed (commit)
       via  f53d651573ef8c358cbdf38c7a56c6aed8178b61 (commit)
       via  b026476240a6f347b579e03efd53a9043f8daa5a (commit)
       via  3d996002ab1f259b31d07858d9c5d0a780600a00 (commit)
       via  9ccc7e8ebe82b97e219d65adeea8b03b2c9ed71a (commit)
       via  21ee15421471ce0f0aa4a1241cab3498c335d682 (commit)
       via  6149700b801fc2cdb83b0e700bbb319850ed471d (commit)
       via  2d887860caa003ddaf69d1f85ebdaf208e0b74c1 (commit)
       via  5163a70c5624a52c802a37d66b806b5e718c4151 (commit)
       via  c798ba784db88b406d27f3783501ab2800f5719a (commit)
       via  3bf48201c92fcb9827d134a96671f02035f544a6 (commit)
       via  4221f6e12bfbbf56ab8848e9c6c1b6b9eacbec64 (commit)
       via  78969103183f03a23557aa0b4d1739a0ff12dcb2 (commit)
       via  de519d0b84931f8ef5fb7d2aecdb67a911c3eabf (commit)
       via  1ca26fd87e061052b071e5039cc68c5a7434a8a5 (commit)
       via  5333321c0b65561a5e715236a5bc7fc319c8f1da (commit)
       via  4c9eb3858796cd5986d8397117549e15e19896e8 (commit)
       via  6a5c0fe0cd12635698d2b5a6df27b4291e5b0ecb (commit)
       via  9fbb245286171bc55fed5b5104361a1869a1d76b (commit)
       via  a6af19c842e41469fb832dff58d5a23747394a1c (commit)
       via  ae9841925d717e97a74f3ae17c414c638c56e496 (commit)
       via  dbde3a8cc8098e423fb7d7f7147ea8a664744957 (commit)
      from  909ee82b3c7c7fd033c6ab2e82b4fb92f383e191 (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 97de0bf90660e72220f350483981e35d53a5998f
Merge: 909ee82 cba0f40
Author: Pawel Kowalczyk <pawel.kowalczyk at contractors.roche.com>
Date:   Thu Aug 30 15:34:30 2018 +0200

    merge master
    
    Feature #13859
    
    Arvados-DCO-1.1-Signed-off-by: Pawel Kowalczyk <pawel.kowalczyk at contractors.roche.com>

diff --cc src/views/process-panel/process-information-card.tsx
index 359c256,53c56ca..acc1d8f
--- a/src/views/process-panel/process-information-card.tsx
+++ b/src/views/process-panel/process-information-card.tsx
@@@ -11,11 -10,10 +11,12 @@@ import * as classnames from "classnames
  import { ArvadosTheme } from '~/common/custom-theme';
  import { MoreOptionsIcon, ProcessIcon } from '~/components/icon/icon';
  import { DetailsAttribute } from '~/components/details-attribute/details-attribute';
- import { getBackgroundColorStatus } from '~/views/process-panel/process-panel';
- import { SubprocessesStatus } from '~/views/process-panel/process-subprocesses';
+ import { Process } from '~/store/processes/process';
 -import { getProcessStatus } from '../../store/processes/process';
++import { getProcessStatus } from '~/store/processes/process';
++import { getBackgroundColorStatus } from '~/views/process-panel/process-panel-root';
  
 -type CssRules = 'card' | 'iconHeader' | 'label' | 'value' | 'chip' | 'headerText' | 'link' | 'content' | 'title' | 'avatar';
 +type CssRules = 'card' | 'iconHeader' | 'label' | 'value' | 'chip' | 'link' | 'content' | 'title' | 'avatar'
 +    | 'headerActive' | 'headerCompleted' | 'headerQueued' | 'headerFailed' | 'headerCanceled';
  
  const styles: StyleRulesCallback<CssRules> = (theme: ArvadosTheme) => ({
      card: {
@@@ -99,8 -85,7 +100,8 @@@ export const ProcessInformationCard = w
                  avatar={<ProcessIcon className={classes.iconHeader} />}
                  action={
                      <div>
-                         <Chip label={SubprocessesStatus.ACTIVE}
-                             className={classnames([classes.chip, getBackgroundColorStatus(SubprocessesStatus.ACTIVE, classes)])} />
 -                        <Chip label={getProcessStatus(process)} className={classes.chip} />
++                        <Chip label={getProcessStatus(process)}
++                            className={classnames([classes.chip, getBackgroundColorStatus(getProcessStatus(process), classes)])} />
                          <IconButton
                              aria-label="More options"
                              onClick={event => onContextMenu(event)}>
diff --cc src/views/process-panel/process-panel-root.tsx
index 0000000,feada3a..49ce98c
mode 000000,100644..100644
--- a/src/views/process-panel/process-panel-root.tsx
+++ b/src/views/process-panel/process-panel-root.tsx
@@@ -1,0 -1,69 +1,91 @@@
+ // Copyright (C) The Arvados Authors. All rights reserved.
+ //
+ // SPDX-License-Identifier: AGPL-3.0
+ 
+ import * as React from 'react';
+ import { Grid } from '@material-ui/core';
+ import { ProcessInformationCard } from './process-information-card';
+ import { DefaultView } from '~/components/default-view/default-view';
+ import { ProcessIcon } from '~/components/icon/icon';
+ import { Process } from '~/store/processes/process';
+ import { SubprocessesCard } from './subprocesses-card';
++import { ProcessSubprocesses } from '~/views-components/process-subprocesses/process-subprocesses';
++import { SubprocessesStatus } from '~/views/process-panel/process-subprocesses';
++
++type CssRules = 'headerActive' | 'headerCompleted' | 'headerQueued' | 'headerFailed' | 'headerCanceled';
+ 
+ export interface ProcessPanelRootDataProps {
+     process?: Process;
+ }
+ 
+ export interface ProcessPanelRootActionProps {
+     onContextMenu: (event: React.MouseEvent<HTMLElement>) => void;
+ }
+ 
+ export type ProcessPanelRootProps = ProcessPanelRootDataProps & ProcessPanelRootActionProps;
+ 
+ export const ProcessPanelRoot = (props: ProcessPanelRootProps) =>
+     props.process
+         ? <Grid container spacing={16}>
+             <Grid item xs={7}>
+                 <ProcessInformationCard
+                     process={props.process}
+                     onContextMenu={props.onContextMenu} />
+             </Grid>
+             <Grid item xs={5}>
+                 <SubprocessesCard
+                     subprocesses={4}
+                     filters={[
+                         {
+                             key: 'queued',
+                             value: 1,
+                             label: 'Queued',
+                             checked: true
+                         }, {
+                             key: 'active',
+                             value: 2,
+                             label: 'Active',
+                             checked: true
+                         },
+                         {
+                             key: 'completed',
+                             value: 2,
+                             label: 'Completed',
+                             checked: true
+                         },
+                         {
+                             key: 'failed',
+                             value: 2,
+                             label: 'Failed',
+                             checked: true
+                         }
+                     ]}
+                     onToggle={() => { return; }}
+                 />
+             </Grid>
++            <ProcessSubprocesses />
+         </Grid>
+         : <Grid container
+             alignItems='center'
+             justify='center'>
+             <DefaultView
+                 icon={ProcessIcon}
+                 messages={['Process not found']} />
+         </Grid>;
++
++export const getBackgroundColorStatus = (status: string, classes: Record<CssRules, string>) => {
++    switch (status) {
++        case SubprocessesStatus.COMPLETED:
++            return classes.headerCompleted;
++        case SubprocessesStatus.CANCELED:
++            return classes.headerCanceled;
++        case SubprocessesStatus.QUEUED:
++            return classes.headerQueued;
++        case SubprocessesStatus.FAILED:
++            return classes.headerFailed;
++        case SubprocessesStatus.ACTIVE:
++            return classes.headerActive;
++        default:
++            return classes.headerQueued;
++    }
++};
diff --cc src/views/process-panel/process-subprocesses-card.tsx
index 2ea1b7e,0000000..17c4424
mode 100644,000000..100644
--- a/src/views/process-panel/process-subprocesses-card.tsx
+++ b/src/views/process-panel/process-subprocesses-card.tsx
@@@ -1,114 -1,0 +1,114 @@@
 +// Copyright (C) The Arvados Authors. All rights reserved.
 +//
 +// SPDX-License-Identifier: AGPL-3.0
 +
 +import * as React from 'react';
 +import {
 +    StyleRulesCallback, WithStyles, withStyles, Card,
 +    CardHeader, IconButton, CardContent, Typography, Tooltip
 +} from '@material-ui/core';
 +import * as classnames from "classnames";
 +import { ArvadosTheme } from '~/common/custom-theme';
 +import { MoreOptionsIcon } from '~/components/icon/icon';
 +import { DetailsAttribute } from '~/components/details-attribute/details-attribute';
- import { getBackgroundColorStatus } from '~/views/process-panel/process-panel';
++import { getBackgroundColorStatus } from '~/views/process-panel/process-panel-root';
 +
 +export type CssRules = 'label' | 'value' | 'title' | 'content' | 'action' | 'options' | 'status' | 'rightSideHeader' | 'titleHeader'
 +    | 'header' | 'headerActive' | 'headerCompleted' | 'headerQueued' | 'headerFailed' | 'headerCanceled';
 +
 +const styles: StyleRulesCallback<CssRules> = (theme: ArvadosTheme) => ({
 +    label: {
 +        fontSize: '0.875rem',
 +    },
 +    value: {
 +        textTransform: 'none',
 +        fontSize: '0.875rem',
 +    },
 +    title: {
 +        overflow: 'hidden'
 +    },
 +    content: {
 +        paddingTop: theme.spacing.unit * 0.5,
 +        '&:last-child': {
 +            paddingBottom: 0
 +        }
 +    },
 +    action: {
 +        marginTop: 0
 +    },
 +    options: {
 +        width: theme.spacing.unit * 4,
 +        height: theme.spacing.unit * 4,
 +        color: theme.palette.common.white,
 +    },
 +    status: {
 +        paddingTop: theme.spacing.unit * 0.5,
 +        color: theme.palette.common.white,
 +    },
 +    rightSideHeader: {
 +        display: 'flex'
 +    },
 +    titleHeader: {
 +        color: theme.palette.common.white,
 +        fontWeight: 600
 +    },
 +    header: {
 +        paddingTop: 0,
 +        paddingBottom: 0,
 +    },
 +    headerActive: {
 +        backgroundColor: theme.customs.colors.blue500,
 +    },
 +    headerCompleted: {
 +        backgroundColor: theme.customs.colors.green700,
 +    },
 +    headerQueued: {
 +        backgroundColor: theme.customs.colors.grey500,
 +    },
 +    headerFailed: {
 +        backgroundColor: theme.customs.colors.red900,
 +    },
 +    headerCanceled: {
 +        backgroundColor: theme.customs.colors.red900,
 +    },
 +});
 +
 +export interface ProcessSubprocessesCardDataProps {
 +    onContextMenu: (event: React.MouseEvent<HTMLElement>) => void;
 +    items: any;
 +}
 +
 +type ProcessSubprocessesCardProps = ProcessSubprocessesCardDataProps & WithStyles<CssRules>;
 +
 +export const ProcessSubprocessesCard = withStyles(styles)(
 +    ({ classes, onContextMenu, items }: ProcessSubprocessesCardProps) => {
 +        return <Card>
 +            <CardHeader
 +                className={classnames([classes.header, getBackgroundColorStatus(items.status, classes)])}
 +                classes={{ content: classes.title, action: classes.action }}
 +                action={
 +                    <div className={classes.rightSideHeader}>
 +                        <Typography noWrap variant="body2" className={classes.status}>
 +                            {items.status}
 +                        </Typography>
 +                        <IconButton
 +                            className={classes.options}
 +                            aria-label="More options"
 +                            onClick={event => onContextMenu(event)}>
 +                            <MoreOptionsIcon />
 +                        </IconButton>
 +                    </div>
 +                }
 +                title={
 +                    <Tooltip title={items.title}>
 +                        <Typography noWrap variant="body2" className={classes.titleHeader}>
 +                            {items.title}
 +                        </Typography>
 +                    </Tooltip>
 +                } />
 +            <CardContent className={classes.content}>
 +                <DetailsAttribute classLabel={classes.label} classValue={classes.value}
 +                    label='Runtime' value="0h 2m" />
 +            </CardContent>
 +        </Card>;
 +    });

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


hooks/post-receive
-- 




More information about the arvados-commits mailing list