Trading Engine Refactoring

This commit is contained in:
Luis Fernando Molina committed 2019-10-27 11:31:16 +01:00
1 parent 0fd53d7cef
commit f05022e026
13 files changed
+28 -32

No files matched your search

@@ -145,7 +145,7 @@ function newAttachDetach () {
completeDetachment(node, rootNodes)
return
}
case 'Trading Engine': {
case 'Trading Bot Instance': {
node.payload.parentNode.bot = undefined
completeDetachment(node, rootNodes)
return
@@ -437,7 +437,7 @@ function newAttachDetach () {
completeAttachment(node, rootNodes)
}
break
case 'Trading Engine': {
case 'Trading Bot Instance': {
node.payload.parentNode = attachToNode
node.payload.chainParent = attachToNode
node.payload.parentNode.bot = node
@@ -44,7 +44,7 @@ function newNodeChildren () {
case 'Indicator Bot Instance': {
return countChildrenIndicator(parentNode, childNode)
}
case 'Trading Engine': {
case 'Trading Bot Instance': {
return countChildrenTradingEngine(parentNode, childNode)
}
case 'Process': {
@@ -109,7 +109,7 @@ function newNodeDeleter () {
deleteBot(rootNode, rootNodes)
break
}
case 'Trading Engine': {
case 'Trading Bot Instance': {
deleteBot(rootNode, rootNodes)
break
}
@@ -574,7 +574,7 @@ function newOnFocus () {
return
}
}
case 'Trading Engine': {
case 'Trading Bot Instance': {
let child
for (let m = 0; m < node.processes.length; m++) {
child = getNodeThatIsOnFocus(node.processes[m])
@@ -481,8 +481,8 @@ function newPartsFromNodes () {
}
return
}
case 'Trading Engine': {
createPart('Trading Engine', node.name, node, parentNode, chainParent, 'Trading Engine')
case 'Trading Bot Instance': {
createPart('Trading Bot Instance', node.name, node, parentNode, chainParent, 'Trading Bot Instance')
for (let m = 0; m < node.processes.length; m++) {
let process = node.processes[m]
createPartFromNode(process, node, node)
@@ -500,7 +500,7 @@ function newPartsFromNodes () {
node.subType = 'Indicator Process'
break
}
case 'Trading Engine': {
case 'Trading Bot Instance': {
node.subType = 'Trading Engine Process'
break
}
@@ -701,7 +701,7 @@ function newPartsFromNodes () {
processes: [],
code: '{}'
}
createPart('Trading Engine', '', node.bot, node, node)
createPart('Trading Bot Instance', '', node.bot, node, node)
}
return node.bot
}
@@ -723,7 +723,7 @@ function newPartsFromNodes () {
process.name = 'Indicator Process'
break
}
case 'Trading Engine': {
case 'Trading Bot Instance': {
process.subType = 'Trading Engine Process'
process.name = 'Trading Engine Process'
break
@@ -824,7 +824,7 @@ function newProtocolNode () {
}
return object
}
case 'Trading Engine': {
case 'Trading Bot Instance': {
let object = {
type: node.type,
subType: node.subType,
@@ -575,7 +575,7 @@ function newShortcutKeys () {
return
}
}
case 'Trading Engine': {
case 'Trading Bot Instance': {
let child
for (let m = 0; m < node.processes.length; m++) {
child = getNodeByShortcutKey(node.processes[m], searchingKey)