From 62884a6d4f70e0d0990260f40971d942a3d0f583 Mon Sep 17 00:00:00 2001 From: Luis Fernando Molina Date: Fri, 6 Sep 2019 14:37:57 +0200 Subject: [PATCH] Bug Fixes con addition of new elements --- FloatingSpace/StrategyPartConstructor.js | 32 ++++++++++++++++--- .../FunctionLibraries/NodeChildren.js | 2 +- .../FunctionLibraries/PartsFromNodes.js | 3 +- 3 files changed, 31 insertions(+), 6 deletions(-) diff --git a/FloatingSpace/StrategyPartConstructor.js b/FloatingSpace/StrategyPartConstructor.js index 4657d0f86..6bfe4c870 100644 --- a/FloatingSpace/StrategyPartConstructor.js +++ b/FloatingSpace/StrategyPartConstructor.js @@ -243,7 +243,7 @@ function newStrategyPartConstructor () { rawRadius: 8, targetRadius: 0, currentRadius: 0, - angle: -50 + angle: -40 } ) menuItemsInitialValues.push( @@ -256,7 +256,7 @@ function newStrategyPartConstructor () { rawRadius: 8, targetRadius: 0, currentRadius: 0, - angle: -25 + angle: -20 } ) menuItemsInitialValues.push( @@ -282,7 +282,7 @@ function newStrategyPartConstructor () { rawRadius: 8, targetRadius: 0, currentRadius: 0, - angle: 25 + angle: 20 } ) menuItemsInitialValues.push( @@ -298,7 +298,7 @@ function newStrategyPartConstructor () { rawRadius: 8, targetRadius: 0, currentRadius: 0, - angle: 50 + angle: 40 } ) menuItemsInitialValues.push( @@ -2028,6 +2028,30 @@ function newStrategyPartConstructor () { level_0() break } + case 'Backend': { + level_1() + break + } + case 'Backend Process': { + level_2() + break + } + case 'Sensor': { + level_3() + break + } + case 'Indicator': { + level_3() + break + } + case 'Trading Engine': { + level_3() + break + } + case 'Bot Process': { + level_4() + break + } case 'Exchange Account': { level_1() break diff --git a/StrategySpace/Workspace/FunctionLibraries/NodeChildren.js b/StrategySpace/Workspace/FunctionLibraries/NodeChildren.js index 0776441a7..409d285d4 100644 --- a/StrategySpace/Workspace/FunctionLibraries/NodeChildren.js +++ b/StrategySpace/Workspace/FunctionLibraries/NodeChildren.js @@ -160,7 +160,7 @@ function newNodeChildren () { childIndex: undefined } - for (let i = 0; i < parentNode.exchangeAccounts.length; i++) { + for (let i = 0; i < parentNode.backendProcesses.length; i++) { let child = parentNode.backendProcesses[i] response.childrenCount++ if (child.id === childNode.id) { diff --git a/StrategySpace/Workspace/FunctionLibraries/PartsFromNodes.js b/StrategySpace/Workspace/FunctionLibraries/PartsFromNodes.js index b151ae6f0..7fa8b9ec0 100644 --- a/StrategySpace/Workspace/FunctionLibraries/PartsFromNodes.js +++ b/StrategySpace/Workspace/FunctionLibraries/PartsFromNodes.js @@ -430,7 +430,8 @@ function newPartsFromNodes () { function addBotProcess (node) { let botProcess = { - name: 'New Bot Process' + name: 'New Bot Process', + code: '// Write the configuration here.' } node.botProcesses.push(botProcess) createPart('Bot Process', botProcess.name, botProcess, node, node, 'Bot Process')