From d881cd7eb30866d2792ffa5ec552d7071cac6635 Mon Sep 17 00:00:00 2001
From: panlinlin <648540858@qq.com>
Date: 星期四, 27 五月 2021 09:18:47 +0800
Subject: [PATCH] 解决录像回放未判断是否等待编码导致的回放失败
---
web_src/src/components/dialog/easyPlayer.vue | 10 +++++++---
1 files changed, 7 insertions(+), 3 deletions(-)
diff --git a/web_src/src/components/dialog/easyPlayer.vue b/web_src/src/components/dialog/easyPlayer.vue
index 71d858e..c79f65d 100644
--- a/web_src/src/components/dialog/easyPlayer.vue
+++ b/web_src/src/components/dialog/easyPlayer.vue
@@ -14,10 +14,14 @@
},
props: ['videoUrl', 'error', 'hasaudio'],
mounted () {
+ let paramUrl = decodeURIComponent(this.$route.params.url)
this.$nextTick(() =>{
- console.log("鍒濆鍖栨椂鐨勫湴鍧�涓�: " + this.videoUrl)
- this.easyPlayer = new WasmPlayer(null, 'easyplayer', this.eventcallbacK)
- this.easyPlayer.play(this.videoUrl, 1)
+ if (typeof (this.videoUrl) == "undefined") {
+ this.videoUrl = paramUrl;
+ }
+ console.log("鍒濆鍖栨椂鐨勫湴鍧�涓�: " + this.videoUrl)
+ this.easyPlayer = new WasmPlayer(null, 'easyplayer', this.eventcallbacK)
+ this.easyPlayer.play(this.videoUrl, 1)
})
},
watch:{
--
Gitblit v1.8.0