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
1a4a833d
Commit
1a4a833d
authored
Apr 12, 2022
by
caicaicai
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
修改
parent
ec92cf7f
Changes
9
Show whitespace changes
Inline
Side-by-side
Showing
9 changed files
with
190 additions
and
96 deletions
+190
-96
.env.development
.env.development
+1
-1
.env.production
.env.production
+1
-1
common.js
src/assets/js/common.js
+10
-0
Map.vue
src/components/mars3d/Map.vue
+81
-29
index.vue
...telligentDispatchManagement/carManualScheduling/index.vue
+23
-22
index.vue
...ispatchManagement/carManualSchedulingManagement/index.vue
+22
-4
index.vue
...ntelligentDispatchManagement/carVoiceSupplement/index.vue
+49
-36
index.vue
...iews/MLargeScreen/components/intelligentSchedul/index.vue
+2
-2
vue.config.js
vue.config.js
+1
-1
No files found.
.env.development
View file @
1a4a833d
...
@@ -3,7 +3,7 @@ ENV = 'development'
...
@@ -3,7 +3,7 @@ ENV = 'development'
# 接口地址
# 接口地址
#VUE_APP_BASE_API = 'http://localhost:8000'
#VUE_APP_BASE_API = 'http://localhost:8000'
VUE_APP_BASE_API = 'http://192.168.0.110:8001'
VUE_APP_BASE_API = 'http://192.168.0.110:8001'
VUE_APP_WS_API = 'ws://
localhost:8000
'
VUE_APP_WS_API = 'ws://
192.168.0.111:8001/webSocket
'
VUE_APP_LOCAL_API = 'http://192.168.0.110:8001'
VUE_APP_LOCAL_API = 'http://192.168.0.110:8001'
VUE_APP_LOCAL_API2 = 'http://192.168.0.110:8001'
VUE_APP_LOCAL_API2 = 'http://192.168.0.110:8001'
...
...
.env.production
View file @
1a4a833d
...
@@ -4,7 +4,7 @@ ENV = 'production'
...
@@ -4,7 +4,7 @@ ENV = 'production'
# 接口地址,注意协议,如果你没有配置 ssl,需要将 https 改为 http
# 接口地址,注意协议,如果你没有配置 ssl,需要将 https 改为 http
VUE_APP_BASE_API = 'https://el-admin.xin'
VUE_APP_BASE_API = 'https://el-admin.xin'
# 如果接口是 http 形式, wss 需要改为 ws
# 如果接口是 http 形式, wss 需要改为 ws
VUE_APP_WS_API = 'ws
s://el-admin.xin
'
VUE_APP_WS_API = 'ws
://192.168.0.111:8001/webSocket
'
VUE_APP_LOCAL_API = 'http://www.wheccloud.com:8002
VUE_APP_LOCAL_API = 'http://www.wheccloud.com:8002
VUE_APP_LOCAL_API2 = 'http://www.wheccloud.com:8002'
VUE_APP_LOCAL_API2 = 'http://www.wheccloud.com:8002'
\ No newline at end of file
src/assets/js/common.js
View file @
1a4a833d
...
@@ -1938,6 +1938,16 @@ var HttpReq = function(){
...
@@ -1938,6 +1938,16 @@ var HttpReq = function(){
params
:
param
,
params
:
param
,
})
})
},
},
//车辆调度——只获取采区接口
onlyGetMiningAreaQuery
:
function
(
param
){
return
request
({
url
:
'
/api/AreaNew/class
'
,
method
:
'
get
'
,
params
:
param
,
})
},
...
...
src/components/mars3d/Map.vue
View file @
1a4a833d
<
template
>
<
template
>
<div
style=
"wight:100%;height:100
vh;position: absolute
;"
>
<div
style=
"wight:100%;height:100
%
;"
>
<div
:id=
"`mars3d-container$
{mapKey}`"
<div
:id=
"`mars3d-container$
{mapKey}`"
:class="['mars3d-container', customClass, { 'mars3d-container-compare-rh' : compare }]">
</div>
:class="['mars3d-container', customClass, { 'mars3d-container-compare-rh' : compare }]">
</div>
...
@@ -42,6 +42,7 @@ export default {
...
@@ -42,6 +42,7 @@ export default {
data
(){
data
(){
return
{
return
{
historyTrajectoryData
:[],
persons
:[
persons
:[
[
"
122.128833
"
,
"
37.526448
"
,
"
500
"
],
[
"
122.128833
"
,
"
37.526448
"
,
"
500
"
],
[
"
122.128638
"
,
"
37.522818
"
,
"
500
"
],
[
"
122.128638
"
,
"
37.522818
"
,
"
500
"
],
...
@@ -89,6 +90,7 @@ export default {
...
@@ -89,6 +90,7 @@ export default {
[
"
122.127833
"
,
"
37.525448
"
,
"
500
"
],
[
"
122.127833
"
,
"
37.525448
"
,
"
500
"
],
],
],
deviceId
:
'
DESKTOP-L56LKGM
'
,
zuobianData
:[],
zuobianData
:[],
toJavaCoordinates
:[],
toJavaCoordinates
:[],
weilanName
:[],
weilanName
:[],
...
@@ -136,8 +138,9 @@ export default {
...
@@ -136,8 +138,9 @@ export default {
//后台获取数据
//后台获取数据
getCoordinate
()
{
getCoordinate
()
{
let
that
=
this
;
let
that
=
this
;
//获取电子围栏
HttpReq
.
truckDispatching
.
screenMapSetUpQuery
({
size
:
9999
}).
then
((
res
)
=>
{
HttpReq
.
truckDispatching
.
screenMapSetUpQuery
({
size
:
9999
}).
then
((
res
)
=>
{
if
(
true
){
if
(
true
){
;
//console.log(res);
//console.log(res);
let
data1
=
[];
let
data1
=
[];
for
(
let
key
in
res
){
for
(
let
key
in
res
){
...
@@ -155,9 +158,38 @@ export default {
...
@@ -155,9 +158,38 @@ export default {
that
.
zuobianData
=
data1
that
.
zuobianData
=
data1
//console.log("zuobianData",that.zuobianData);
//console.log("zuobianData",that.zuobianData);
//console.log("weilanName",that.weilanName);
//console.log("weilanName",that.weilanName);
this
.
$nextTick
(()
=>
{
if
(
this
.
appendToBody
)
{
document
.
body
.
appendChild
(
this
.
$el
)
}
if
(
this
.
mapKey
)
{
this
.
initMars3d
(
this
.
options
)
}
else
{
mars3d
.
Resource
.
fetchJson
({
url
:
this
.
url
}).
then
((
data
)
=>
{
this
.
initMars3d
(
data
.
map3d
)
// 构建地图
})
}
}
})
})
}
})
//获取历史轨迹
HttpReq
.
truckDispatching
.
getAllHistroyCarTrajectoryQuery
({
id
:
that
.
deviceId
}).
then
((
res
)
=>
{
//console.log('获取历史轨迹',res);
if
(
res
.
code
==
200
){
let
obj1
=
{};
let
array1
=
[];
res
.
data
.
line
.
forEach
((
item
,
index
)
=>
{
let
array2
=
[];
array2
.
push
(
item
.
location
.
x
);
array2
.
push
(
item
.
location
.
y
);
array2
.
push
(
'
500
'
);
array1
.
push
(
array2
);
})
obj1
.
name
=
res
.
data
.
devId
;
obj1
.
arrays
=
array1
;
let
hisCenterData
=
[...
that
.
historyTrajectoryData
];
hisCenterData
.
push
(
obj1
);
that
.
historyTrajectoryData
=
[...
hisCenterData
];
this
.
$nextTick
(()
=>
{
this
.
$nextTick
(()
=>
{
if
(
this
.
appendToBody
)
{
if
(
this
.
appendToBody
)
{
...
@@ -171,6 +203,10 @@ export default {
...
@@ -171,6 +203,10 @@ export default {
})
})
}
}
})
})
}
})
},
},
...
@@ -249,19 +285,35 @@ export default {
...
@@ -249,19 +285,35 @@ export default {
that
.
addGraphic_01
(
graphicLayer
,
item
,
that
.
weilanName
[
index
]);
that
.
addGraphic_01
(
graphicLayer
,
item
,
that
.
weilanName
[
index
]);
})
})
//历史轨迹回放
that
.
historyTrajectoryData
.
forEach
(
function
(
item
,
index
){
var
graphicLayer2
=
new
mars3d
.
layer
.
GraphicLayer
();
map
.
addLayer
(
graphicLayer2
);
var
itemText
=
`<table style="width: auto;">
<tr>
<th scope="col" colspan="2" style="text-align:center;font-size:15px;">卡车号码:
${
item
.
name
}
</th>
</tr>
<tr>
<td>名称:卡车二</td>
</tr>
</table>`
;
initGraphicManager
(
graphicLayer2
,
itemText
);
that
.
addGraphic_02
(
graphicLayer2
,
item
.
arrays
,
item
.
name
);
})
//创建矢量数据图层2
//创建矢量数据图层2
//
var graphicLayer1 = new mars3d.layer.GraphicLayer();
var
graphicLayer1
=
new
mars3d
.
layer
.
GraphicLayer
();
//
map.addLayer(graphicLayer1);
map
.
addLayer
(
graphicLayer1
);
// var item
= `
<
table
style
=
"
width: auto;
"
>
var
itemText
=
`<table style="width: auto;">
//
<
tr
>
<tr>
//
<
th
scope
=
"
col
"
colspan
=
"
2
"
style
=
"
text-align:center;font-size:15px;
"
>
卡车号码:鲁
K12345
<
/th
>
<th scope="col" colspan="2" style="text-align:center;font-size:15px;">卡车号码:鲁K12345</th>
//
<
/tr
>
</tr>
//
<
tr
>
<tr>
//
<
td
>
名称:卡车一
<
/td
>
<td>名称:卡车一</td>
//
<
/tr
>
</tr>
//
<
/table>`
;
</table>`
;
// initGraphicManager(graphicLayer1,item
);
initGraphicManager
(
graphicLayer1
,
itemText
);
// this.addGraphic_02(graphicLayer1,this.persons
);
that
.
addGraphic_02
(
graphicLayer1
,
this
.
persons
,
'
卡车一
'
);
// 抛出事件
// 抛出事件
this
.
$emit
(
'
onload
'
,
map
)
this
.
$emit
(
'
onload
'
,
map
)
...
@@ -318,7 +370,7 @@ export default {
...
@@ -318,7 +370,7 @@ export default {
graphicLayer
.
addGraphic
(
graphic
);
//还可以另外一种写法: graphic.addTo(graphicLayer)
graphicLayer
.
addGraphic
(
graphic
);
//还可以另外一种写法: graphic.addTo(graphicLayer)
},
},
//车辆轨迹
//车辆轨迹
addGraphic_02
(
graphicLayer1
,
positions
)
{
addGraphic_02
(
graphicLayer1
,
positions
,
truckName
)
{
var
property
=
new
Cesium
.
SampledPositionProperty
();
var
property
=
new
Cesium
.
SampledPositionProperty
();
var
tempTime
;
var
tempTime
;
...
@@ -345,7 +397,7 @@ export default {
...
@@ -345,7 +397,7 @@ export default {
},
},
},
},
label
:
{
label
:
{
text
:
"
卡车一
"
,
text
:
truckName
,
font_size
:
19
,
font_size
:
19
,
font_family
:
"
楷体
"
,
font_family
:
"
楷体
"
,
color
:
Cesium
.
Color
.
AZURE
,
color
:
Cesium
.
Color
.
AZURE
,
...
...
src/views/IntelligentDispatchManagement/carManualScheduling/index.vue
View file @
1a4a833d
...
@@ -55,7 +55,7 @@
...
@@ -55,7 +55,7 @@
</el-select>
</el-select>
</el-form-item>
</el-form-item>
<el-form-item
label=
"调度截止日期"
style=
"display: inline-block;"
>
<el-form-item
label=
"调度截止日期"
style=
"display: inline-block;"
>
<el-date-picker
v-model=
"form.endTime"
type=
"datetime"
placeholder=
"选择日期时间"
style=
"width:220px;"
></el-date-picker>
<el-date-picker
v-model=
"form.endTime"
type=
"datetime"
placeholder=
"选择日期时间"
style=
"width:220px;"
:disabled=
'form.duration != "长期" '
></el-date-picker>
</el-form-item>
</el-form-item>
<br>
<br>
<el-form-item
label=
"说明"
style=
"display: inline-block;"
>
<el-form-item
label=
"说明"
style=
"display: inline-block;"
>
...
@@ -124,10 +124,8 @@ export default {
...
@@ -124,10 +124,8 @@ export default {
}
}
})
})
//获取区域信息
//获取区域信息
HttpReq
.
truckDispatching
.
RegionalInformationQuery
({
size
:
9999
}).
then
((
res
)
=>
{
HttpReq
.
truckDispatching
.
onlyGetMiningAreaQuery
({
size
:
9999
}).
then
((
res
)
=>
{
if
(
res
.
code
==
200
){
this
.
areaInformationData
=
res
;
this
.
areaInformationData
=
res
.
data
.
content
;
}
})
})
//获取车辆类型
//获取车辆类型
HttpReq
.
truckDispatching
.
carTypeQuery
({
size
:
9999
}).
then
((
res
)
=>
{
HttpReq
.
truckDispatching
.
carTypeQuery
({
size
:
9999
}).
then
((
res
)
=>
{
...
@@ -141,15 +139,12 @@ export default {
...
@@ -141,15 +139,12 @@ export default {
//发起调度
//发起调度
toDispatch
(){
toDispatch
(){
let
that
=
this
;
let
that
=
this
;
let
query1
=
{...
this
.
form
};
this
.
checkDataList
.
forEach
((
item
,
index
)
=>
{
query1
.
carNo
=
JSON
.
stringify
(
this
.
checkDataList
);
let
query1
=
{...
that
.
form
};
query1
.
carNo
=
item
;
HttpReq
.
truckDispatching
.
manualSchedulingAdd
(
query1
).
then
((
res
)
=>
{
HttpReq
.
truckDispatching
.
manualSchedulingAdd
(
query1
).
then
((
res
)
=>
{
if
(
res
.
code
==
200
){
if
(
res
.
code
==
200
){
this
.
$notify
({
title
:
'
车辆调度发起成功!
'
,
type
:
'
success
'
,
duration
:
2500
});
}
else
{
}
else
{
this
.
$notify
({
this
.
$notify
({
title
:
res
.
msg
,
title
:
res
.
msg
,
...
@@ -158,6 +153,12 @@ export default {
...
@@ -158,6 +153,12 @@ export default {
})
})
}
}
}).
catch
(
function
(
error
)
{
});
}).
catch
(
function
(
error
)
{
});
})
this
.
$notify
({
title
:
'
车辆调度发起成功!
'
,
type
:
'
success
'
,
duration
:
2500
});
this
.
query
=
{};
this
.
query
=
{};
this
.
form
=
{};
this
.
form
=
{};
this
.
checkDataList
=
[];
this
.
checkDataList
=
[];
...
...
src/views/IntelligentDispatchManagement/carManualSchedulingManagement/index.vue
View file @
1a4a833d
...
@@ -32,6 +32,7 @@
...
@@ -32,6 +32,7 @@
<el-table
:data=
"tableData"
v-loading=
"loading"
border
style=
"width:auto"
:row-class-name=
"tableRowClassName"
>
<el-table
:data=
"tableData"
v-loading=
"loading"
border
style=
"width:auto"
:row-class-name=
"tableRowClassName"
>
<el-table-column
prop=
"odd"
label=
"调度单号"
align=
"center"
></el-table-column>
<el-table-column
prop=
"odd"
label=
"调度单号"
align=
"center"
></el-table-column>
<el-table-column
prop=
"carclass"
label=
"车辆类型"
align=
"center"
></el-table-column>
<el-table-column
prop=
"carclass"
label=
"车辆类型"
align=
"center"
></el-table-column>
<el-table-column
prop=
"carNo"
label=
"车牌号"
align=
"center"
></el-table-column>
<el-table-column
prop=
"createTime"
label=
"调度时间"
align=
"center"
></el-table-column>
<el-table-column
prop=
"createTime"
label=
"调度时间"
align=
"center"
></el-table-column>
<el-table-column
prop=
"endTime"
label=
"调度截止日期"
align=
"center"
></el-table-column>
<el-table-column
prop=
"endTime"
label=
"调度截止日期"
align=
"center"
></el-table-column>
<el-table-column
prop=
"finishTime"
label=
"完成调度时间"
align=
"center"
></el-table-column>
<el-table-column
prop=
"finishTime"
label=
"完成调度时间"
align=
"center"
></el-table-column>
...
@@ -39,7 +40,7 @@
...
@@ -39,7 +40,7 @@
<el-table-column
prop=
"carshow"
label=
"说明"
align=
"center"
></el-table-column>
<el-table-column
prop=
"carshow"
label=
"说明"
align=
"center"
></el-table-column>
<el-table-column
label=
"操作"
align=
"center"
fixed=
"right"
>
<el-table-column
label=
"操作"
align=
"center"
fixed=
"right"
>
<template
slot-scope=
"scope"
>
<template
slot-scope=
"scope"
>
<
el-button
size=
"mini"
type=
"success"
icon=
"el-icon-view"
@
click=
"showCars(scope.row)"
></el-button
>
<
!--
<el-button
size=
"mini"
type=
"success"
icon=
"el-icon-view"
@
click=
"showCars(scope.row)"
></el-button>
--
>
<el-button
size=
"mini"
type=
"danger"
icon=
"el-icon-delete"
@
click=
"toDelete(scope.row)"
></el-button>
<el-button
size=
"mini"
type=
"danger"
icon=
"el-icon-delete"
@
click=
"toDelete(scope.row)"
></el-button>
</
template
>
</
template
>
</el-table-column>
</el-table-column>
...
@@ -164,17 +165,18 @@ export default {
...
@@ -164,17 +165,18 @@ export default {
//删除提示
//删除提示
toDelete
(
item
)
{
toDelete
(
item
)
{
var
id
=
item
.
id
;
var
id
=
item
.
id
;
var
odd
=
item
.
odd
;
var
itemAll
=
item
;
this
.
$confirm
(
'
确认删除该条数据吗?
'
,
'
提示
'
,
{
this
.
$confirm
(
'
确认删除该条数据吗?
'
,
'
提示
'
,
{
confirmButtonText
:
'
确定
'
,
confirmButtonText
:
'
确定
'
,
cancelButtonText
:
'
取消
'
,
cancelButtonText
:
'
取消
'
,
type
:
'
warning
'
type
:
'
warning
'
}).
then
((
e
)
=>
{
}).
then
((
e
)
=>
{
this
.
reqRemoveProject
([
id
],
odd
)
this
.
reqRemoveProject
([
id
],
itemAll
)
}).
catch
((
e
)
=>
{})
}).
catch
((
e
)
=>
{})
},
},
//删除调度
//删除调度
reqRemoveProject
(
item
){
reqRemoveProject
(
item
,
itemAll
){
//删除调度
HttpReq
.
truckDispatching
.
manualSchedulingDel
(
item
).
then
((
res
)
=>
{
HttpReq
.
truckDispatching
.
manualSchedulingDel
(
item
).
then
((
res
)
=>
{
if
(
res
.
status
==
400
){
if
(
res
.
status
==
400
){
this
.
$notify
({
this
.
$notify
({
...
@@ -191,6 +193,22 @@ export default {
...
@@ -191,6 +193,22 @@ export default {
}
}
this
.
loadData
();
this
.
loadData
();
})
})
let
obj1
=
{...
itemAll
};
delete
obj1
.
id
;
obj1
.
flag
=
1
;
//新增到订单历史
HttpReq
.
truckDispatching
.
personRecordingAdd
(
obj1
).
then
((
res
)
=>
{
if
(
res
.
code
==
200
){
}
else
{
this
.
$notify
({
title
:
res
.
msg
,
type
:
'
error
'
,
duration
:
2500
})
}
}).
catch
(
function
(
error
)
{
});
},
},
currentTime
(
time
){
currentTime
(
time
){
var
date
=
new
Date
(
time
);
var
date
=
new
Date
(
time
);
...
...
src/views/IntelligentDispatchManagement/carVoiceSupplement/index.vue
View file @
1a4a833d
...
@@ -21,7 +21,7 @@
...
@@ -21,7 +21,7 @@
</div>
</div>
<!-- 表格 -->
<!-- 表格 -->
<div
class=
"panel-bottom page-row"
>
<div
class=
"panel-bottom page-row"
>
<h3>
人工补录管理
</h3>
<h3>
订单历史
</h3>
<div
class=
"ctin-box"
>
<div
class=
"ctin-box"
>
<div
class=
"content-within"
>
<div
class=
"content-within"
>
<div
class=
"content-fix"
>
<div
class=
"content-fix"
>
...
@@ -31,15 +31,17 @@
...
@@ -31,15 +31,17 @@
<div
class=
"content"
>
<div
class=
"content"
>
<el-table
:data=
"tableData"
v-loading=
"loading"
border
style=
"width:auto"
:row-class-name=
"tableRowClassName"
>
<el-table
:data=
"tableData"
v-loading=
"loading"
border
style=
"width:auto"
:row-class-name=
"tableRowClassName"
>
<el-table-column
prop=
"odd"
label=
"调度单号"
align=
"center"
></el-table-column>
<el-table-column
prop=
"odd"
label=
"调度单号"
align=
"center"
></el-table-column>
<el-table-column
prop=
"carname"
label=
"车辆类型"
align=
"center"
></el-table-column>
<el-table-column
prop=
"carclass"
label=
"车辆类型"
align=
"center"
></el-table-column>
<el-table-column
prop=
"endTime"
label=
"调度时间"
align=
"center"
></el-table-column>
<el-table-column
prop=
"carNo"
label=
"车牌号"
align=
"center"
></el-table-column>
<el-table-column
prop=
"createTime"
label=
"调度时间"
align=
"center"
></el-table-column>
<el-table-column
prop=
"name"
label=
"调度人"
align=
"center"
></el-table-column>
<el-table-column
prop=
"name"
label=
"调度人"
align=
"center"
></el-table-column>
<
el-table-column
prop=
"startad"
label=
"调度起点"
align=
"center"
></el-table-column
>
<
!--
<el-table-column
prop=
"startad"
label=
"调度起点"
align=
"center"
></el-table-column>
--
>
<el-table-column
prop=
"destination"
label=
"调度目的地"
align=
"center"
></el-table-column>
<el-table-column
prop=
"destination"
label=
"调度目的地"
align=
"center"
></el-table-column>
<el-table-column
prop=
"flag"
label=
"调度类型"
align=
"center"
:formatter=
"flagChange"
></el-table-column>
<el-table-column
prop=
"carshow"
label=
"说明"
align=
"center"
></el-table-column>
<el-table-column
prop=
"carshow"
label=
"说明"
align=
"center"
></el-table-column>
<el-table-column
label=
"操作"
align=
"center"
fixed=
"right"
>
<el-table-column
label=
"操作"
align=
"center"
fixed=
"right"
>
<template
slot-scope=
"scope"
>
<template
slot-scope=
"scope"
>
<
el-button
size=
"mini"
type=
"success"
icon=
"el-icon-view"
@
click=
"showCars(scope.row)"
></el-button
>
<
!--
<el-button
size=
"mini"
type=
"success"
icon=
"el-icon-view"
@
click=
"showCars(scope.row)"
></el-button>
--
>
<el-button
size=
"mini"
type=
"danger"
icon=
"el-icon-delete"
@
click=
"toDelete(scope.row)"
></el-button>
<el-button
size=
"mini"
type=
"danger"
icon=
"el-icon-delete"
@
click=
"toDelete(scope.row)"
></el-button>
</
template
>
</
template
>
</el-table-column>
</el-table-column>
...
@@ -99,12 +101,11 @@
...
@@ -99,12 +101,11 @@
<el-option
label=
"清扫车"
value=
"清扫车"
></el-option>
<el-option
label=
"清扫车"
value=
"清扫车"
></el-option>
</el-select>
</el-select>
</el-form-item>
</el-form-item>
<br>
<!-- <el-form-item label="起点" style="display: inline-block;">
<el-form-item
label=
"起点"
style=
"display: inline-block;"
>
<el-select v-model="formAdd.destination" placeholder="请选择起点" style="width:220px;">
<el-select v-model="formAdd.destination" placeholder="请选择起点" style="width:220px;">
<el-option v-for="(obj,index) in areaInformationDataAdd" :label="obj.name" :value="obj.name" :key="index"></el-option>
<el-option v-for="(obj,index) in areaInformationDataAdd" :label="obj.name" :value="obj.name" :key="index"></el-option>
</el-select>
</el-select>
</el-form-item>
</el-form-item>
-->
<el-form-item
label=
"目的地"
style=
"display: inline-block;"
>
<el-form-item
label=
"目的地"
style=
"display: inline-block;"
>
<el-select
v-model=
"formAdd.startad"
placeholder=
"请选择目的地"
style=
"width:220px;"
>
<el-select
v-model=
"formAdd.startad"
placeholder=
"请选择目的地"
style=
"width:220px;"
>
<el-option
v-for=
"(obj,index) in areaInformationDataAdd"
:label=
"obj.name"
:value=
"obj.name"
:key=
"index"
></el-option>
<el-option
v-for=
"(obj,index) in areaInformationDataAdd"
:label=
"obj.name"
:value=
"obj.name"
:key=
"index"
></el-option>
...
@@ -122,7 +123,7 @@
...
@@ -122,7 +123,7 @@
<el-input
type=
"textarea"
v-model=
"formAdd.carshow"
style=
"width:545px;"
></el-input>
<el-input
type=
"textarea"
v-model=
"formAdd.carshow"
style=
"width:545px;"
></el-input>
</el-form-item>
</el-form-item>
<br>
<br>
<el-button
type=
"primary"
style=
"height:40px;width:100px;margin-left:100px;"
round
@
click=
"toDispatchAdd"
>
调度
</el-button>
<el-button
type=
"primary"
style=
"height:40px;width:100px;margin-left:100px;"
round
@
click=
"toDispatchAdd"
>
确认
</el-button>
</el-form>
</el-form>
</el-dialog>
</el-dialog>
...
@@ -306,9 +307,11 @@ export default {
...
@@ -306,9 +307,11 @@ export default {
param
.
size
=
9999
;
param
.
size
=
9999
;
this
.
$nextTick
(()
=>
{
this
.
$nextTick
(()
=>
{
//获取车辆信息以及状态
//获取车辆信息
HttpReq
.
truckDispatching
.
carPeopStatus1Query
(
param
).
then
((
res
)
=>
{
HttpReq
.
truckDispatching
.
carInformationQuery
(
param
).
then
((
res
)
=>
{
this
.
carInformationDataAdd
=
res
;
if
(
res
.
code
==
200
){
this
.
carInformationDataAdd
=
res
.
data
.
content
;
}
})
})
//获取车队
//获取车队
HttpReq
.
truckDispatching
.
carFleetQuery
({
size
:
9999
}).
then
((
res
)
=>
{
HttpReq
.
truckDispatching
.
carFleetQuery
({
size
:
9999
}).
then
((
res
)
=>
{
...
@@ -317,10 +320,8 @@ export default {
...
@@ -317,10 +320,8 @@ export default {
}
}
})
})
//获取区域信息
//获取区域信息
HttpReq
.
truckDispatching
.
RegionalInformationQuery
({
size
:
9999
}).
then
((
res
)
=>
{
HttpReq
.
truckDispatching
.
onlyGetMiningAreaQuery
({
size
:
9999
}).
then
((
res
)
=>
{
if
(
res
.
code
==
200
){
this
.
areaInformationDataAdd
=
res
;
this
.
areaInformationDataAdd
=
res
.
data
.
content
;
}
})
})
//获取车辆类型
//获取车辆类型
HttpReq
.
truckDispatching
.
carTypeQuery
({
size
:
9999
}).
then
((
res
)
=>
{
HttpReq
.
truckDispatching
.
carTypeQuery
({
size
:
9999
}).
then
((
res
)
=>
{
...
@@ -333,17 +334,14 @@ export default {
...
@@ -333,17 +334,14 @@ export default {
},
},
//发起调度
//发起调度
toDispatchAdd
(){
toDispatchAdd
(){
let
that
=
this
;
this
.
checkDataListAdd
.
forEach
((
item
,
index
)
=>
{
let
query1
=
{...
this
.
formAdd
};
let
query1
=
{...
this
.
formAdd
};
query1
.
carNo
=
JSON
.
stringify
(
this
.
checkDataListAdd
);
query1
.
carNo
=
item
;
query1
.
flag
=
2
;
HttpReq
.
truckDispatching
.
personRecordingAdd
(
query1
).
then
((
res
)
=>
{
HttpReq
.
truckDispatching
.
personRecordingAdd
(
query1
).
then
((
res
)
=>
{
if
(
res
.
code
==
200
){
if
(
res
.
code
==
200
){
this
.
$notify
({
title
:
'
车辆调度发起成功!
'
,
type
:
'
success
'
,
duration
:
2500
});
this
.
loadDataAdd
();
this
.
loadData
();
}
else
{
}
else
{
this
.
$notify
({
this
.
$notify
({
title
:
res
.
msg
,
title
:
res
.
msg
,
...
@@ -352,11 +350,26 @@ export default {
...
@@ -352,11 +350,26 @@ export default {
})
})
}
}
}).
catch
(
function
(
error
)
{
});
}).
catch
(
function
(
error
)
{
});
})
this
.
$notify
({
title
:
'
添加成功!
'
,
type
:
'
success
'
,
duration
:
2500
});
this
.
loadDataAdd
();
this
.
loadData
();
this
.
form
.
toAddVisible
=
false
;
this
.
form
.
toAddVisible
=
false
;
this
.
queryAdd
=
{};
this
.
queryAdd
=
{};
this
.
formAdd
=
{};
this
.
formAdd
=
{};
this
.
checkDataListAdd
=
[];
this
.
checkDataListAdd
=
[];
}
},
//调度状态更改
flagChange
(
row
){
return
row
.
flag
==
0
?
'
智能调度
'
:
row
.
flag
==
1
?
'
人工调度
'
:
row
.
flag
==
2
?
'
人工补录
'
:
row
.
flag
},
}
}
}
}
</
script
>
</
script
>
...
...
src/views/MLargeScreen/components/intelligentSchedul/index.vue
View file @
1a4a833d
...
@@ -399,7 +399,7 @@ export default {
...
@@ -399,7 +399,7 @@ export default {
//初始化weosocket
//初始化weosocket
initWebSocket
(){
initWebSocket
(){
//const wsuri = "ws://114.116.108.246:81/websocket/socketServer?userId="+userId;//连接地址,可加参数
//const wsuri = "ws://114.116.108.246:81/websocket/socketServer?userId="+userId;//连接地址,可加参数
const
wsuri
=
"
ws://192.168.0.111:8001/webSocket?userId=7
"
;
const
wsuri
=
process
.
env
.
VUE_APP_WS_API
+
"
/
"
+
7
;
this
.
websocket
=
new
WebSocket
(
wsuri
);
this
.
websocket
=
new
WebSocket
(
wsuri
);
this
.
websocket
.
onopen
=
this
.
websocketonopen
;
this
.
websocket
.
onopen
=
this
.
websocketonopen
;
this
.
websocket
.
onerror
=
this
.
websocketonerror
;
this
.
websocket
.
onerror
=
this
.
websocketonerror
;
...
...
vue.config.js
View file @
1a4a833d
...
@@ -25,7 +25,7 @@ module.exports = {
...
@@ -25,7 +25,7 @@ module.exports = {
productionSourceMap
:
false
,
productionSourceMap
:
false
,
devServer
:
{
devServer
:
{
// host: 'localhost', // 也可以直接写IP地址这样方便真机测试
// host: 'localhost', // 也可以直接写IP地址这样方便真机测试
host
:
'
192.168.0.10
1
'
,
// 也可以直接写IP地址这样方便真机测试
host
:
'
192.168.0.10
7
'
,
// 也可以直接写IP地址这样方便真机测试
port
:
port
,
port
:
port
,
open
:
true
,
open
:
true
,
overlay
:
{
overlay
:
{
...
...
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