Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
N
NewTruckTerminalSyetem
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
SQL_Mou
NewTruckTerminalSyetem
Commits
8780570f
Commit
8780570f
authored
Apr 24, 2022
by
caicaicai
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
修改
parent
e8979c00
Changes
2
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
33 additions
and
14 deletions
+33
-14
index.vue
src/views/MLargeScreen/components/voiceApplication/index.vue
+31
-12
index.vue
src/views/MLargeScreen/index.vue
+2
-2
No files found.
src/views/MLargeScreen/components/voiceApplication/index.vue
View file @
8780570f
...
@@ -61,6 +61,7 @@
...
@@ -61,6 +61,7 @@
</div>
</div>
</div>
</div>
<!-- 语音所需内容,隐藏无需展示 -->
<div
class=
"main"
style=
"display:none;"
>
<div
class=
"main"
style=
"display:none;"
>
<slot
name=
"top"
></slot>
<slot
name=
"top"
></slot>
...
@@ -181,7 +182,7 @@ export default {
...
@@ -181,7 +182,7 @@ export default {
this
.
searchText
=
''
;
this
.
searchText
=
''
;
this
.
selectCarRadioArray
=
[];
this
.
selectCarRadioArray
=
[];
this
.
situationWhich
=
10000
;
this
.
situationWhich
=
10000
;
this
.
userName1
=
value
;
this
.
userName1
=
value
;
//车牌号
this
.
recOpen
();
this
.
recOpen
();
//车队
//车队
httpGet
(
carFleetQuery
,{
size
:
9999
,
page
:
0
}).
then
((
res
)
=>
{
httpGet
(
carFleetQuery
,{
size
:
9999
,
page
:
0
}).
then
((
res
)
=>
{
...
@@ -235,7 +236,7 @@ export default {
...
@@ -235,7 +236,7 @@ export default {
//初始化weosocket
//初始化weosocket
initWebSocket
(){
initWebSocket
(){
//const wsuri = 'ws://8.143.203.103:9090/webSocket' + '/' + this.userName1;
//const wsuri = 'ws://8.143.203.103:9090/webSocket' + '/' + this.userName1;
const
wsuri
=
'
ws://192.168.0.111:
8001
/webSocket
'
+
'
/
'
+
this
.
userName1
;
const
wsuri
=
'
ws://192.168.0.111:
9090
/webSocket
'
+
'
/
'
+
this
.
userName1
;
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
;
...
@@ -256,13 +257,27 @@ export default {
...
@@ -256,13 +257,27 @@ export default {
console
.
log
(
e
);
console
.
log
(
e
);
let
that
=
this
;
let
that
=
this
;
if
(
e
==
undefined
){
if
(
e
==
undefined
){
let
str1
=
localStorage
.
getItem
(
this
.
userName1
+
'
voiceData
'
);
if
(
!
str1
){
return
return
}
else
{
}
else
{
let
array1
=
[...
that
.
videoContentAllArray
];
let
arr2
=
JSON
.
parse
(
str1
);
array1
.
push
(
JSON
.
parse
(
e
.
data
));
that
.
videoContentAllArray
=
arr2
;
that
.
videoContentAllArray
=
array1
;
}
//that.videoContent = JSON.parse(e.data).contentText;
}
else
{
//that.videoContentUserName = JSON.parse(e.data).toUserId;
let
str1
=
localStorage
.
getItem
(
this
.
userName1
+
'
voiceData
'
);
let
str2
=
JSON
.
parse
(
e
.
data
);
if
(
!
str1
){
let
arr1
=
[];
arr1
.
unshift
(
str2
);
that
.
videoContentAllArray
=
arr1
;
localStorage
.
setItem
(
this
.
userName1
+
'
voiceData
'
,
JSON
.
stringify
(
arr1
));
}
else
{
let
arr2
=
JSON
.
parse
(
str1
);
arr2
.
unshift
(
str2
);
that
.
videoContentAllArray
=
arr2
;
localStorage
.
setItem
(
this
.
userName1
+
'
voiceData
'
,
JSON
.
stringify
(
arr2
));
}
}
}
},
},
//WebSocket数据发送
//WebSocket数据发送
...
@@ -588,6 +603,7 @@ export default {
...
@@ -588,6 +603,7 @@ export default {
this
.
dialogCancel
();
this
.
dialogCancel
();
this
.
waitDialogClickFn
();
this
.
waitDialogClickFn
();
},
},
//播放语音
selectSituation
(
item
){
selectSituation
(
item
){
this
.
recClose
();
this
.
recClose
();
// Blobdata 就是后端返回给你的Blob数据
// Blobdata 就是后端返回给你的Blob数据
...
@@ -601,10 +617,13 @@ export default {
...
@@ -601,10 +617,13 @@ export default {
};
};
},
},
//删除某个语音
selectDeleteSituation
(
index
){
selectDeleteSituation
(
index
){
let
array2
=
[...
this
.
videoContentAllArray
];
let
str1
=
localStorage
.
getItem
(
this
.
userName1
+
'
voiceData
'
);
array2
.
splice
(
index
,
1
);
let
arr3
=
JSON
.
parse
(
str1
);
this
.
videoContentAllArray
=
array2
;
arr3
.
splice
(
index
,
1
);
this
.
videoContentAllArray
=
arr3
;
localStorage
.
setItem
(
this
.
userName1
+
'
voiceData
'
,
JSON
.
stringify
(
arr3
));
},
},
addWavHeader
(
samples
,
sampleRateTmp
,
sampleBits
,
channelCount
)
{
addWavHeader
(
samples
,
sampleRateTmp
,
sampleBits
,
channelCount
)
{
const
dataLength
=
samples
.
byteLength
;
const
dataLength
=
samples
.
byteLength
;
...
...
src/views/MLargeScreen/index.vue
View file @
8780570f
...
@@ -56,9 +56,9 @@
...
@@ -56,9 +56,9 @@
<personalCenter
ref=
"personalCenterMethod"
v-show=
"selectFunction == 6"
/>
<personalCenter
ref=
"personalCenterMethod"
v-show=
"selectFunction == 6"
/>
<smallWindow
ref=
"smallWindowMethod"
v-show=
"selectFunction == 7"
/>
<smallWindow
ref=
"smallWindowMethod"
v-show=
"selectFunction == 7"
/>
<!-- 地图区域 -->
<!-- 地图区域 -->
<div
id=
"centerDiv"
class=
"mapcontainer"
>
<
!--
<
div
id=
"centerDiv"
class=
"mapcontainer"
>
<mars3dViewerMap
:url=
"configUrl"
@
onload=
"onMapload"
/>
<mars3dViewerMap
:url=
"configUrl"
@
onload=
"onMapload"
/>
</div>
</div>
-->
<!-- 电铲待装车辆列表 -->
<!-- 电铲待装车辆列表 -->
<div
class=
"waitingtrucksView"
v-if=
"carclass == '电铲'"
>
<div
class=
"waitingtrucksView"
v-if=
"carclass == '电铲'"
>
<div
class=
"waitingtrucksView_title"
>
待装卡车列表
</div>
<div
class=
"waitingtrucksView_title"
>
待装卡车列表
</div>
...
...
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