var data=[];
if(e.target.result.length>1){
data=JSON.parse(e.target.result);
}
function compare(a, b) {
return Number(a.date.substring(8,10))-Number(b.date.substring(8,10));
}
data = data.sort(compare);