Toggle navigation
Toggle navigation
This project
Loading...
Sign in
최현영
/
Expresswayinfo24
Go to a project
Toggle navigation
Toggle navigation pinning
Projects
Groups
Snippets
Help
Project
Activity
Repository
Pipelines
Graphs
Issues
4
Merge Requests
0
Wiki
Snippets
Network
Create a new issue
Builds
Commits
Issue Boards
Authored by
최현영
2020-06-13 23:20:13 +0900
Browse Files
Options
Browse Files
Download
Email Patches
Plain Diff
Commit
b1c17d90319138d172752370cf24f79e5e766663
b1c17d90
1 parent
c9120052
Expressway travel time of ICtoIC function added
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
9 additions
and
8 deletions
whereur/app.js
whereur/app.js
View file @
b1c17d9
...
...
@@ -1150,7 +1150,6 @@ function feelead(eventObj, msg){
}
function
timelead
(
eventObj
,
msg
){
var
isstart
=
false
;
var
isend
=
false
;
...
...
@@ -1163,13 +1162,14 @@ function timelead(eventObj, msg){
console
.
log
(
inputoutputIC
[
1
]);
var
length
=
namedata
.
unitLists
.
length
;
for
(
var
i
=
0
;
i
<
length
;
i
++
){
if
(
namedata
.
unitName
==
inputoutputIC
[
0
]){
start
=
namedata
.
unitCode
;
if
(
namedata
.
unitLists
[
i
].
unitName
==
inputoutputIC
[
0
]){
start
=
namedata
.
unitLists
[
i
].
unitCode
;
isstart
=
true
;
}
if
(
namedata
.
unitName
==
inputoutputIC
[
1
]){
end
=
namedata
.
unitCode
;
isend
=
fals
e
;
if
(
namedata
.
unit
Lists
[
i
].
unit
Name
==
inputoutputIC
[
1
]){
end
=
namedata
.
unit
Lists
[
i
].
unit
Code
;
isend
=
tru
e
;
}
}
...
...
@@ -1177,7 +1177,8 @@ function timelead(eventObj, msg){
jsonICtoICtime
(
start
,
end
,
function
(
Object
){
var
avgTime
=
new
Array
();
var
ICtimejson
=
Object
;
var
avgTime
=
ICtimejson
.
realUnitTrtmVO
.
timeAvg
.
split
(
'.'
);
console
.
log
(
ICtimejson
);
var
avgTime
=
ICtimejson
.
realUnitTrtmVO
[
0
].
timeAvg
;
if
(
ICtimejson
.
count
>
0
){
request
.
post
(
{
...
...
@@ -1190,7 +1191,7 @@ function timelead(eventObj, msg){
"messages"
:[
{
"type"
:
"text"
,
"text"
:
ICtimejson
.
realUnitTrtmVO
[
0
].
startUnitNm
+
"나들목에서 "
+
ICtimejson
.
realUnitTrtmVO
[
0
].
endUnitNm
+
"나들목까지 평균 소요시간은 "
+
avg
"text"
:
ICtimejson
.
realUnitTrtmVO
[
0
].
startUnitNm
+
"나들목에서 "
+
ICtimejson
.
realUnitTrtmVO
[
0
].
endUnitNm
+
"나들목까지 평균 소요시간은 "
+
avg
Time
}
]
}
...
...
Please
register
or
login
to post a comment