From bb1b1ec8ae75f3e05bfab3d77be948e1e84a3d40 Mon Sep 17 00:00:00 2001 From: Matias Date: Thu, 28 Feb 2019 18:46:43 -0300 Subject: [PATCH] Adding competition mode to the list view --- client/package.json | 2 +- client/src/GraphQL/models.js | 8 +++++++- client/src/views/Clone/List/ListClones.js | 4 ++-- 3 files changed, 10 insertions(+), 4 deletions(-) diff --git a/client/package.json b/client/package.json index 8d25a66f8..e6a8e7cc6 100644 --- a/client/package.json +++ b/client/package.json @@ -1,6 +1,6 @@ { "name": "@superalgos/operations-client", - "version": "0.0.16", + "version": "0.0.17", "description": "Superalgos Operations client-side web app", "main": "src/index.js", "dependencies": { diff --git a/client/src/GraphQL/models.js b/client/src/GraphQL/models.js index 47c7e6dfb..cd7e37973 100644 --- a/client/src/GraphQL/models.js +++ b/client/src/GraphQL/models.js @@ -6,6 +6,12 @@ const tradingStartModes = { backtest: 'Backtest' } +const tradingStartModesList = { + live: 'Live', + backtest: 'Backtest', + competition: 'Competition' +} + const indicatorStartModes = { allMonths: 'All Months', oneMonth: 'One Month', @@ -19,4 +25,4 @@ const exchanges = [ } ] -export { tradingStartModes, exchanges, indicatorStartModes, availableMonths } +export { tradingStartModes, tradingStartModesList, exchanges, indicatorStartModes, availableMonths } diff --git a/client/src/views/Clone/List/ListClones.js b/client/src/views/Clone/List/ListClones.js index b9c577826..774536bf8 100644 --- a/client/src/views/Clone/List/ListClones.js +++ b/client/src/views/Clone/List/ListClones.js @@ -10,7 +10,7 @@ import { } from '@material-ui/core' import Avatar from '@material-ui/core/Avatar'; import ExpandMoreIcon from '@material-ui/icons/ExpandMore'; -import { tradingStartModes, indicatorStartModes } from '../../../GraphQL/models' +import { tradingStartModesList, indicatorStartModes } from '../../../GraphQL/models' import { isDefined, toLocalTime } from '../../../utils' import classNames from 'classnames' import { withStyles } from '@material-ui/core/styles' @@ -43,7 +43,7 @@ class ListClones extends Component {
- { clone.processName } / { clone.botType === 'TRADER' ? tradingStartModes[clone.mode] : indicatorStartModes[clone.mode] } + { clone.processName } / { clone.botType === 'TRADER' ? tradingStartModesList[clone.mode] : indicatorStartModes[clone.mode] }