Commit bb1cc051 authored by liyuanhong's avatar liyuanhong

修复车安优模拟器跑出的轨迹一直显示红色的问题

parent e1d1923e
{"time": {"dateTime": "2020-05-29 18:06:43", "date": "2020-05-29", "time": "18:06:43"}, "curDayTravel": {"todayTotalMilleage": 166, "todayTotalOil": 16, "todayTotalTime": 10, "theMilleage": 166, "theOil": 16, "theTime": 10}, "travelData": {"totalMilleage": 166, "totalOil": 16, "totalTime": 10}}
\ No newline at end of file
{"time": {"dateTime": "2020-06-04 16:47:12", "date": "2020-06-04", "time": "16:47:12"}, "curDayTravel": {"todayTotalMilleage": 664, "todayTotalOil": 64, "todayTotalTime": 40, "theMilleage": 664, "theOil": 64, "theTime": 40}, "travelData": {"totalMilleage": 830, "totalOil": 80, "totalTime": 50}}
\ No newline at end of file
{"time": {"dateTime": "2020-06-01 11:23:40", "date": "2020-06-01", "time": "11:23:40"}, "curDayTravel": {"todayTotalMilleage": 1472, "todayTotalOil": 92, "todayTotalTime": 92, "theMilleage": 656, "theOil": 41, "theTime": 41}, "travelData": {"totalMilleage": 25101, "totalOil": 2319, "totalTime": 1508}}
\ No newline at end of file
{"time": {"dateTime": "2020-06-04 15:11:26", "date": "2020-06-04", "time": "15:11:26"}, "curDayTravel": {"todayTotalMilleage": 8523, "todayTotalOil": 778, "todayTotalTime": 598, "theMilleage": 747, "theOil": 62, "theTime": 78}, "travelData": {"totalMilleage": 33624, "totalOil": 3097, "totalTime": 2106}}
\ No newline at end of file
{"time": {"dateTime": "2020-06-02 14:55:40", "date": "2020-06-02", "time": "14:55:40"}, "curDayTravel": {"todayTotalMilleage": 1174, "todayTotalOil": 109, "todayTotalTime": 71, "theMilleage": 1174, "theOil": 109, "theTime": 71}, "travelData": {"totalMilleage": 344447, "totalOil": 32342, "totalTime": 20463}, "event": {"threeRapid": {"totalRapidlyAccelerate": 19, "totalSharpSlowdown": 18, "totalSharpTurn": 17}}}
\ No newline at end of file
{"time": {"dateTime": "2020-06-04 16:26:36", "date": "2020-06-04", "time": "16:26:36"}, "curDayTravel": {"todayTotalMilleage": 332, "todayTotalOil": 32, "todayTotalTime": 20, "theMilleage": 332, "theOil": 32, "theTime": 20}, "travelData": {"totalMilleage": 344779, "totalOil": 32374, "totalTime": 20483}, "event": {"threeRapid": {"totalRapidlyAccelerate": 19, "totalSharpSlowdown": 18, "totalSharpTurn": 17}}}
\ No newline at end of file
......@@ -254,6 +254,7 @@ class MessageSimulaterService():
gpsParams["baseInfo"]["infoTime"] = curTime
gpsParams["baseInfo"]["latitude"] = self.gpsLine[self.gpsLineIndex]["lat"]
gpsParams["baseInfo"]["longtitude"] = self.gpsLine[self.gpsLineIndex]["lng"]
gpsParams["baseInfo"]["speed"] = int(self.data["travelData"]["carSpeed"]) * 10
gpsParams["baseInfo"]["directionAngle"] = self.getDirAngle()
gpsObj = Location_msg()
gpsMsg = gpsObj.generateMsg_GUI(gpsParams)
......@@ -275,6 +276,7 @@ class MessageSimulaterService():
gpsParams["baseInfo"]["infoTime"] = curTime
gpsParams["baseInfo"]["latitude"] = self.gpsLine[self.gpsLineIndex]["lat"]
gpsParams["baseInfo"]["longtitude"] = self.gpsLine[self.gpsLineIndex]["lng"]
gpsParams["baseInfo"]["speed"] = int(self.data["travelData"]["carSpeed"]) * 10
gpsParams["baseInfo"]["directionAngle"] = self.getDirAngle()
gpsObj = Location_msg()
gpsMsg = gpsObj.generateMsg_GUI(gpsParams)
......@@ -329,6 +331,7 @@ class MessageSimulaterService():
gpsParams["baseInfo"]["infoTime"] = curTime
gpsParams["baseInfo"]["latitude"] = self.gpsLine[self.gpsLineIndex]["lat"]
gpsParams["baseInfo"]["longtitude"] = self.gpsLine[self.gpsLineIndex]["lng"]
gpsParams["baseInfo"]["speed"] = int(self.data["travelData"]["carSpeed"]) * 10
gpsParams["baseInfo"]["directionAngle"] = self.getDirAngle()
gpsObj = Location_msg()
gpsMsg = gpsObj.generateMsg_GUI(gpsParams)
......
......@@ -583,7 +583,9 @@ function getAllUsers(){
success:function(data){
if(data.status == 200){
//window.location.reload()
obj = data.result
//obj = data.result
obj = data.result.replace(/'service'(.*?)>,/g,"").replace(/'/g,"\"")
obj = JSON.parse(obj)
console.log(obj)
$("#totalSessionNums").val(data.userCounts)
}else{
......
......@@ -616,7 +616,8 @@ function getAllUsers(){
success:function(data){
if(data.status == 200){
//window.location.reload()
obj = data.result
obj = data.result.replace(/'service'(.*?)>,/g,"").replace(/'/g,"\"")
obj = JSON.parse(obj)
console.log(obj)
$("#totalSessionNums").val(data.userCounts)
}else{
......
......@@ -600,7 +600,9 @@ function getAllUsers(){
success:function(data){
if(data.status == 200){
//window.location.reload()
obj = data.result
//obj = data.result
obj = data.result.replace(/'service'(.*?)>,/g,"").replace(/'/g,"\"")
obj = JSON.parse(obj)
console.log(obj)
$("#totalSessionNums").val(data.userCounts)
}else{
......
......@@ -89,6 +89,7 @@ def porcessConnect():
timeArray = time.localtime(int(time.time()))
curTime = time.strftime("%Y-%m-%d %H:%M:%S", timeArray)
connects[sessionId]["time"] = curTime
connects[sessionId]["carId"] = params["carId"]
ip = request.remote_addr
connects[sessionId]["ip"] = ip
data["status"] = "200"
......
......@@ -90,6 +90,7 @@ def porcessConnect():
timeArray = time.localtime(int(time.time()))
curTime = time.strftime("%Y-%m-%d %H:%M:%S", timeArray)
connects[sessionId]["time"] = curTime
connects[sessionId]["carId"] = params["phoneNum"]
ip = request.remote_addr
connects[sessionId]["ip"] = ip
data["status"] = "200"
......
......@@ -93,6 +93,7 @@ def createConect():
timeArray = time.localtime(int(time.time()))
curTime = time.strftime("%Y-%m-%d %H:%M:%S", timeArray)
connects[sessionId]["time"] = curTime
connects[sessionId]["carId"] = params["carId"]
ip = request.remote_addr
connects[sessionId]["ip"] = ip
data["status"] = "200"
......
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