From 170ee55bd1f0858fdbad3147a72c0f185d49a9a6 Mon Sep 17 00:00:00 2001
From: zhangzengfei <zhangzengfei@smartai.com>
Date: 星期四, 10 三月 2022 11:02:01 +0800
Subject: [PATCH] cameraPlayer 添加h265b播放功能
---
src/components/subComponents/FileUpload/index.vue | 41 ++++++++++++++++++++++-------------------
1 files changed, 22 insertions(+), 19 deletions(-)
diff --git a/src/components/subComponents/FileUpload/index.vue b/src/components/subComponents/FileUpload/index.vue
index 685fd8e..796d99f 100644
--- a/src/components/subComponents/FileUpload/index.vue
+++ b/src/components/subComponents/FileUpload/index.vue
@@ -10,7 +10,7 @@
@complete="onComplete"
>
<el-input :placeholder="uploadPlaceholder" size="small" :readonly="true" v-model="fileName">
- <uploader-btn slot="suffix" >
+ <uploader-btn slot="suffix">
<el-tooltip :content="tipWords" placement="top" v-if="tip">
<i class="el-icon-upload2" style="font-size:18px; color:#0088ff"></i>
</el-tooltip>
@@ -31,7 +31,7 @@
@complete="onComplete"
@close="closeHandle"
>
- <uploader-btn ref="button">
+ <uploader-btn ref="button" :sourceType="sourceType">
<i class="el-icon-upload2" style="font-size:18px; color:#0088ff"></i>
涓婁紶
</uploader-btn>
@@ -53,6 +53,9 @@
UploaderList
},
props: {
+ sourceType: {
+ type: Number,
+ },
tip: {
type: Boolean,
default: false
@@ -73,14 +76,22 @@
type: String,
default: "/data/api-f/file/upload" //"//192.168.20.10:3000/upload"
},
+ attrs: {
+ type: Object,
+ default () {
+ return {
+
+ }
+ }
+ }
},
data() {
return {
fileName: "",
fileMd5: "",
- attrs: {
- accept: 'image/*'
- },
+ // attrs: {
+ // accept: 'image/*'
+ // },
statusText: {
success: '涓婁紶鎴愬姛',
error: '涓婁紶澶辫触',
@@ -148,15 +159,6 @@
}
},
computeMD5Success(md5, file) {
- // 灏嗚嚜瀹氫箟鍙傛暟鐩存帴鍔犺浇uploader瀹炰緥鐨刼pts涓�
- // if (this.$route.path.indexOf("VideoManage") >= 0) {
- // Object.assign(this.uploader.opts, {
- // query: {
- // stackId: this.DataStackPool.selectedDir.id
- // // ...this.params,
- // }
- // })
- // }
//灏嗚嚜瀹氫箟鍙傛暟鐩存帴鍔犺浇uploader瀹炰緥鐨刼pts涓�
if (location.href.indexOf("dataStack") >= 0) {
Object.assign(this.uploader.opts, {
@@ -171,7 +173,6 @@
this.statusText.paused = "鏆傚仠涓�";
},
onComplete() {
- debugger
this.$emit("complete", { filename: this.fileName, identifier: this.fileMd5 });
},
fileComplete() {
@@ -183,6 +184,7 @@
},
mounted() {
this.$nextTick(() => {
+ console.log(this.sourceType)
window.uploader = this.$refs.uploader.uploader
})
}
@@ -191,10 +193,11 @@
<style lang="scss">
.file-uploader {
- .el-input__suffix,.el-input__suffix-inner{
- outline: none!important;
+ .el-input__suffix,
+ .el-input__suffix-inner {
+ outline: none !important;
}
- .el-tooltip.focusing{
+ .el-tooltip.focusing {
outline: none;
}
.uploader-example {
@@ -223,7 +226,7 @@
display: none;
}
.uploader-btn {
- border: 0px;
+ border: 0px;
}
.uploader-file {
height: 2px;
--
Gitblit v1.8.0