0704会议问题修改

master
lion 1 year ago
parent b3979970d6
commit 3355fc909f

@ -27,13 +27,18 @@
<template v-slot:image_id>
<div class="xy-table-item">
<div class="xy-table-item-label" style="font-weight: bold">
<span style="color: red;font-weight: bold;padding-right: 4px;">*</span>标题图片
<span style="color: red;font-weight: bold;padding-right: 4px;">*</span>标题图片/视频
</div>
<div class="xy-table-item-content">
<el-upload :action="action" :limit='1' class='upload-demo' list-type="picture-card" :file-list="pictureList"
<!-- <el-upload :action="action" :limit='1' class='upload-demo' list-type="picture-card" :file-list="pictureList"
ref="pictureUpload" style="width:600px" :auto-upload="true" :data="uploadOther"
:on-success="handlesuccess" :on-remove="handleRemove">
<i class="el-icon-plus"></i>
</el-upload> -->
<el-upload :action="action" class='upload-demo' :file-list="pictureList" ref="pictureUpload"
style="width:600px;display: flex;flex-wrap: wrap;margin-left:10px" :auto-upload="true" :data="uploadOther" :on-success="handlesuccess"
:on-remove="handleRemove">
<el-button style="width: 100%;text-align: left;" v-if="pictureList.length<1" size="small" type="primary"></el-button>
</el-upload>
</div>
</div>

@ -2,7 +2,10 @@
<div>
<xy-dialog ref="dialog" :width="80" :is-show.sync="isShow" type="form" :title="showform.title" :form="form">
<template v-slot:show>
<div class="article_title">{{showform.title}}</div>
<div class="article_title">{{showform.title}}</div>
<div style="text-align: center;" v-if="extension=='mp4'||extension=='avi'||extension=='wmv'">
<video controls :src="showform.image.url" style="max-width: 600px; max-height: 400px;"></video>
</div>
<div class="article_content">
<div v-html="showform.content"></div>
</div>
@ -54,7 +57,8 @@
fileTitle: '',
form: {
show: ''
},
},
extension:'',
showform: {},
diaShow: false
}
@ -80,19 +84,23 @@
this.$refs.viewFile.diaShow = true
},
closeDia() {
this.isShow = false
this.isShow = false
this.extension = ''
this.showform = {}
this.$emit("refresh", this.isShow)
},
getDetail() {
let that = this
show({
table_name: 'articles',
id: this.id
id: this.id,
with_relations:['image']
}).then(res => {
this.form = {
show: ''
}
this.showform = res
this.showform = res
this.extension = res.image?res.image.extension:''
}).catch(error => {});
}
}

@ -15,10 +15,16 @@
<div class="overall">
<el-carousel height="330px">
<el-carousel-item v-for="item in articleSwiper" :key="item.id">
<el-image
@click="showDashboardArticle(item.id)"
style="width: 100%; height: 100%"
:src="item.image.url"></el-image>
<div @click="showDashboardArticle(item.id)" v-if="item.image.extension=='mp4'||item.image.extension=='avi'||item.image.extension=='wmv'">
<video :src="item.image.url" style="width: 100%; height: 100%"></video>
</div>
<div v-else>
<el-image
@click="showDashboardArticle(item.id)"
style="width: 100%; height: 100%"
:src="item.image.url"></el-image>
</div>
<h3 style="position: absolute;bottom: 0;width: 100%;padding: 10px;color: #fff;background: rgba(0, 0, 0, 0.4);" class="small">{{ item.title }}</h3>
</el-carousel-item>
</el-carousel>

Loading…
Cancel
Save