fix; bug
This commit is contained in:
@@ -31,6 +31,7 @@
|
||||
import { useStorageStore } from "@/store/storage.js"
|
||||
import { get_base_url } from '@/api/request.js'
|
||||
import imagePreviewVue from './image-preview.vue'
|
||||
import { getToken } from '@/common/common.js'
|
||||
export default {
|
||||
name:"video-preview",
|
||||
components:{ imagePreviewVue },
|
||||
@@ -75,7 +76,7 @@
|
||||
fileId: {
|
||||
handler(newval, oldval) {
|
||||
if(newval.indexOf('http') === 0){
|
||||
this.fileUrlShow = newval
|
||||
this.fileUrlShow = newval + '?tk=' + getToken()
|
||||
}else{
|
||||
if (newval && this.watching) {
|
||||
this.getPreviewUrlBlob(newval);
|
||||
@@ -129,7 +130,7 @@
|
||||
return
|
||||
}
|
||||
let _newDate = new Date().getTime()
|
||||
this.fileUrlShow = getPreviewFileUrl(this.fileId)+'?t=' + _newDate
|
||||
this.fileUrlShow = getPreviewFileUrl(this.fileId) + '?tk=' + getToken() + '&t=' + _newDate
|
||||
// downloadFile(id).then(res=>{
|
||||
// this.fileUrlShow = res.tempFilePath
|
||||
// this.storageStore.setStorage('video', id, this.fileUrlShow)
|
||||
@@ -150,7 +151,7 @@
|
||||
if (this.fileId) {
|
||||
let _newDate = new Date().getTime()
|
||||
if(this.fileId.indexOf('http') === 0){
|
||||
this.fileUrlShow = this.fileId + '?t=' + _newDate
|
||||
this.fileUrlShow = this.fileId + '?tk=' + getToken() + '&t=' + _newDate
|
||||
}else{
|
||||
this.getPreviewUrlBlob(this.fileId);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user