Kaynağa Gözat

📦 细节修改和其他图片更换

imengyu 12 saat önce
ebeveyn
işleme
f1d9ad7626

+ 1 - 1
src/api/fusion/ProductContent.ts

@@ -3,7 +3,7 @@ import { CommonContentApi } from '../CommonContent';
 export class ProductContentApi extends CommonContentApi {
 
   constructor() {
-    super(9, "文创产品", 278);
+    super(9, "文创产品", 48);
   }
 }
 

BIN
src/assets/images/communicate/Image2.jpg


BIN
src/assets/images/inheritor/Image11.jpg


+ 6 - 0
src/assets/scss/news.scss

@@ -207,6 +207,12 @@
     }
   }
 
+  .news-video {
+    position: relative;
+    width: 100%;
+    height: 50vh;
+    border-radius: 8px;
+  }
   .news-content {
     position: relative;
     min-height: 50vh;

+ 1 - 1
src/components/display/SimpleRichHtml.vue

@@ -7,7 +7,7 @@
         :key="i"
       >
         <div 
-          v-if="content"
+          v-if="content && content != 'null'"
           :data-r-id="id"
           class="content"
           v-html="content"

+ 13 - 0
src/views/NewsDetailView.vue

@@ -19,8 +19,21 @@
             </div>
           </div>
    
+          <video 
+            v-if="newsLoader.content.value.audio"
+            class="news-video mt-3"
+            controls
+            :src="newsLoader.content.value.audio" 
+          />
+          <video 
+            v-else-if="newsLoader.content.value.video"
+            class="news-video mt-3"
+            controls
+            :src="newsLoader.content.value.video" 
+          />
           <!-- 轮播 -->
           <Carousel 
+            v-else
             :itemsToShow="1"
             wrapAround
             :autoPlay="5000"

+ 28 - 13
src/views/fusion/fashion.vue

@@ -1,35 +1,43 @@
 <template>
-  <!-- 文旅融合 - 闽南时尚 -->
+  <!-- 文化传承 - 闽南时尚 -->
    <CommonListPage
     :title="'闽南时尚'"
-    :prevPage="{ title: '文旅融合' }"
     :dropDownNames="[]"
+    :showSearch="true"
     :pageSize="8"
     :load="loadData"
     :loadDetail="loadDetail"
+    :tagsData="tagsData"
+    :defaultSelectTag="tagsData[0].id"
   />
 </template>
 
 <script setup lang="ts">
+import { ref } from 'vue';
 import { GetContentListParams } from '@/api/CommonContent';
-import FashionContent from '@/api/fusion/FashionContent';
+import CustomContent from '@/api/introduction/CustomContent';
+
+let _selectedTag = 0;
 
 async function loadDetail(id: number, item: any) {
-  const res = await FashionContent.getContentDetail(id);
-  res.content = res.content || res.intro as string;
-  res.addItems = [
-  ];
-  return res;
+  return await CustomContent.getContentDetail(
+    id,
+    tagsData.value.find((item) => item.id == _selectedTag)?.modelId || 0
+  );
 }
 async function loadData(
   page: number, 
   pageSize: number,
   selectedTag: number,
   searchText: string,
-  dropDownValues: number[]
+  dropDownValues: number[],
 ) {
-
-  const res = await FashionContent.getContentList(new GetContentListParams(), page, pageSize);
+  _selectedTag = selectedTag;
+  const res = await CustomContent.getContentList(new GetContentListParams()
+    .setModelId(tagsData.value.find((item) => item.id == selectedTag)?.modelId || 0)
+    .setMainBodyColumnId(selectedTag > 0 ? selectedTag : 0)
+    .setKeywords(searchText)
+  , page, pageSize);
 
   return { 
     page: page,
@@ -40,12 +48,19 @@ async function loadData(
         title: item.title,
         desc: item.desc,
         image: item.image,
-        addItems: [
-        ],
+        addItems: [],
       };
     }),
   }
 }
+
+//子分类
+const tagsData = ref([
+  { modelId: 4, id: 276, name: '闽南时尚' },
+  { modelId: 16, id: 191, name: '闽南语经典歌曲' },
+  { modelId: 16, id: 190, name: '南音' },
+  { modelId: 16, id: 189, name: '闽南童谣' },
+]);
 </script>
 
 <style>

+ 18 - 13
src/views/inheritor/activity.vue

@@ -2,7 +2,6 @@
   <!-- 文化传承 - 非遗活动 -->
    <CommonListPage
     :title="'非遗活动'"
-    :prevPage="{ title: '保护传承' }"
     :dropDownNames="[]"
     :showSearch="true"
     :pageSize="8"
@@ -18,21 +17,27 @@ import { ref } from 'vue';
 import { GetContentListParams } from '@/api/CommonContent';
 import CustomContent from '@/api/introduction/CustomContent';
 
+let _selectedTag = 0;
+
 async function loadDetail(id: number, item: any) {
-  return await CustomContent.getContentDetail(id);
+  return await CustomContent.getContentDetail(
+    id,
+    tagsData.value.find((item) => item.id == _selectedTag)?.modelId || 0
+  );
 }
 async function loadData(
   page: number, 
   pageSize: number,
   selectedTag: number,
   searchText: string,
-  dropDownValues: number[]
+  dropDownValues: number[],
 ) {
-
-  const res = await CustomContent.getContentList(new GetContentListParams().setSelfValues({
-    mainBodyColumnId: selectedTag,
-    keywords: searchText,
-  }), page, pageSize);
+  _selectedTag = selectedTag;
+  const res = await CustomContent.getContentList(new GetContentListParams()
+    .setModelId(tagsData.value.find((item) => item.id == selectedTag)?.modelId || 0)
+    .setMainBodyColumnId(selectedTag > 0 ? selectedTag : 0)
+    .setKeywords(searchText)
+  , page, pageSize);
 
   return { 
     page: page,
@@ -43,6 +48,7 @@ async function loadData(
         title: item.title,
         desc: item.desc,
         image: item.image,
+        addItems: [],
       };
     }),
   }
@@ -50,11 +56,10 @@ async function loadData(
 
 //子分类
 const tagsData = ref([
-  { id: 290, name: '全部' },
-  { id: 291, name: '闽南音乐' },
-  { id: 187, name: '讲古' },
-  { id: 292, name: '方言' },
-  { id: 293, name: '民俗习俗' },
+  { modelId: 18, id: 290, name: '全部' },
+  { modelId: 16, id: 187, name: '讲古' },
+  { modelId: 5, id: -1, name: '方言' },
+  { modelId: 4, id: -2, name: '民俗习俗' },
 ]);
 </script>
 

+ 1 - 1
src/views/introduction/custom.vue

@@ -52,7 +52,7 @@ async function loadData(
 const tagsData = ref([
   { id: 245, name: '全部' },
   { id: 246, name: '婚丧嫁娶' },
-  { id: 247, name: '民俗节庆' },
+  { id: 111, name: '民俗节庆' },
   { id: 248, name: '信仰' },
 ]);
 </script>