Commit 1dc2f2e9 authored by Ahmad Nemati's avatar Ahmad Nemati

git pull

parent 4aba0716
...@@ -213,7 +213,7 @@ async function run() { ...@@ -213,7 +213,7 @@ async function run() {
for (let i = 0; i < dates.length; i++) for (let i = 0; i < dates.length; i++)
sumAll = sumAll + dates[i].count sumAll = sumAll + dates[i].count
console.log(arrNew) console.log(dates)
// let ss=0 // let ss=0
// for (let i=0;i<dates.length;i++) // for (let i=0;i<dates.length;i++)
// ss=ss+dates[i].profit // ss=ss+dates[i].profit
......
...@@ -49,7 +49,7 @@ app.post('/signal', (req, res) => { ...@@ -49,7 +49,7 @@ app.post('/signal', (req, res) => {
res.send('Done') res.send('Done')
console.log(req.body) console.log(req.body)
// analyse(req.body) analyse(req.body)
}) })
...@@ -58,7 +58,7 @@ app.post('/', (req, res) => { ...@@ -58,7 +58,7 @@ app.post('/', (req, res) => {
res.send('Done') res.send('Done')
console.log(req.body) console.log(req.body)
// analyse(req.body) analyse(req.body)
}) })
...@@ -66,6 +66,8 @@ app.post('/', (req, res) => { ...@@ -66,6 +66,8 @@ app.post('/', (req, res) => {
async function analyse(body) { async function analyse(body) {
let t = body.split(',') let t = body.split(',')
let obj = {} let obj = {}
if (typeof t[0] ==="undefined")
return
obj.symbol = t[0] obj.symbol = t[0]
obj.entry = parseFloat(t[1]) obj.entry = parseFloat(t[1])
obj.exit = parseFloat(t[2]) obj.exit = parseFloat(t[2])
...@@ -101,8 +103,8 @@ async function analyse(body) { ...@@ -101,8 +103,8 @@ async function analyse(body) {
appendCsv(final, indicator) appendCsv(final, indicator)
indicator = indicator.replace('Kelt', 'btc4').replace('SOTT', 'btc3').replace('Pmax', 'btc2').replace('PPST', 'btc1').replace('.csv', '') indicator = indicator.replace('Kelt', 'btc4').replace('SOTT', 'btc3').replace('Pmax', 'btc2').replace('PPST', 'btc1').replace('.csv', '')
appendCsvtoMain(final,indicator) //appendCsvtoMain(final,indicator)
updateVars(indicator,final) // updateVars(indicator,final)
} }
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment