修改
This commit is contained in:
parent
2a7e0470ac
commit
bba19a7869
@ -4,6 +4,7 @@
|
|||||||
<video
|
<video
|
||||||
style="width: 208px; height: 208px"
|
style="width: 208px; height: 208px"
|
||||||
v-bind:src="video.VideoPath"
|
v-bind:src="video.VideoPath"
|
||||||
|
v-if="video.VideoPath"
|
||||||
class="avatar video-avatar"
|
class="avatar video-avatar"
|
||||||
controls="controls"
|
controls="controls"
|
||||||
>您的浏览器不支持视频播放</video>
|
>您的浏览器不支持视频播放</video>
|
||||||
@ -123,14 +124,17 @@ export default {
|
|||||||
this.filedata.type = this.type;
|
this.filedata.type = this.type;
|
||||||
this.items = this.item;
|
this.items = this.item;
|
||||||
this.videoForm.showVideoPath = process.env.VUE_APP_BASE_API + this.tovideo;
|
this.videoForm.showVideoPath = process.env.VUE_APP_BASE_API + this.tovideo;
|
||||||
this.video.VideoPath = process.env.VUE_APP_BASE_API + this.tovideo;
|
if (this.tovideo) {
|
||||||
|
this.video.VideoPath = process.env.VUE_APP_BASE_API + this.tovideo;
|
||||||
|
}
|
||||||
this.title = "上传视频";
|
this.title = "上传视频";
|
||||||
},
|
},
|
||||||
watch: {
|
watch: {
|
||||||
tovideo: {
|
tovideo: {
|
||||||
handler(newimg, oldimg) {
|
handler(newimg, oldimg) {
|
||||||
this.uploadbtn = true;
|
this.uploadbtn = true;
|
||||||
this.videoForm.showVideoPath = process.env.VUE_APP_BASE_API + this.tovideo;
|
this.videoForm.showVideoPath =
|
||||||
|
process.env.VUE_APP_BASE_API + this.tovideo;
|
||||||
this.video.VideoPath = process.env.VUE_APP_BASE_API + this.tovideo;
|
this.video.VideoPath = process.env.VUE_APP_BASE_API + this.tovideo;
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
@ -223,7 +227,8 @@ export default {
|
|||||||
this.uploadbtn = false;
|
this.uploadbtn = false;
|
||||||
uploadVideoUrl(formData).then(response => {
|
uploadVideoUrl(formData).then(response => {
|
||||||
if (response.code == 200) {
|
if (response.code == 200) {
|
||||||
this.video.VideoPath = process.env.VUE_APP_BASE_API + response.imgUrl;
|
this.video.VideoPath =
|
||||||
|
process.env.VUE_APP_BASE_API + response.imgUrl;
|
||||||
this.items.itemDirectoryUrl = response.imgUrl;
|
this.items.itemDirectoryUrl = response.imgUrl;
|
||||||
this.$emit("item", JSON.stringify(this.items));
|
this.$emit("item", JSON.stringify(this.items));
|
||||||
this.openimg = false;
|
this.openimg = false;
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user