Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
卡
卡车调度系统
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
caicaicai
卡车调度系统
Commits
c161b682
Commit
c161b682
authored
Oct 18, 2022
by
xxx
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
1
parent
39cb5713
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
70 additions
and
1 deletion
+70
-1
carsEZUIKitJs.vue
src/components/ezuikit/carsEZUIKitJs.vue
+63
-1
vue.config.js
vue.config.js
+7
-0
No files found.
src/components/ezuikit/carsEZUIKitJs.vue
View file @
c161b682
...
...
@@ -59,6 +59,7 @@
<
script
>
import
{
Tools
,
HttpReq
,
Dates
}
from
'
@/assets/js/common.js
'
;
import
*
as
echarts
from
'
echarts
'
;
import
axios
from
'
axios
'
export
default
{
data
()
{
...
...
@@ -85,12 +86,23 @@ export default {
total
:
30
,
handle
:
10
,
},
//所有车的信息
allCarData
:
''
,
};
},
mounted
()
{
this
.
getCode
();
this
.
echarts1Fn
();
this
.
echarts2Fn
();
HttpReq
.
truckDispatching
.
carMonitoringCarsQuery
({
size
:
9999
}).
then
((
res
)
=>
{
let
arr1
=
''
;
res
.
content
.
forEach
((
item
,
index
)
=>
{
arr1
=
arr1
+
item
.
carnumber
+
'
,
'
;
})
arr1
=
arr1
.
substring
(
0
,
arr1
.
length
-
1
);
this
.
allCarData
=
arr1
;
this
.
aiTabPositionFn
();
})
},
methods
:
{
getCode
()
{
...
...
@@ -133,7 +145,25 @@ export default {
}
},
aiTabPositionFn
(){
console
.
log
(
this
.
aiTabPosition
);
if
(
this
.
aiTabPosition
==
'
今天
'
){
let
start
=
this
.
currentTime1
(
new
Date
(
new
Date
(
new
Date
().
toLocaleDateString
()).
getTime
()));
let
end
=
this
.
currentTime1
(
new
Date
(
new
Date
(
new
Date
().
toLocaleDateString
()).
getTime
()
+
24
*
60
*
60
*
1000
-
1
));
//可配置参数的方式
axios
.
get
(
'
/jiankong
'
,
{
params
:
{
jsession
:
'
1bf84ae637b843f2af24cf8c1502e9cf
'
,
vehiIdno
:
'
202208221701
'
,
begintime
:
start
,
endtime
:
end
,
armType
:
'
670,671,620,621,624,625,400
'
,
currentPage
:
0
,
pageRecords
:
9999
,
}
}).
then
(
function
(
response
)
{
console
.
log
(
response
.
data
.
alarms
);
})
}
},
//饼图1
echarts1Fn
(){
...
...
@@ -283,6 +313,38 @@ export default {
noPtzCloseFn
(){
this
.
noPtz
=
false
;
},
//转换时间格式(yyyy-mm-dd hh:mm:ss)
currentTime1
(
time
){
var
date
=
new
Date
(
time
);
var
year
=
date
.
getFullYear
();
//年 ,从 Date 对象以四位数字返回年份
var
month
=
date
.
getMonth
()
+
1
;
//月 ,从 Date 对象返回月份 (0 ~ 11) ,date.getMonth()比实际月份少 1 个月
var
day
=
date
.
getDate
();
//日 ,从 Date 对象返回一个月中的某一天 (1 ~ 31)
var
hours
=
date
.
getHours
();
//小时 ,返回 Date 对象的小时 (0 ~ 23)
var
minutes
=
date
.
getMinutes
();
//分钟 ,返回 Date 对象的分钟 (0 ~ 59)
var
seconds
=
date
.
getSeconds
();
//秒 ,返回 Date 对象的秒数 (0 ~ 59)
//修改月份格式
if
(
month
>=
1
&&
month
<=
9
)
{
month
=
"
0
"
+
month
;
}
//修改日期格式
if
(
day
>=
0
&&
day
<=
9
)
{
day
=
"
0
"
+
day
;
}
//修改小时格式
if
(
hours
>=
0
&&
hours
<=
9
)
{
hours
=
"
0
"
+
hours
;
}
//修改分钟格式
if
(
minutes
>=
0
&&
minutes
<=
9
)
{
minutes
=
"
0
"
+
minutes
;
}
//修改秒格式
if
(
seconds
>=
0
&&
seconds
<=
9
)
{
seconds
=
"
0
"
+
seconds
;
}
let
currentFormatDate
=
year
+
"
-
"
+
month
+
"
-
"
+
day
+
"
"
+
hours
+
"
:
"
+
minutes
+
"
:
"
+
seconds
;
return
currentFormatDate
;
},
},
//销毁
beforeDestroy
()
{
...
...
vue.config.js
View file @
c161b682
...
...
@@ -46,6 +46,13 @@ module.exports = {
'
^/auth
'
:
'
auth
'
}
},
'
/jiankong
'
:
{
target
:
'
http://120.224.103.84:8088/StandardApiAction_queryAlarmDetail.action
'
,
changeOrigin
:
true
,
pathRewrite
:
{
'
^/jiankong
'
:
''
}
},
'
/dianziweilan
'
:
{
target
:
process
.
env
.
VUE_APP_BASE_API
,
},
...
...
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