From 9f5a532c9213a34c7da9271cffd0ec2eb90461b4 Mon Sep 17 00:00:00 2001
From: ZhangXianQiang <1135831638@qq.com>
Date: 星期五, 17 五月 2024 15:03:31 +0800
Subject: [PATCH] Merge branch 'dev-zhang'
---
src/views/onlineStudy/file.vue | 22 +++++++++++++++-------
src/views/user/student/list.vue | 2 +-
2 files changed, 16 insertions(+), 8 deletions(-)
diff --git a/src/views/onlineStudy/file.vue b/src/views/onlineStudy/file.vue
index ad90fdf..d2dd6a2 100644
--- a/src/views/onlineStudy/file.vue
+++ b/src/views/onlineStudy/file.vue
@@ -31,14 +31,16 @@
</el-table-column>
<el-table-column prop="contentType" :formatter="typeFormatter" label="鏂囦欢绫诲瀷">
</el-table-column>
- <el-table-column label="鏂囦欢鍐呭">
+ <el-table-column label="鏂囦欢鍐呭" width="240">
<template slot-scope="scope">
<video controls v-if="scope.row.contentType === 'video'" :src="'/api/files/' + scope.row.contentUrl.url"
class="showContent" />
- <img v-if="scope.row.contentType === 'img'" :src="'/api/files/' + scope.row.contentUrl.url"
- class="showContent" />
- <el-link type="primary" v-if="scope.row.contentType === 'pdf'"
- class="showContent" @click="checkPdf('/api/files/' + scope.row.contentUrl.url)">鐐瑰嚮鏌ョ湅</el-link>
+ <el-image v-if="scope.row.contentType === 'img'" :src="'/api/files/' + scope.row.contentUrl.url"
+ class="showContent"></el-image>
+ <!-- <img v-if="scope.row.contentType === 'img'" :src="'/api/files/' + scope.row.contentUrl.url"
+ class="showContent" /> -->
+ <el-link type="primary" v-if="scope.row.contentType === 'pdf'" class="showContent"
+ @click="checkPdf('/api/files/' + scope.row.contentUrl.url)">鐐瑰嚮鏌ョ湅</el-link>
</template>
</el-table-column>
<el-table-column prop="attachment" label="闄勪欢">
@@ -297,8 +299,9 @@
<style scoped>
.showContent {
- width: 200px;
- height: 100px;
+ width: 100%;
+ min-height: 80px;
+ object-fit: contain;
}
.warp {
@@ -308,4 +311,9 @@
.search {
margin-top: 10px;
}
+::v-deep .el-image__error {
+ position: absolute;
+ top: 0;
+ bottom: 0;
+}
</style>
diff --git a/src/views/user/student/list.vue b/src/views/user/student/list.vue
index ba02de0..5817b89 100644
--- a/src/views/user/student/list.vue
+++ b/src/views/user/student/list.vue
@@ -40,7 +40,7 @@
<el-tag :type="row.condition == '姝e父' || row.condition == null ? 'success' : 'warning'">{{ row.condition ? row.condition : '姝e父' }}</el-tag>
</template>
</el-table-column>
- <el-table-column prop="conditionDetail" label="鍏蜂綋鎯呭喌" show-overflow-tooltip="true"/>
+ <el-table-column prop="conditionDetail" label="鍏蜂綋鎯呭喌" :show-overflow-tooltip="true"/>
<el-table-column prop="sex" label="鎬у埆" width="60px;" :formatter="sexFormatter"/>
<el-table-column prop="phone" label="鎵嬫満鍙�" width="120"/>
<el-table-column prop="createTime" label="鍒涘缓鏃堕棿" width="160px"/>
--
Gitblit v1.8.0