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
3b2948ba
Commit
3b2948ba
authored
Aug 26, 2022
by
SQL_Mou
Browse files
Options
Browse Files
Download
Plain Diff
Merge branch 'master' of
http://h.gemho.cn:7099/caicaicai/truckDispatching
parents
bfb4ec8c
f9def99c
Changes
4
Hide whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
373 additions
and
103 deletions
+373
-103
common.js
src/assets/js/common.js
+25
-0
index.vue
src/views/MLargeScreen/components/dataAnalysis/index.vue
+0
-2
index.vue
src/views/MLargeScreen/components/dataScreening/index.vue
+11
-11
index.vue
...iews/MLargeScreen/components/intelligentSchedul/index.vue
+337
-90
No files found.
src/assets/js/common.js
View file @
3b2948ba
...
@@ -1168,6 +1168,7 @@ var HttpReq = function(){
...
@@ -1168,6 +1168,7 @@ var HttpReq = function(){
data
:
data
,
data
:
data
,
})
})
},
},
//绩效统计——日报——区域产量报表采区
//绩效统计——日报——区域产量报表采区
caiquAreaQueryDay
:
function
(
param
){
caiquAreaQueryDay
:
function
(
param
){
return
request
({
return
request
({
...
@@ -1943,6 +1944,30 @@ var HttpReq = function(){
...
@@ -1943,6 +1944,30 @@ var HttpReq = function(){
data
:
data
,
data
:
data
,
})
})
},
},
//大屏——数据总览——采区产量统计——日产量
apiPlanDayQuery
:
function
(
param
){
return
request
({
url
:
'
/api/Plan/Day
'
,
method
:
'
get
'
,
params
:
param
,
})
},
//大屏——数据总览——采区产量统计——月产量
apiPlanMonthQuery
:
function
(
param
){
return
request
({
url
:
'
/api/Plan/Month
'
,
method
:
'
get
'
,
params
:
param
,
})
},
//大屏——数据总览——采区产量统计——年产量
apiPlanYearQuery
:
function
(
param
){
return
request
({
url
:
'
/api/Plan/Year
'
,
method
:
'
get
'
,
params
:
param
,
})
},
//大屏——数据总览——司机信息
//大屏——数据总览——司机信息
screenDriverInformationQuery
:
function
(
param
){
screenDriverInformationQuery
:
function
(
param
){
return
request
({
return
request
({
...
...
src/views/MLargeScreen/components/dataAnalysis/index.vue
View file @
3b2948ba
...
@@ -197,7 +197,6 @@ export default {
...
@@ -197,7 +197,6 @@ export default {
})
})
//各采区当月完成率 和 月生产完成效率
//各采区当月完成率 和 月生产完成效率
HttpReq
.
truckDispatching
.
caiquAreaQueryMonth
().
then
((
res
)
=>
{
HttpReq
.
truckDispatching
.
caiquAreaQueryMonth
().
then
((
res
)
=>
{
console
.
log
(
res
);
let
eh2_1_arr1
=
[];
let
eh2_1_arr1
=
[];
let
eh2_1_arr2
=
[];
let
eh2_1_arr2
=
[];
let
eh2_1_arr3
=
[];
let
eh2_1_arr3
=
[];
...
@@ -440,7 +439,6 @@ export default {
...
@@ -440,7 +439,6 @@ export default {
})
})
//各采区当月完成率 和 月生产完成效率
//各采区当月完成率 和 月生产完成效率
HttpReq
.
truckDispatching
.
caiquAreaQueryMonth
().
then
((
res
)
=>
{
HttpReq
.
truckDispatching
.
caiquAreaQueryMonth
().
then
((
res
)
=>
{
console
.
log
(
res
);
let
eh2_1_arr1
=
[];
let
eh2_1_arr1
=
[];
let
eh2_1_arr2
=
[];
let
eh2_1_arr2
=
[];
let
eh2_1_arr3
=
[];
let
eh2_1_arr3
=
[];
...
...
src/views/MLargeScreen/components/dataScreening/index.vue
View file @
3b2948ba
...
@@ -478,12 +478,12 @@ export default {
...
@@ -478,12 +478,12 @@ export default {
},
},
//矿石开采效率
//矿石开采效率
exploitationEfficiencyData
:{
exploitationEfficiencyData
:{
rate1
:[
0.
4
],
rate1
:[
0.
5
],
dayYield1
:
5
1
,
dayYield1
:
5
0
,
dayMil1
:
3
2
,
dayMil1
:
3
0
,
rate2
:[
0.
2
],
rate2
:[
0.
5
],
dayWorkTime2
:
8
,
dayWorkTime2
:
8
,
dayYield2
:
5
1
,
dayYield2
:
5
0
,
},
},
//实时报警
//实时报警
realAlarmStyleData
:{
realAlarmStyleData
:{
...
@@ -501,7 +501,7 @@ export default {
...
@@ -501,7 +501,7 @@ export default {
this
.
$nextTick
(()
=>
{
this
.
$nextTick
(()
=>
{
//获取采区当前日产量
//获取采区当前日产量
HttpReq
.
truckDispatching
.
caiquAreaQueryDa
y
().
then
((
res
)
=>
{
HttpReq
.
truckDispatching
.
apiPlanDayQuer
y
().
then
((
res
)
=>
{
let
undueArray
=
{};
let
undueArray
=
{};
if
(
res
.
length
==
0
||
JSON
.
stringify
(
res
[
0
])
==
'
{}
'
){
if
(
res
.
length
==
0
||
JSON
.
stringify
(
res
[
0
])
==
'
{}
'
){
undueArray
.
eff
=
0
;
undueArray
.
eff
=
0
;
...
@@ -525,7 +525,7 @@ export default {
...
@@ -525,7 +525,7 @@ export default {
this
.
outputMineData
.
day
=
undueArray
;
this
.
outputMineData
.
day
=
undueArray
;
})
})
//获取采区当前月产量
//获取采区当前月产量
HttpReq
.
truckDispatching
.
caiquAreaQueryMonth
().
then
((
res
)
=>
{
HttpReq
.
truckDispatching
.
apiPlanMonthQuery
().
then
((
res
)
=>
{
let
undueArray
=
{};
let
undueArray
=
{};
if
(
res
.
length
==
0
||
JSON
.
stringify
(
res
[
0
])
==
'
{}
'
){
if
(
res
.
length
==
0
||
JSON
.
stringify
(
res
[
0
])
==
'
{}
'
){
undueArray
.
eff
=
0
;
undueArray
.
eff
=
0
;
...
@@ -549,7 +549,7 @@ export default {
...
@@ -549,7 +549,7 @@ export default {
this
.
outputMineData
.
month
=
undueArray
;
this
.
outputMineData
.
month
=
undueArray
;
})
})
//获取采区当前年产量
//获取采区当前年产量
HttpReq
.
truckDispatching
.
caiquAreaQueryYear
().
then
((
res
)
=>
{
HttpReq
.
truckDispatching
.
apiPlanYearQuery
().
then
((
res
)
=>
{
let
undueArray
=
{};
let
undueArray
=
{};
if
(
res
.
length
==
0
||
JSON
.
stringify
(
res
[
0
])
==
'
{}
'
){
if
(
res
.
length
==
0
||
JSON
.
stringify
(
res
[
0
])
==
'
{}
'
){
undueArray
.
eff
=
0
;
undueArray
.
eff
=
0
;
...
@@ -723,7 +723,7 @@ export default {
...
@@ -723,7 +723,7 @@ export default {
//定时刷新数据
//定时刷新数据
this
.
dataScreeningTimer
=
setInterval
(()
=>
{
this
.
dataScreeningTimer
=
setInterval
(()
=>
{
//获取采区当前日产量
//获取采区当前日产量
HttpReq
.
truckDispatching
.
caiquAreaQueryDa
y
().
then
((
res
)
=>
{
HttpReq
.
truckDispatching
.
apiPlanDayQuer
y
().
then
((
res
)
=>
{
let
undueArray
=
{};
let
undueArray
=
{};
if
(
res
.
length
==
0
||
JSON
.
stringify
(
res
[
0
])
==
'
{}
'
){
if
(
res
.
length
==
0
||
JSON
.
stringify
(
res
[
0
])
==
'
{}
'
){
undueArray
.
eff
=
0
;
undueArray
.
eff
=
0
;
...
@@ -747,7 +747,7 @@ export default {
...
@@ -747,7 +747,7 @@ export default {
this
.
outputMineData
.
day
=
undueArray
;
this
.
outputMineData
.
day
=
undueArray
;
})
})
//获取采区当前月产量
//获取采区当前月产量
HttpReq
.
truckDispatching
.
caiquAreaQueryMonth
().
then
((
res
)
=>
{
HttpReq
.
truckDispatching
.
apiPlanMonthQuery
().
then
((
res
)
=>
{
let
undueArray
=
{};
let
undueArray
=
{};
if
(
res
.
length
==
0
||
JSON
.
stringify
(
res
[
0
])
==
'
{}
'
){
if
(
res
.
length
==
0
||
JSON
.
stringify
(
res
[
0
])
==
'
{}
'
){
undueArray
.
eff
=
0
;
undueArray
.
eff
=
0
;
...
@@ -771,7 +771,7 @@ export default {
...
@@ -771,7 +771,7 @@ export default {
this
.
outputMineData
.
month
=
undueArray
;
this
.
outputMineData
.
month
=
undueArray
;
})
})
//获取采区当前年产量
//获取采区当前年产量
HttpReq
.
truckDispatching
.
caiquAreaQueryYear
().
then
((
res
)
=>
{
HttpReq
.
truckDispatching
.
apiPlanYearQuery
().
then
((
res
)
=>
{
let
undueArray
=
{};
let
undueArray
=
{};
if
(
res
.
length
==
0
||
JSON
.
stringify
(
res
[
0
])
==
'
{}
'
){
if
(
res
.
length
==
0
||
JSON
.
stringify
(
res
[
0
])
==
'
{}
'
){
undueArray
.
eff
=
0
;
undueArray
.
eff
=
0
;
...
...
src/views/MLargeScreen/components/intelligentSchedul/index.vue
View file @
3b2948ba
...
@@ -34,9 +34,9 @@
...
@@ -34,9 +34,9 @@
</div>
</div>
</div>
</div>
<div
class=
"voiceAppContent_4"
>
<div
class=
"voiceAppContent_4"
>
<el-button
type=
"primary"
@
click=
"toNoticeFn('广播')"
>
{{
guangbo1
}}
</el-button>
<el-button
type=
"primary"
@
click=
"toNoticeFn('广播')"
>
广播
</el-button>
<el-button
type=
"primary"
@
click=
"toNoticeFn('紧急通知')"
>
{{
jinzhitongzhi1
}}
</el-button>
<el-button
type=
"primary"
@
click=
"toNoticeFn('紧急通知')"
>
紧急通知
</el-button>
<el-button
type=
"primary"
@
click=
"toNoticeFn('通话')"
>
{{
tonghua1
}}
</el-button>
<el-button
type=
"primary"
@
click=
"toNoticeFn('通话')"
>
通话
</el-button>
<el-button
type=
"primary"
@
click=
"todispatchChange()"
>
{{
dispatchBtnTitle
}}
</el-button>
<el-button
type=
"primary"
@
click=
"todispatchChange()"
>
{{
dispatchBtnTitle
}}
</el-button>
</div>
</div>
</div>
</div>
...
@@ -56,7 +56,7 @@
...
@@ -56,7 +56,7 @@
<dd
v-for=
"(item,index) in recentNoticeData"
:key=
"index"
>
<dd
v-for=
"(item,index) in recentNoticeData"
:key=
"index"
>
<div>
{{
item
.
noticeClass
}}
</div>
<div>
{{
item
.
noticeClass
}}
</div>
<div>
{{
item
.
createTime
}}
</div>
<div>
{{
item
.
createTime
}}
</div>
<div
style=
"cursor: pointer;text-decoration:underline;"
@
click=
"
selectSituation(item)"
>
录音播放
</div>
<div
style=
"cursor: pointer;text-decoration:underline;"
@
click=
"
item.noticeClass == '智能调度' ? '' : item.noticeClass == '人工调度' ? '' : selectSituation(item)"
>
{{
item
.
noticeClass
==
'
智能调度
'
?
'
无录音
'
:
item
.
noticeClass
==
'
人工调度
'
?
'
无录音
'
:
'
录音播放
'
}}
</div>
</dd>
</dd>
</dl>
</dl>
</div>
</div>
...
@@ -174,17 +174,57 @@
...
@@ -174,17 +174,57 @@
<slot
name=
"bottom"
></slot>
<slot
name=
"bottom"
></slot>
</div>
</div>
<!-- 播放器 -->
<audio
controls
currentTime
autoplay
:src=
'srcUrl'
style=
"display:none;"
></audio>
<audio
controls
currentTime
autoplay
:src=
'srcUrl'
style=
"display:none;"
></audio>
<!-- 语音发起dialog -->
<!-- 语音区域组件 -->
<el-dialog
:title=
"dialogTitle"
:visible.sync=
"dialogVisible"
width=
"30%"
>
<div
class=
"videoListView"
v-if=
"dialogVisible"
>
<span
slot=
"footer"
class=
"dialog-footer"
>
<div
class=
"videoListView_title"
>
{{
dialogTitle
}}
</div>
<el-button
type=
"primary"
@
click=
"recStart"
style=
"font-size:18px;"
:disabled=
'tonghuadisabled'
>
录制语音
</el-button>
<div
style=
"color:white;font-size:14px;margin-bottom:1vh;"
>
若无选中车辆,默认对所有车辆发起
</div>
<el-button
type=
"primary"
@
click=
"recStop"
style=
"font-size:18px;"
>
结束语音
</el-button>
<div
class=
"videoListView_content"
>
<el-button
type=
"primary"
@
click=
"recUploadLast"
style=
"font-size:18px;"
:disabled=
'tonghuadisabled'
>
上传语音
</el-button>
<div
v-for=
"(item,index) in tanchuCarListArray"
:label=
"item"
:key=
"index"
>
{{
item
.
number
}}
</div>
<el-button
@
click=
"dialogVisible = false"
style=
"font-size:18px;"
:disabled=
'tonghuadisabled'
>
取 消
</el-button>
</div>
</span>
<div
style=
"margin-top:10px;display: flex;justify-content: space-evenly;flex-wrap: wrap;"
>
</el-dialog>
<el-button
type=
"primary"
style=
"width:40%;"
@
click=
"recStart"
>
录制语音
</el-button>
<el-button
type=
"primary"
style=
"width:40%;"
@
click=
"recStop"
>
结束语音
</el-button>
</div>
<div
style=
"margin-top:10px;display: flex;justify-content: space-evenly;flex-wrap: wrap;"
>
<el-button
type=
"primary"
style=
"width:40%;"
@
click=
"recUploadLast"
>
上传语音
</el-button>
<el-button
style=
"width:40%;"
@
click=
"quxiaoVideo()"
>
取消语音
</el-button>
</div>
</div>
<!-- 人工调度组件 -->
<div
class=
"peopleScheAssembly"
v-if=
"peopleScheAssemblyShow"
>
<div
style=
"color:white;font-size:14px;margin-bottom:1vh;font-size: 18px;font-weight: 600;"
>
人工调度详情
</div>
<el-form
size=
"small"
label-width=
"100px"
:rules=
"rules"
>
<el-form-item
label=
"目的地"
style=
"display: inline-block;"
class=
"des1"
>
<el-select
v-model=
"desform.destination"
placeholder=
"请选择目的地"
style=
"width:200px;"
>
<el-option
v-for=
"(obj,index) in destinationDataAll"
:label=
"obj.number ? obj.number : obj.name"
:value=
"obj.number ? obj.number : obj.name"
:key=
"index"
></el-option>
</el-select>
</el-form-item>
<el-form-item
label=
"时长"
style=
"display: inline-block;"
class=
"des1"
>
<el-select
v-model=
"desform.duration"
placeholder=
"请选择调度时长"
style=
"width:200px;"
>
<el-option
label=
"单次"
value=
"单次"
></el-option>
<el-option
label=
"一天"
value=
"一天"
></el-option>
<el-option
label=
"长期"
value=
"长期"
></el-option>
</el-select>
</el-form-item>
<el-form-item
label=
"截止日期"
style=
"display: inline-block;"
class=
"des1"
>
<el-date-picker
v-model=
"desform.endTime"
type=
"datetime"
placeholder=
"选择日期时间"
style=
"width:200px;"
:disabled=
'desform.duration != "长期" '
></el-date-picker>
</el-form-item>
<el-form-item
label=
"说明"
style=
"display: inline-block;"
class=
"des1"
>
<el-input
type=
"textarea"
v-model=
"desform.carshow"
style=
"width:200px;"
></el-input>
</el-form-item>
</el-form>
<div
class=
"peopleScheAssemblyBtns"
>
<el-button
type=
"primary"
style=
"height:40px;width:100px;font-size: 16px;"
round
@
click=
"peopleScheAssemblyFn()"
>
确定
</el-button>
<el-button
style=
"height:40px;width:100px;font-size: 16px;"
round
@
click=
"peopleScheAssemblyCloseFn()"
>
取消
</el-button>
</div>
</div>
</div>
</div>
</
template
>
</
template
>
...
@@ -211,6 +251,7 @@ export default {
...
@@ -211,6 +251,7 @@ export default {
carFleetData
:[],
//车队信息
carFleetData
:[],
//车队信息
carsInforData
:[],
//车辆信息
carsInforData
:[],
//车辆信息
selectCarRadioArray
:[],
//多选选中车辆
selectCarRadioArray
:[],
//多选选中车辆
tanchuCarListArray
:[],
//弹出列表选中车辆
recentNoticeData
:[],
//近期通知列表
recentNoticeData
:[],
//近期通知列表
dispatchLoadingNum
:
0
,
//智能调度进行中
dispatchLoadingNum
:
0
,
//智能调度进行中
dispatchFinishNum
:
0
,
//智能调度已完成
dispatchFinishNum
:
0
,
//智能调度已完成
...
@@ -225,22 +266,24 @@ export default {
...
@@ -225,22 +266,24 @@ export default {
qitache
:[],
qitache
:[],
},
},
//各装点车铲比Echarts
//各装点车铲比Echarts
carsProportionData
:[
carsProportionData
:[],
[
28
,
3
,
'
采区一
'
],
dialogTitle
:
'
广播车辆
'
,
[
50
,
7
,
'
采区二
'
],
[
22
,
0
,
'
卸区一
'
],
[
2
,
0
,
'
卸区二
'
],
],
guangbo1
:
'
广播
'
,
jinzhitongzhi1
:
'
紧急通知
'
,
tonghua1
:
'
通话
'
,
dialogTitle
:
''
,
dialogTitle1
:
''
,
dialogTitle1
:
''
,
dialogVisible
:
false
,
dialogVisible
:
false
,
tonghuadisabled
:
false
,
srcUrl
:
null
,
srcUrl
:
null
,
resultBlob
:
null
,
resultBlob
:
null
,
//人工调度配置
desform
:{},
destinationDataAll
:[],
//人工调度调度目的地列表
peopleScheAssemblyShow
:
false
,
rules
:
{
// odd: [
// {required: true, message: '请输入调度单号', trigger: 'blur' }
// ],
},
//录音相关数据
type
:
"
mp3
"
,
type
:
"
mp3
"
,
bitRate
:
16
,
bitRate
:
16
,
sampleRate
:
16000
,
sampleRate
:
16000
,
...
@@ -259,7 +302,11 @@ export default {
...
@@ -259,7 +302,11 @@ export default {
this
.
whetherShow
=
true
;
this
.
whetherShow
=
true
;
this
.
srcUrl
=
null
;
this
.
srcUrl
=
null
;
this
.
selectCarFleet
=
''
;
this
.
selectCarFleet
=
''
;
this
.
dialogVisible
=
false
;
this
.
selectCarRadioArray
=
[];
this
.
selectCarRadioArray
=
[];
this
.
tanchuCarListArray
=
[];
this
.
peopleScheAssemblyShow
=
false
;
this
.
desform
=
{},
this
.
$nextTick
(()
=>
{
this
.
$nextTick
(()
=>
{
//车队信息
//车队信息
...
@@ -274,17 +321,17 @@ export default {
...
@@ -274,17 +321,17 @@ export default {
HttpReq
.
truckDispatching
.
recentNoticeQuery
({
size
:
50
,
sort
:
'
id,desc
'
}).
then
((
res
)
=>
{
HttpReq
.
truckDispatching
.
recentNoticeQuery
({
size
:
50
,
sort
:
'
id,desc
'
}).
then
((
res
)
=>
{
if
(
res
.
code
==
200
){
if
(
res
.
code
==
200
){
this
.
recentNoticeData
=
res
.
data
.
content
;
this
.
recentNoticeData
=
res
.
data
.
content
;
let
flag0
=
[];
//
let flag0 = [];
this
.
recentNoticeData
.
forEach
((
item
)
=>
{
//
this.recentNoticeData.forEach((item)=>{
if
(
item
.
flag
==
0
){
//
if(item.flag == 0){
flag0
.
push
(
item
);
//
flag0.push(item);
}
//
}
})
//
})
if
(
flag0
.
length
==
0
){
//
if(flag0.length == 0){
this
.
dispatchBtnTitle
=
'
人工调度
'
;
//
this.dispatchBtnTitle = '人工调度';
}
else
{
//
}else{
this
.
dispatchBtnTitle
=
flag0
[
0
].
noticeClass
;
//
this.dispatchBtnTitle = flag0[0].noticeClass;
}
//
}
};
};
})
})
//智能调度情况
//智能调度情况
...
@@ -337,30 +384,21 @@ export default {
...
@@ -337,30 +384,21 @@ export default {
//定时器
//定时器
this
.
intelligentSchedulTimer
=
setInterval
(()
=>
{
this
.
intelligentSchedulTimer
=
setInterval
(()
=>
{
//车队信息
HttpReq
.
truckDispatching
.
carFleetQuery
({
size
:
9999
}).
then
((
res
)
=>
{
if
(
res
.
code
==
200
){
this
.
carFleetData
=
res
.
data
.
content
;
};
})
//车辆信息
this
.
loadData2
();
//近期通知列表
//近期通知列表
HttpReq
.
truckDispatching
.
recentNoticeQuery
({
size
:
50
,
sort
:
'
id,desc
'
}).
then
((
res
)
=>
{
HttpReq
.
truckDispatching
.
recentNoticeQuery
({
size
:
50
,
sort
:
'
id,desc
'
}).
then
((
res
)
=>
{
if
(
res
.
code
==
200
){
if
(
res
.
code
==
200
){
this
.
recentNoticeData
=
res
.
data
.
content
;
this
.
recentNoticeData
=
res
.
data
.
content
;
let
flag0
=
[];
// let flag0 = [];
this
.
recentNoticeData
.
forEach
((
item
)
=>
{
// this.recentNoticeData.forEach((item)=>{
if
(
item
.
flag
==
0
){
// if(item.flag == 0){
flag0
.
push
(
item
);
// flag0.push(item);
}
// }
})
// })
if
(
flag0
.
length
==
0
){
// if(flag0.length == 0){
this
.
dispatchBtnTitle
=
'
人工调度
'
;
// this.dispatchBtnTitle = '人工调度';
}
else
{
// }else{
this
.
dispatchBtnTitle
=
flag0
[
0
].
noticeClass
;
// this.dispatchBtnTitle = flag0[0].noticeClass;
}
// }
};
};
})
})
//智能调度情况
//智能调度情况
...
@@ -429,12 +467,18 @@ export default {
...
@@ -429,12 +467,18 @@ export default {
loadData2
()
{
loadData2
()
{
let
query
=
{};
let
query
=
{};
query
.
size
=
9999
;
query
.
size
=
9999
;
query
.
page
=
0
;
query
.
road
=
this
.
selectCarFleet
;
query
.
road
=
this
.
selectCarFleet
;
//车辆
//车辆
HttpReq
.
truckDispatching
.
carInformationQuery
(
query
).
then
((
res
)
=>
{
HttpReq
.
truckDispatching
.
carInformationQuery
(
query
).
then
((
res
)
=>
{
if
(
res
.
code
==
200
){
if
(
res
.
code
==
200
){
this
.
carsInforData
=
res
.
data
.
content
;
this
.
carsInforData
=
res
.
data
.
content
;
let
destination1
=
[];
res
.
data
.
content
.
forEach
((
item
,
index
)
=>
{
if
(
item
.
carclass
==
'
铲车
'
){
destination1
.
push
(
item
);
}
})
this
.
destinationDataAll
=
destination1
;
};
};
})
})
},
},
...
@@ -466,26 +510,141 @@ export default {
...
@@ -466,26 +510,141 @@ export default {
},
},
//发起通知
//发起通知
toNoticeFn
(
text
){
toNoticeFn
(
text
){
this
.
dialogTitle
=
'
发起
'
+
text
;
if
(
text
==
'
广播
'
){
this
.
dialogTitle
=
'
广播车辆
'
;
}
else
if
(
text
==
'
紧急通知
'
){
this
.
dialogTitle
=
'
接到通知的车辆
'
;
}
else
if
(
text
==
'
通话
'
){
this
.
dialogTitle
=
'
连麦的车辆
'
;
}
this
.
dialogTitle1
=
text
;
this
.
dialogTitle1
=
text
;
if
(
JSON
.
stringify
(
this
.
selectCarRadioArray
)
==
'
[]
'
){
this
.
tanchuCarListArray
=
this
.
carsInforData
;
}
else
{
this
.
tanchuCarListArray
=
this
.
selectCarRadioArray
;
}
this
.
dialogVisible
=
true
;
this
.
dialogVisible
=
true
;
//关闭人工调度组件
this
.
peopleScheAssemblyShow
=
false
;
this
.
desform
=
{};
},
//取消发送语音
quxiaoVideo
(){
this
.
dialogVisible
=
false
;
this
.
tanchuCarListArray
=
[];
this
.
selectCarRadioArray
=
[];
},
},
//人工调度和智能调度切换
//人工调度和智能调度切换
todispatchChange
(){
todispatchChange
(){
if
(
this
.
dispatchBtnTitle
==
'
人工调度
'
){
if
(
this
.
dispatchBtnTitle
==
'
人工调度
'
){
this
.
dispatchBtnTitle
=
'
智能调度
'
;
this
.
peopleScheAssemblyShow
=
true
;
this
.
dispatchBtnTitle1
=
'
人工调度
'
;
// this.dispatchBtnTitle = '智能调度';
// this.dispatchBtnTitle1 = '人工调度';
}
else
{
}
else
{
this
.
dispatchBtnTitle
=
'
人工调度
'
;
this
.
dispatchBtnTitle
=
'
人工调度
'
;
this
.
dispatchBtnTitle1
=
'
智能调度
'
;
this
.
dispatchBtnTitle1
=
'
智能调度
'
;
HttpReq
.
truckDispatching
.
recentNoticeAdd
({
noticeClass
:
this
.
dispatchBtnTitle1
,
flag
:
0
}).
then
((
res
)
=>
{
if
(
res
.
code
==
200
){
this
.
$notify
({
title
:
this
.
dispatchBtnTitle1
+
'
发起成功!
'
,
type
:
'
success
'
,
duration
:
2500
});
//近期通知列表
HttpReq
.
truckDispatching
.
recentNoticeQuery
({
size
:
50
,
sort
:
'
id,desc
'
,}).
then
((
res
)
=>
{
if
(
res
.
code
==
200
){
this
.
recentNoticeData
=
res
.
data
.
content
;
};
})
//发起添加调度类型
HttpReq
.
truckDispatching
.
screenDispatchWayAdd
({
dispatcher
:
this
.
dispatchBtnTitle1
}).
then
((
res
)
=>
{})
}
else
{
this
.
$notify
({
title
:
res
.
msg
,
type
:
'
error
'
,
duration
:
2500
})
}
}).
catch
(
function
(
error
)
{});
}
//关闭发起通知组件
this
.
dialogVisible
=
false
;
this
.
tanchuCarListArray
=
[];
},
//发起人工调度
peopleScheAssemblyFn
(){
if
(
JSON
.
stringify
(
this
.
selectCarRadioArray
)
==
'
[]
'
){
this
.
$notify
({
title
:
'
请选择调度车辆!
'
,
type
:
'
warning
'
,
duration
:
2500
});
return
}
if
(
!
this
.
desform
.
destination
){
this
.
$notify
({
title
:
'
请选择调度目的地!
'
,
type
:
'
warning
'
,
duration
:
2500
});
return
}
if
(
!
this
.
desform
.
duration
){
this
.
$notify
({
title
:
'
请选择调度时长!
'
,
type
:
'
warning
'
,
duration
:
2500
});
return
}
}
if
(
this
.
desform
.
duration
==
'
长期
'
&&
!
this
.
desform
.
endTime
){
this
.
$notify
({
title
:
'
请选择调度截止日期!
'
,
type
:
'
warning
'
,
duration
:
2500
});
return
}
this
.
selectCarRadioArray
.
forEach
((
item
,
index
)
=>
{
let
query1
=
{...
this
.
desform
};
query1
.
carNo
=
item
;
HttpReq
.
truckDispatching
.
manualSchedulingAdd
(
query1
).
then
((
res
)
=>
{
if
(
res
.
code
==
200
){
}
else
{
this
.
$notify
({
title
:
res
.
msg
,
type
:
'
error
'
,
duration
:
2500
})
}
}).
catch
(
function
(
error
)
{
});
HttpReq
.
truckDispatching
.
manualOrderAdd
(
query1
).
then
((
res
)
=>
{
if
(
res
.
code
==
200
){
}
else
{
this
.
$notify
({
title
:
res
.
msg
,
type
:
'
error
'
,
duration
:
2500
})
}
}).
catch
(
function
(
error
)
{
});
})
this
.
$notify
({
title
:
'
人工调度发起成功!
'
,
type
:
'
success
'
,
duration
:
2500
});
this
.
peopleScheAssemblyShow
=
false
;
this
.
desform
=
{},
this
.
selectCarRadioArray
=
[];
//切换智能调度
this
.
dispatchBtnTitle
=
'
智能调度
'
;
this
.
dispatchBtnTitle1
=
'
人工调度
'
;
HttpReq
.
truckDispatching
.
recentNoticeAdd
({
noticeClass
:
this
.
dispatchBtnTitle1
,
flag
:
0
}).
then
((
res
)
=>
{
HttpReq
.
truckDispatching
.
recentNoticeAdd
({
noticeClass
:
this
.
dispatchBtnTitle1
,
flag
:
0
}).
then
((
res
)
=>
{
if
(
res
.
code
==
200
){
if
(
res
.
code
==
200
){
this
.
$notify
({
title
:
this
.
dispatchBtnTitle1
+
'
发起成功!
'
,
type
:
'
success
'
,
duration
:
2500
});
//近期通知列表
//近期通知列表
HttpReq
.
truckDispatching
.
recentNoticeQuery
({
size
:
50
,
sort
:
'
id,desc
'
,}).
then
((
res
)
=>
{
HttpReq
.
truckDispatching
.
recentNoticeQuery
({
size
:
50
,
sort
:
'
id,desc
'
,}).
then
((
res
)
=>
{
if
(
res
.
code
==
200
){
if
(
res
.
code
==
200
){
...
@@ -493,7 +652,7 @@ export default {
...
@@ -493,7 +652,7 @@ export default {
};
};
})
})
//发起添加调度类型
//发起添加调度类型
HttpReq
.
truckDispatching
.
screenDispatchWayAdd
({
dispatcher
:
this
.
dispatchBtnTitle1
}).
then
((
res
)
=>
{
})
HttpReq
.
truckDispatching
.
screenDispatchWayAdd
({
dispatcher
:
this
.
dispatchBtnTitle1
}).
then
((
res
)
=>
{})
}
else
{
}
else
{
this
.
$notify
({
this
.
$notify
({
title
:
res
.
msg
,
title
:
res
.
msg
,
...
@@ -501,11 +660,14 @@ export default {
...
@@ -501,11 +660,14 @@ export default {
duration
:
2500
duration
:
2500
})
})
}
}
}).
catch
(
function
(
error
)
{
});
}).
catch
(
function
(
error
)
{});
},
},
//播放录音
//取消人工调度
playSoundRecordingFn
(
id
){
peopleScheAssemblyCloseFn
(){
console
.
log
(
id
);
this
.
peopleScheAssemblyShow
=
false
;
this
.
desform
=
{};
this
.
selectCarRadioArray
=
[];
},
},
//车辆区域分布Echarts
//车辆区域分布Echarts
carsAreaDistributionEcharts
(){
carsAreaDistributionEcharts
(){
...
@@ -822,7 +984,6 @@ export default {
...
@@ -822,7 +984,6 @@ export default {
type
:
'
success
'
,
type
:
'
success
'
,
duration
:
5000
duration
:
5000
});
});
this
.
tonghuadisabled
=
true
;
},
},
recPause
:
function
(){
recPause
:
function
(){
...
@@ -872,7 +1033,6 @@ export default {
...
@@ -872,7 +1033,6 @@ export default {
This
.
reclog
(
"
录音失败:
"
+
s
,
1
);
This
.
reclog
(
"
录音失败:
"
+
s
,
1
);
});
});
this
.
recOpen
();
this
.
recOpen
();
this
.
tonghuadisabled
=
false
;
},
},
...
@@ -886,7 +1046,7 @@ export default {
...
@@ -886,7 +1046,7 @@ export default {
},
},
recUploadLast
:
function
(){
recUploadLast
:
function
(){
let
carNumberString
=
''
;
let
carNumberString
=
''
;
this
.
selectCarRadio
Array
.
forEach
((
item
,
index
)
=>
{
this
.
tanchuCarList
Array
.
forEach
((
item
,
index
)
=>
{
carNumberString
=
carNumberString
+
item
.
number
+
'
;
'
;
carNumberString
=
carNumberString
+
item
.
number
+
'
;
'
;
})
})
carNumberString
=
carNumberString
+
'
pcBigScreen
'
;
carNumberString
=
carNumberString
+
'
pcBigScreen
'
;
...
@@ -945,15 +1105,6 @@ export default {
...
@@ -945,15 +1105,6 @@ export default {
}
}
};
};
reader
.
readAsDataURL
(
blob
);
reader
.
readAsDataURL
(
blob
);
/***方式二:使用FormData用multipart/form-data表单上传文件***/
// let form = new FormData();
// form.append("upfile",blob,"recorder.mp3"); //和普通form表单并无二致,后端接收到upfile参数的文件,文件名为recorder.mp3
// console.log('form',form);
this
.
dialogVisible
=
false
;
},
},
...
@@ -1078,15 +1229,24 @@ export default {
...
@@ -1078,15 +1229,24 @@ export default {
},
},
//播放语音
//播放语音
selectSituation
(
item
){
selectSituation
(
item
){
//注意base64的最后面中括号和引号是不转译的
if
(
!
item
.
videoContent
){
let
bstr
=
this
.
dataURItoBlob
(
item
.
videoContent
);
this
.
$notify
({
const
reader1
=
new
FileReader
();
title
:
'
无语音数据!
'
,
reader1
.
readAsArrayBuffer
(
bstr
);
type
:
'
warning
'
,
reader1
.
onload
=
(
e
)
=>
{
duration
:
2500
const
bufer
=
e
.
srcElement
.
result
;
});
const
blob
=
this
.
addWavHeader
(
bufer
,
16000
,
16
,
1
);
}
else
{
this
.
srcUrl
=
(
window
.
URL
||
webkitURL
).
createObjectURL
(
blob
);
//注意base64的最后面中括号和引号是不转译的
};
let
bstr
=
this
.
dataURItoBlob
(
item
.
videoContent
);
const
reader1
=
new
FileReader
();
reader1
.
readAsArrayBuffer
(
bstr
);
reader1
.
onload
=
(
e
)
=>
{
const
bufer
=
e
.
srcElement
.
result
;
const
blob
=
this
.
addWavHeader
(
bufer
,
16000
,
16
,
1
);
this
.
srcUrl
=
(
window
.
URL
||
webkitURL
).
createObjectURL
(
blob
);
};
}
},
},
addWavHeader
(
samples
,
sampleRateTmp
,
sampleBits
,
channelCount
)
{
addWavHeader
(
samples
,
sampleRateTmp
,
sampleBits
,
channelCount
)
{
const
dataLength
=
samples
.
byteLength
;
const
dataLength
=
samples
.
byteLength
;
...
@@ -1463,4 +1623,91 @@ dd>div{
...
@@ -1463,4 +1623,91 @@ dd>div{
width
:
19vw
;
width
:
19vw
;
height
:
27.5vh
;
height
:
27.5vh
;
}
}
.videoListView
{
position
:
absolute
;
bottom
:
28vh
;
left
:
20vw
;
height
:
47vh
;
width
:
35vh
;
z-index
:
3
;
background
:
no-repeat
center
center
url('~@/assets/images/cutGraph/guzhangshenbankuang1.png')
;
background-size
:
100%
100%
;
padding
:
10px
10px
0px
;
box-sizing
:
border-box
;
}
.videoListView_title
{
color
:
white
;
font-size
:
18px
;
}
.videoListView_content
{
width
:
100%
;
height
:
30vh
;
border
:
1px
solid
rgb
(
24
,
144
,
255
);
border-radius
:
5px
;
display
:
flex
;
flex-wrap
:
wrap
;
align-content
:
flex-start
;
padding-top
:
10px
;
box-sizing
:
border-box
;
overflow-y
:
scroll
;
}
.videoListView_content
::-webkit-scrollbar
{
/*滚动条整体样式*/
width
:
8px
;
/*高宽分别对应横竖滚动条的尺寸*/
height
:
1px
;
}
.videoListView_content
::-webkit-scrollbar-thumb
{
/*滚动条里面小方块*/
border-radius
:
10px
;
background-color
:
#274088
;
background-image
:
-webkit-linear-gradient
(
45deg
,
rgba
(
255
,
255
,
255
,
0.2
)
25%
,
transparent
25%
,
transparent
50%
,
rgba
(
255
,
255
,
255
,
0.2
)
50%
,
rgba
(
255
,
255
,
255
,
0.2
)
75%
,
transparent
75%
,
transparent
);
}
.videoListView_content
::-webkit-scrollbar-track
{
/*滚动条里面轨道*/
box-shadow
:
inset
0
0
5px
rgba
(
0
,
0
,
0
,
0.2
);
background
:
#ededed
;
border-radius
:
10px
;
}
.videoListView_content
>
div
{
margin-bottom
:
10px
;
width
:
49%
;
color
:
rgb
(
24
,
228
,
240
);
text-align
:
center
;
}
.peopleScheAssembly
{
position
:
absolute
;
bottom
:
10vh
;
left
:
20vw
;
height
:
50vh
;
width
:
40vh
;
z-index
:
3
;
background
:
no-repeat
center
center
url('~@/assets/images/cutGraph/guzhangshenbankuang1.png')
;
background-size
:
100%
100%
;
padding
:
10px
10px
0px
;
box-sizing
:
border-box
;
}
.peopleScheAssemblyBtns
{
position
:
absolute
;
bottom
:
5px
;
padding
:
0
15%
10px
;
box-sizing
:
border-box
;
}
</
style
>
<
style
>
.des1
.el-form-item__label
{
color
:
white
;
font-size
:
15px
;
}
</
style
>
</
style
>
\ No newline at end of file
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