Bug Fixed

This commit is contained in:
Luis Fernando Molina committed 2020-06-15 16:15:01 +02:00
1 parent 4088d631a8
commit fb3cdde61a
3 files changed
+7 -7

No files matched your search

+1 -1
View File
@@ -114,7 +114,7 @@ exports.newTradingRecords = function newTradingRecords(bot, logger) {
value = '"' + value + '"'
}
if (recordProperty.config.decimals !== undefined) {
value = value.toFixed(decimals)
value = Number(value.toFixed(recordProperty.config.decimals))
}
record.push(value)
}
+2 -1
View File
@@ -151,9 +151,10 @@ exports.newTradingSimulation = function newTradingSimulation(bot, logger, UTILIT
heartBeat()
positionChartAtCurrentCandle()
tradingSystemModule.setChart(chart)
tradingEngineModule.updateEpisodeCountersAndStatistics()
tradingSystemModule.setChart(chart)
tradingSystemModule.evalConditions()
tradingSystemModule.evalFormulas()
tradingSystemModule.checkTriggerOn()
+4 -5
View File
@@ -100,7 +100,7 @@ exports.newTradingSystem = function newTradingSystem(bot, logger) {
case 'node': {
if (property.name !== previousPropertyName) {
if (node[property.name] !== undefined) {
evalNode(node[property.name])
evalNode(node[property.name], evaluating)
}
previousPropertyName = property.name
}
@@ -109,9 +109,8 @@ exports.newTradingSystem = function newTradingSystem(bot, logger) {
case 'array': {
if (node[property.name] !== undefined) {
let nodePropertyArray = node[property.name]
object[property.name] = []
for (let m = 0; m < nodePropertyArray.length; m++) {
evalNode(nodePropertyArray[m])
evalNode(nodePropertyArray[m], evaluating)
}
}
break
@@ -191,9 +190,9 @@ exports.newTradingSystem = function newTradingSystem(bot, logger) {
formulas.set(node.id, value)
if (value === true) {
formulaValues.push(1)
tradingSystem.formulasValues.push(1)
} else {
formulaValues.push(0)
tradingSystem.formulasValues.push(0)
}
tradingSystem.formulasErrors.push(error)