Refactoring for Tasks

This commit is contained in:
Luis Fernando Molina committed 2019-09-08 11:28:39 +02:00
1 parent d17627c29a
commit 2f7461c58f
11 files changed
+68 -68

No files matched your search

+5 -5
View File
@@ -246,20 +246,20 @@ function newStrategyPart () {
compatibleType = '->' + 'Definition'
compatibleSubType = undefined
break
case 'Backend Process':
case 'Task':
compatibleType = '->' + 'Backend'
compatibleSubType = undefined
break
case 'Sensor':
compatibleType = '->' + 'Backend Process'
compatibleType = '->' + 'Task'
compatibleSubType = undefined
break
case 'Indicator':
compatibleType = '->' + 'Backend Process'
compatibleType = '->' + 'Task'
compatibleSubType = undefined
break
case 'Trading Engine':
compatibleType = '->' + 'Backend Process'
compatibleType = '->' + 'Task'
compatibleSubType = undefined
break
case 'Bot Process':
@@ -365,7 +365,7 @@ function newStrategyPart () {
if (compatibleType.indexOf('->' + nearbyNode.type) >= 0) {
/* Discard objects with busy coonection ports */
if (thisObject.payload.node.type === 'Backend' && nearbyNode.backend !== undefined) { continue }
if (thisObject.payload.node.type === 'Backend Process' && nearbyNode.backendProcess !== undefined) { continue }
if (thisObject.payload.node.type === 'Task' && nearbyNode.task !== undefined) { continue }
if (thisObject.payload.node.type === 'Sensor' && nearbyNode.bot !== undefined) { continue }
if (thisObject.payload.node.type === 'Indicator' && nearbyNode.bot !== undefined) { continue }
if (thisObject.payload.node.type === 'Trading Engine' && nearbyNode.bot !== undefined) { continue }
+7 -7
View File
@@ -321,9 +321,9 @@ function newStrategyPartConstructor () {
addLeftIcons(menuItemsInitialValues, floatingObject)
menuItemsInitialValues.push(
{
action: 'Add Backend Process',
action: 'Add Task',
actionFunction: payload.onMenuItemClick,
label: 'Add Backend Process',
label: 'Add Task',
visible: false,
relatedStrategyPart: 'Backend',
rawRadius: 8,
@@ -364,11 +364,11 @@ function newStrategyPartConstructor () {
)
break
}
case 'Backend Process': {
case 'Task': {
addLeftIcons(menuItemsInitialValues, floatingObject)
menuItemsInitialValues.push(
{
action: 'Run Backend Process',
action: 'Run Task',
actionFunction: payload.onMenuItemClick,
label: 'Run',
visible: false,
@@ -382,7 +382,7 @@ function newStrategyPartConstructor () {
)
menuItemsInitialValues.push(
{
action: 'Stop Backend Process',
action: 'Stop Task',
actionFunction: payload.onMenuItemClick,
label: 'Stop',
visible: false,
@@ -435,7 +435,7 @@ function newStrategyPartConstructor () {
)
menuItemsInitialValues.push(
{
action: 'Delete Backend Process',
action: 'Delete Task',
askConfirmation: true,
confirmationLabel: 'Confirm to Delete',
actionFunction: payload.onMenuItemClick,
@@ -2144,7 +2144,7 @@ function newStrategyPartConstructor () {
level_1()
break
}
case 'Backend Process': {
case 'Task': {
level_1()
break
}
+1 -1
View File
@@ -55,7 +55,7 @@ function newStrategyPartTitle () {
case 'Backend': {
break
}
case 'Backend Process': {
case 'Task': {
break
}
case 'Sensor': {