Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
N
new-socketemulator
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
李远洪
new-socketemulator
Commits
bb1cc051
Commit
bb1cc051
authored
Jun 04, 2020
by
liyuanhong
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
修复车安优模拟器跑出的轨迹一直显示红色的问题
parent
e1d1923e
Changes
10
Show whitespace changes
Inline
Side-by-side
Showing
10 changed files
with
17 additions
and
6 deletions
+17
-6
data/m300Tools/carData/M202003060518.json
data/m300Tools/carData/M202003060518.json
+1
-1
data/messageTools/carData/012201500010.json
data/messageTools/carData/012201500010.json
+1
-1
data/protocolTools/carData/M202003060520.json
data/protocolTools/carData/M202003060520.json
+1
-1
lib/socket/service/MessageSimulaterService.py
lib/socket/service/MessageSimulaterService.py
+3
-0
templates/m300Tools/report/M_m300Simulater_page.html
templates/m300Tools/report/M_m300Simulater_page.html
+3
-1
templates/messageTools/message/M_simulater_page.html
templates/messageTools/message/M_simulater_page.html
+2
-1
templates/protocolTools/report/M_carSimulater_page.html
templates/protocolTools/report/M_carSimulater_page.html
+3
-1
views/m300Tools/M_m300Simulater_process.py
views/m300Tools/M_m300Simulater_process.py
+1
-0
views/messageTools/M_simulater_process.py
views/messageTools/M_simulater_process.py
+1
-0
views/protocolTools/M_carSimulater_process.py
views/protocolTools/M_carSimulater_process.py
+1
-0
No files found.
data/m300Tools/carData/M202003060518.json
View file @
bb1cc051
{
"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
}}
{
"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
\ No newline at end of file
data/messageTools/carData/012201500010.json
View file @
bb1cc051
{
"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
}}
{
"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
\ No newline at end of file
data/protocolTools/carData/M202003060520.json
View file @
bb1cc051
{
"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
}}}
{
"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
\ No newline at end of file
lib/socket/service/MessageSimulaterService.py
View file @
bb1cc051
...
@@ -254,6 +254,7 @@ class MessageSimulaterService():
...
@@ -254,6 +254,7 @@ class MessageSimulaterService():
gpsParams
[
"baseInfo"
][
"infoTime"
]
=
curTime
gpsParams
[
"baseInfo"
][
"infoTime"
]
=
curTime
gpsParams
[
"baseInfo"
][
"latitude"
]
=
self
.
gpsLine
[
self
.
gpsLineIndex
][
"lat"
]
gpsParams
[
"baseInfo"
][
"latitude"
]
=
self
.
gpsLine
[
self
.
gpsLineIndex
][
"lat"
]
gpsParams
[
"baseInfo"
][
"longtitude"
]
=
self
.
gpsLine
[
self
.
gpsLineIndex
][
"lng"
]
gpsParams
[
"baseInfo"
][
"longtitude"
]
=
self
.
gpsLine
[
self
.
gpsLineIndex
][
"lng"
]
gpsParams
[
"baseInfo"
][
"speed"
]
=
int
(
self
.
data
[
"travelData"
][
"carSpeed"
])
*
10
gpsParams
[
"baseInfo"
][
"directionAngle"
]
=
self
.
getDirAngle
()
gpsParams
[
"baseInfo"
][
"directionAngle"
]
=
self
.
getDirAngle
()
gpsObj
=
Location_msg
()
gpsObj
=
Location_msg
()
gpsMsg
=
gpsObj
.
generateMsg_GUI
(
gpsParams
)
gpsMsg
=
gpsObj
.
generateMsg_GUI
(
gpsParams
)
...
@@ -275,6 +276,7 @@ class MessageSimulaterService():
...
@@ -275,6 +276,7 @@ class MessageSimulaterService():
gpsParams
[
"baseInfo"
][
"infoTime"
]
=
curTime
gpsParams
[
"baseInfo"
][
"infoTime"
]
=
curTime
gpsParams
[
"baseInfo"
][
"latitude"
]
=
self
.
gpsLine
[
self
.
gpsLineIndex
][
"lat"
]
gpsParams
[
"baseInfo"
][
"latitude"
]
=
self
.
gpsLine
[
self
.
gpsLineIndex
][
"lat"
]
gpsParams
[
"baseInfo"
][
"longtitude"
]
=
self
.
gpsLine
[
self
.
gpsLineIndex
][
"lng"
]
gpsParams
[
"baseInfo"
][
"longtitude"
]
=
self
.
gpsLine
[
self
.
gpsLineIndex
][
"lng"
]
gpsParams
[
"baseInfo"
][
"speed"
]
=
int
(
self
.
data
[
"travelData"
][
"carSpeed"
])
*
10
gpsParams
[
"baseInfo"
][
"directionAngle"
]
=
self
.
getDirAngle
()
gpsParams
[
"baseInfo"
][
"directionAngle"
]
=
self
.
getDirAngle
()
gpsObj
=
Location_msg
()
gpsObj
=
Location_msg
()
gpsMsg
=
gpsObj
.
generateMsg_GUI
(
gpsParams
)
gpsMsg
=
gpsObj
.
generateMsg_GUI
(
gpsParams
)
...
@@ -329,6 +331,7 @@ class MessageSimulaterService():
...
@@ -329,6 +331,7 @@ class MessageSimulaterService():
gpsParams
[
"baseInfo"
][
"infoTime"
]
=
curTime
gpsParams
[
"baseInfo"
][
"infoTime"
]
=
curTime
gpsParams
[
"baseInfo"
][
"latitude"
]
=
self
.
gpsLine
[
self
.
gpsLineIndex
][
"lat"
]
gpsParams
[
"baseInfo"
][
"latitude"
]
=
self
.
gpsLine
[
self
.
gpsLineIndex
][
"lat"
]
gpsParams
[
"baseInfo"
][
"longtitude"
]
=
self
.
gpsLine
[
self
.
gpsLineIndex
][
"lng"
]
gpsParams
[
"baseInfo"
][
"longtitude"
]
=
self
.
gpsLine
[
self
.
gpsLineIndex
][
"lng"
]
gpsParams
[
"baseInfo"
][
"speed"
]
=
int
(
self
.
data
[
"travelData"
][
"carSpeed"
])
*
10
gpsParams
[
"baseInfo"
][
"directionAngle"
]
=
self
.
getDirAngle
()
gpsParams
[
"baseInfo"
][
"directionAngle"
]
=
self
.
getDirAngle
()
gpsObj
=
Location_msg
()
gpsObj
=
Location_msg
()
gpsMsg
=
gpsObj
.
generateMsg_GUI
(
gpsParams
)
gpsMsg
=
gpsObj
.
generateMsg_GUI
(
gpsParams
)
...
...
templates/m300Tools/report/M_m300Simulater_page.html
View file @
bb1cc051
...
@@ -583,7 +583,9 @@ function getAllUsers(){
...
@@ -583,7 +583,9 @@ function getAllUsers(){
success
:
function
(
data
){
success
:
function
(
data
){
if
(
data
.
status
==
200
){
if
(
data
.
status
==
200
){
//window.location.reload()
//window.location.reload()
obj
=
data
.
result
//obj = data.result
obj
=
data
.
result
.
replace
(
/'service'
(
.*
?)
>,/g
,
""
).
replace
(
/'/g
,
"
\"
"
)
obj
=
JSON
.
parse
(
obj
)
console
.
log
(
obj
)
console
.
log
(
obj
)
$
(
"
#totalSessionNums
"
).
val
(
data
.
userCounts
)
$
(
"
#totalSessionNums
"
).
val
(
data
.
userCounts
)
}
else
{
}
else
{
...
...
templates/messageTools/message/M_simulater_page.html
View file @
bb1cc051
...
@@ -616,7 +616,8 @@ function getAllUsers(){
...
@@ -616,7 +616,8 @@ function getAllUsers(){
success
:
function
(
data
){
success
:
function
(
data
){
if
(
data
.
status
==
200
){
if
(
data
.
status
==
200
){
//window.location.reload()
//window.location.reload()
obj
=
data
.
result
obj
=
data
.
result
.
replace
(
/'service'
(
.*
?)
>,/g
,
""
).
replace
(
/'/g
,
"
\"
"
)
obj
=
JSON
.
parse
(
obj
)
console
.
log
(
obj
)
console
.
log
(
obj
)
$
(
"
#totalSessionNums
"
).
val
(
data
.
userCounts
)
$
(
"
#totalSessionNums
"
).
val
(
data
.
userCounts
)
}
else
{
}
else
{
...
...
templates/protocolTools/report/M_carSimulater_page.html
View file @
bb1cc051
...
@@ -600,7 +600,9 @@ function getAllUsers(){
...
@@ -600,7 +600,9 @@ function getAllUsers(){
success
:
function
(
data
){
success
:
function
(
data
){
if
(
data
.
status
==
200
){
if
(
data
.
status
==
200
){
//window.location.reload()
//window.location.reload()
obj
=
data
.
result
//obj = data.result
obj
=
data
.
result
.
replace
(
/'service'
(
.*
?)
>,/g
,
""
).
replace
(
/'/g
,
"
\"
"
)
obj
=
JSON
.
parse
(
obj
)
console
.
log
(
obj
)
console
.
log
(
obj
)
$
(
"
#totalSessionNums
"
).
val
(
data
.
userCounts
)
$
(
"
#totalSessionNums
"
).
val
(
data
.
userCounts
)
}
else
{
}
else
{
...
...
views/m300Tools/M_m300Simulater_process.py
View file @
bb1cc051
...
@@ -89,6 +89,7 @@ def porcessConnect():
...
@@ -89,6 +89,7 @@ def porcessConnect():
timeArray
=
time
.
localtime
(
int
(
time
.
time
()))
timeArray
=
time
.
localtime
(
int
(
time
.
time
()))
curTime
=
time
.
strftime
(
"
%
Y-
%
m-
%
d
%
H:
%
M:
%
S"
,
timeArray
)
curTime
=
time
.
strftime
(
"
%
Y-
%
m-
%
d
%
H:
%
M:
%
S"
,
timeArray
)
connects
[
sessionId
][
"time"
]
=
curTime
connects
[
sessionId
][
"time"
]
=
curTime
connects
[
sessionId
][
"carId"
]
=
params
[
"carId"
]
ip
=
request
.
remote_addr
ip
=
request
.
remote_addr
connects
[
sessionId
][
"ip"
]
=
ip
connects
[
sessionId
][
"ip"
]
=
ip
data
[
"status"
]
=
"200"
data
[
"status"
]
=
"200"
...
...
views/messageTools/M_simulater_process.py
View file @
bb1cc051
...
@@ -90,6 +90,7 @@ def porcessConnect():
...
@@ -90,6 +90,7 @@ def porcessConnect():
timeArray
=
time
.
localtime
(
int
(
time
.
time
()))
timeArray
=
time
.
localtime
(
int
(
time
.
time
()))
curTime
=
time
.
strftime
(
"
%
Y-
%
m-
%
d
%
H:
%
M:
%
S"
,
timeArray
)
curTime
=
time
.
strftime
(
"
%
Y-
%
m-
%
d
%
H:
%
M:
%
S"
,
timeArray
)
connects
[
sessionId
][
"time"
]
=
curTime
connects
[
sessionId
][
"time"
]
=
curTime
connects
[
sessionId
][
"carId"
]
=
params
[
"phoneNum"
]
ip
=
request
.
remote_addr
ip
=
request
.
remote_addr
connects
[
sessionId
][
"ip"
]
=
ip
connects
[
sessionId
][
"ip"
]
=
ip
data
[
"status"
]
=
"200"
data
[
"status"
]
=
"200"
...
...
views/protocolTools/M_carSimulater_process.py
View file @
bb1cc051
...
@@ -93,6 +93,7 @@ def createConect():
...
@@ -93,6 +93,7 @@ def createConect():
timeArray
=
time
.
localtime
(
int
(
time
.
time
()))
timeArray
=
time
.
localtime
(
int
(
time
.
time
()))
curTime
=
time
.
strftime
(
"
%
Y-
%
m-
%
d
%
H:
%
M:
%
S"
,
timeArray
)
curTime
=
time
.
strftime
(
"
%
Y-
%
m-
%
d
%
H:
%
M:
%
S"
,
timeArray
)
connects
[
sessionId
][
"time"
]
=
curTime
connects
[
sessionId
][
"time"
]
=
curTime
connects
[
sessionId
][
"carId"
]
=
params
[
"carId"
]
ip
=
request
.
remote_addr
ip
=
request
.
remote_addr
connects
[
sessionId
][
"ip"
]
=
ip
connects
[
sessionId
][
"ip"
]
=
ip
data
[
"status"
]
=
"200"
data
[
"status"
]
=
"200"
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment