fix: 项目看板安全教育修改以及代码合并

This commit is contained in:
kun 2024-06-13 11:19:41 +08:00
parent e64d92cc64
commit 0d09b54695

View File

@ -1,29 +1,7 @@
<template> <template>
<div class="leftTop"> <div class="leftTop">
<Card title="项目展示"> <Card title="安全教育">
<div class="top-tab" v-if="COMPANY === 'agjt'"> <div class="video-config"></div>
<div
class="tab-box"
:style="boxStyle(item)"
v-for="(item, index) in topText2"
:key="item.id"
@click="activeBtn(item, index)"
>
{{ item.title }}
</div>
</div>
<div class="top-tab" v-else>
<div
class="tab-box"
:style="boxStyle(item)"
v-for="(item, index) in topText"
:key="item.id"
@click="activeBtn(item, index)"
>
{{ item.title }}
</div>
</div>
<div class="href-content" v-if="showVideo == 1"> <div class="href-content" v-if="showVideo == 1">
<el-carousel indicator-position="none" height="450px" style="width: 76%;"> <el-carousel indicator-position="none" height="450px" style="width: 76%;">
<el-carousel-item v-for="(item, index) in videoList" :key="item.id"> <el-carousel-item v-for="(item, index) in videoList" :key="item.id">
@ -38,35 +16,8 @@
</el-carousel> </el-carousel>
</div> </div>
<div class="videoBox" v-if="showVideo == 2" @mouseenter="showChangeVideo = true" @mouseleave="showChangeVideo = false"> <div class="videoBox" v-if="showVideo == 2" @mouseenter="showChangeVideo = true" @mouseleave="showChangeVideo = false">
<el-upload
:action="BASEURL + '/upload/image'"
:on-success="file => handleSuccessTwo(file, 1)"
:on-error="file => handleError(file, 1)"
:beforeUpload="file => handleBeforeUploadVideo(file, 1)"
name="files"
:show-file-list="false"
>
<!-- 更换视频 -->
<span class="change-video" v-if="showChangeVideo">更换视频</span>
</el-upload>
<video :src="BASEURL + '/image/' + projectData.videoUrl" class="videos" autoplay controls loop></video> <video :src="BASEURL + '/image/' + projectData.videoUrl" class="videos" autoplay controls loop></video>
</div> </div>
<div class="imgBox" v-if="showVideo == 3">
<div class="imgs" @mouseenter="showChangeImg = true" @mouseleave="showChangeImg = false">
<el-upload
:action="BASEURL + '/upload/image'"
:on-success="file => handleSuccess(file, 1)"
:on-error="file => handleError(file, 1)"
:beforeUpload="file => handleBeforeUploadPic(file, 1)"
name="files"
:show-file-list="false"
>
<!-- 更换图片 -->
<span class="change-video" v-if="showChangeImg">更换图片</span>
</el-upload>
<img :src="BASEURL + '/image/' + picUrl" alt="" />
</div>
</div>
</Card> </Card>
</div> </div>
</template> </template>
@ -306,15 +257,11 @@ onMounted(async () => {
position: relative; position: relative;
.videoBox { .videoBox {
width: 100%; width: 100%;
height: 92%; height: 100%;
margin-top: 8%;
background: url("@/assets/images/comprehensiveManage/project10.png") no-repeat;
background-size: 100% 100%;
.videos { .videos {
width: 78%; width: 100%;
height: 90%; height: 100%;
margin-left: 11%; object-fit: fill;
margin-top: 1%;
} }
} }
.imgBox { .imgBox {