From a52f8c508d08014d1a153cfc02e12b5fc185a3a4 Mon Sep 17 00:00:00 2001
From: k94314517 <8417338+k94314517@user.noreply.gitee.com>
Date: 星期四, 11 七月 2024 15:28:59 +0800
Subject: [PATCH] Merge remote-tracking branch 'origin/master'

---
 admin/src/views/business/news.vue |   57 +++++++++++++++++++++++++++++++++++++++++----------------
 1 files changed, 41 insertions(+), 16 deletions(-)

diff --git a/admin/src/views/business/news.vue b/admin/src/views/business/news.vue
index e42bac7..099963d 100644
--- a/admin/src/views/business/news.vue
+++ b/admin/src/views/business/news.vue
@@ -20,7 +20,7 @@
     <!-- 琛ㄦ牸鍜屽垎椤� -->
     <template v-slot:table-wrap>
       <ul class="toolbar" v-permissions="['business:news:create', 'business:news:delete']">
-        <li><el-button type="primary" @click="$refs.operaNewsWindow.open('鏂板缓璧勮鍜屽畾鍒舵湇鍔′俊鎭〃')" icon="el-icon-plus" v-permissions="['business:news:create']">鏂板缓</el-button></li>
+        <li><el-button type="primary" @click="$refs.operaNewsWindow.open('鏂板缓鎺ㄥ箍璧勮')" icon="el-icon-plus" v-permissions="['business:news:create']">鏂板缓</el-button></li>
         <li><el-button @click="deleteByIdInBatch" icon="el-icon-delete" v-permissions="['business:news:delete']">鍒犻櫎</el-button></li>
       </ul>
       <el-table
@@ -30,29 +30,38 @@
         @selection-change="handleSelectionChange"
       >
         <el-table-column type="selection" width="55"></el-table-column>
-        <el-table-column prop="title" label="鏍囬" min-width="100px"></el-table-column>
-        <el-table-column prop="subTitle" label="鍓爣棰�" min-width="100px"></el-table-column>
-        <el-table-column prop="linkType" label="璺宠浆绫诲瀷" min-width="100px">
+        <el-table-column prop="title" label="鏂囨" fixed min-width="300px"></el-table-column>
+        <el-table-column prop="fileList" label="闄勪欢"  align="center" fixed min-width="250px">>
           <template slot-scope="{row}">
-            <span v-if="row.linkType ==0">瀵屾枃鏈�</span>
-            <span v-if="row.linkType ==1">澶栭摼</span>
+            <div v-if="row.fileType!=1 && row.fileList!=null && row.fileList.length" class="image-container">
+              <div v-for="(item) in row.fileList" :key="item.id" >
+                <el-image
+                    v-if="item.fileurlFull && item.type !=1"
+                    class="image-item"
+                    :src="item.fileurlFull"
+                    fit="fill"
+                    :preview-src-list="[item.fileurlFull]">
+                </el-image>
+              </div>
+            </div>
+            <div v-if="row.fileType == 1 && row.fileList!=null && row.fileList.length" class="image-container">
+              <video v-if="row.fileList[0].fileurlFull"  style="width: 60px;height: 60px"  controls autoplay :src="row.fileList[0].fileurlFull"></video>
+            </div>
           </template>
         </el-table-column>
-        <el-table-column prop="status" label="鐘舵��" min-width="100px">
+        <el-table-column prop="publishDate" label="鍙戝竷鏃堕棿"   min-width="150px"></el-table-column>
+        <el-table-column prop="status" label="鐘舵��"   min-width="80px">
           <template slot-scope="{row}">
-            <span v-if="row.status ==1">涓嶅睍绀�</span>
-            <span v-if="row.status ==0">灞曠ず</span>
+            <span v-if="row.status ==1" style="color:red;">涓嶅睍绀�</span>
+            <span v-if="row.status ==0" style="color:green;">灞曠ず</span>
           </template>
         </el-table-column>
+        <el-table-column prop="publishInfo" label="鍙戝竷澶囨敞" min-width="150px"></el-table-column>
         <el-table-column prop="lookNum" label="娴忚閲�" min-width="80px"></el-table-column>
         <el-table-column prop="donwloadNum" label="涓嬭浇閲�" min-width="80px"></el-table-column>
-        <el-table-column prop="sortnum" label="鎺掑簭鐮�" min-width="100px"></el-table-column>
-        <el-table-column prop="remark" label="澶囨敞" min-width="100px"></el-table-column>
+        <el-table-column prop="sortnum" label="鎺掑簭鐮�" min-width="80px"></el-table-column>
         <el-table-column prop="editorName" label="鎿嶄綔浜�" min-width="100px"></el-table-column>
-        <el-table-column prop="editDate" label="鎿嶄綔鏃堕棿" min-width="100px"></el-table-column>
-        <el-table-column prop="publishDate" label="鏈�杩戝彂甯冩椂闂�" min-width="100px"></el-table-column>
-        <el-table-column prop="publishUserName" label="鏈�杩戝彂甯冧汉" min-width="100px"></el-table-column>
-        <el-table-column prop="publishInfo" label="鏈�杩戝彂甯冨娉�" min-width="100px"></el-table-column>
+        <el-table-column prop="editDate" label="鎿嶄綔鏃堕棿" min-width="150px"></el-table-column>
         <el-table-column
           v-if="containPermissions(['business:news:update', 'business:news:delete'])"
           label="鎿嶄綔"
@@ -60,7 +69,7 @@
           fixed="right"
         >
           <template slot-scope="{row}">
-            <el-button type="text" @click="$refs.operaNewsWindow.open('缂栬緫璧勮鍜屽畾鍒舵湇鍔′俊鎭〃', row)" icon="el-icon-edit" v-permissions="['business:news:update']">缂栬緫</el-button>
+            <el-button type="text" @click="$refs.operaNewsWindow.open('缂栬緫鎺ㄥ箍璧勮', row)" icon="el-icon-edit" v-permissions="['business:news:update']">缂栬緫</el-button>
             <el-button type="text" @click="deleteById(row)" icon="el-icon-delete" v-permissions="['business:news:delete']">鍒犻櫎</el-button>
           </template>
         </el-table-column>
@@ -107,3 +116,19 @@
   }
 }
 </script>
+
+<style scoped>
+.image-container {
+  display: flex; /* 璁惧畾涓� Flexbox 甯冨眬 */
+  flex-wrap: wrap; /* 鍏佽鎹㈣ */
+  justify-content: center; /* 姘村钩鏂瑰悜涓婄殑闂撮殧鍒嗗竷 */
+  align-items: flex-start; /* 鍨傜洿鏂瑰悜涓婄殑椤圭洰瀵归綈 */
+}
+
+.image-item {
+  height: 60px;
+  width: 60px;
+  margin-right: 10px; /* 鍙宠竟璺濓紝浣垮緱鍥剧墖涔嬮棿鏈夐棿闅� */
+  margin-bottom: 10px; /* 搴曢儴杈硅窛锛屼娇寰楀浘鐗囪兘澶熸崲琛� */
+}
+</style>

--
Gitblit v1.9.3