홍용민

예측시간 저장 배열 변수 추가

......@@ -63,6 +63,7 @@ for(var i=0; i<routeID.length; i++){
const GateBusUrl = bus_url + '?servicekey=' + process.env.key + '&stationId=' + gateStationID; //국제캠 정문 정류장
let date = new Date();
let predictTime;
function predict(){
console.log(GateBusUrl);
......@@ -92,13 +93,15 @@ function predict(){
Bus[index]["MinPredictTime"] = predictHour1 + ":" + predictMinute1;
Bus[index]["MaxPredictTime"] = predictHour2 + ":" + predictMinute2;
predictTime = [Bus[index].MinPredictTime, Bus[index].MaxPredictTime];
}
})
})
}
function useWhile(){
function start(){
setInterval(predict, 60000);
}
setTimeout(useWhile, 20000);
\ No newline at end of file
setTimeout(start, 20000);
\ No newline at end of file
......