Commit b26ce7a9 authored by Ahmad Nemati's avatar Ahmad Nemati

git pull

parent 427fc281
...@@ -121,32 +121,33 @@ async function run(root,name, directory, timestamp) { ...@@ -121,32 +121,33 @@ async function run(root,name, directory, timestamp) {
last = _.orderBy(arr2, ['maxRuntime']); last = _.orderBy(arr2, ['maxRuntime']);
last= _.uniqBy(last, 'platform');
let las = [] let las = []
for (let i = 0; i < last.length; i++) { for (let i = 0; i < last.length; i++) {
if (i < last.length && last[i].newAllDonePer >10) if (i < last.length && last[i].newAllDonePer >10)
las.push(last[i]) las.push(last[i])
} }
last=[] // last=[]
let newLast=[] // let newLast=[]
let jj='[' // let jj='['
await append(jj) // await append(jj)
for (let i=0;i<las.length;i++) // for (let i=0;i<las.length;i++)
{ // {
let sidee=las[i].sideString // let sidee=las[i].sideString
sidee=sidee.replace(/LONG/g, 'L').replace(/SHORT/g, 'S') // sidee=sidee.replace(/LONG/g, 'L').replace(/SHORT/g, 'S')
let inline='{"c":"'+las[i].closeDate+'","p":"'+las[i].profitLossString+'","s":"'+sidee+'"}' // let inline='{"c":"'+las[i].closeDate+'","p":"'+las[i].profitLossString+'","s":"'+sidee+'"}'
if (i !==(las.length-1)) // if (i !==(las.length-1))
inline=inline+',' // inline=inline+','
await append(inline) // await append(inline)
// jj=jj+inline // // jj=jj+inline
} // }
await append(']') // await append(']')
// jj=jj+']' // // jj=jj+']'
//console.log(las.length) // //console.log(las.length)
createfileADV(root,timestamp, name, jj) // createfileADV(root,timestamp, name, jj)
createfileADV(root, timestamp, name, JSON.stringify(las, null, 2))
last = [] last = []
} }
......
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