Quellcode durchsuchen

💄 修改细节问题,增加非遗研学点

快乐的梦鱼 vor 3 Wochen
Ursprung
Commit
1ad374d7db

BIN
src/assets/images/fusion/Image6.jpg


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

@@ -85,6 +85,13 @@
         height: 180px;
       }
     }
+      &.row-type4 {
+        img {
+          object-fit: contain;
+          width: 270px;
+          height: 150px;
+        }
+      }
     &.empty {
       background-color: transparent;
       border: none;
@@ -167,6 +174,12 @@
           height: 90px;
         }
       }
+      &.row-type4 {
+        img {
+          width: 180px;
+          height: 110px;
+        }
+      }
 
       img {
         width: 200px;

+ 5 - 0
src/router/index.ts

@@ -169,6 +169,11 @@ const router = createRouter({
       component: () => import('../views/fusion/fashion.vue'),
     },
     {
+      path: '/fusion/point',
+      name: 'FusionPoint',
+      component: () => import('../views/fusion/point.vue'),
+    },
+    {
       path: '/inheritor',
       name: 'inheritor',
       component: () => import('../views/InheritorView.vue'),

+ 9 - 5
src/views/FusionView.vue

@@ -77,6 +77,7 @@ import Image2 from '@/assets/images/fusion/Image2.jpg'
 import Image3 from '@/assets/images/inheritor/Image3.jpg'
 import Image4 from '@/assets/images/fusion/Image4.jpg'
 import Image5 from '@/assets/images/fusion/Image5.jpg'
+import Image6 from '@/assets/images/fusion/Image6.jpg'
 import LeftRightBox from '@/components/parts/LeftRightBox.vue';
 import ImageTitleDescBlock from '@/components/parts/ImageTitleDescBlock.vue';
 import ThreeImageList from '@/components/parts/ThreeImageList.vue';
@@ -107,6 +108,14 @@ const list = [
     }
   },
   {
+    title: '非遗研学点',
+    desc: '',
+    image: Image6,
+    onClick: () => {
+      navTo('/fusion/point');
+    }
+  },
+  {
     title: '非遗作品',
     desc: '让文化因传承而永存',
     image: Image3,
@@ -130,11 +139,6 @@ const list = [
       navTo('/fusion/fashion');
     }
   },
-  {
-    title: '',
-    desc: '',
-    image: '',
-  }
 ]
 const daysData = ref<GetContentListItem[]>([]) as Ref<GetContentListItem[]>
 const monthSelected = ref(new Date().getMonth() + 1)

+ 3 - 2
src/views/HomeView.vue

@@ -269,8 +269,9 @@ const recommend3Data = useSimpleDataLoader<GetContentListItem[]>(async () => {
   , 1, 8)).list
 });
 const newsData = useSimpleDataLoader<GetContentListItem[]>(async () => {
-  return (await NewsIndexContent.getContentList(new GetContentListParams().setSelfValues({
-  }), 1, 9)).list
+  return (await NewsIndexContent.getContentList(new GetContentListParams()
+    .setMainBodyColumnId([ 228/* , 298, 299 */ ])
+  , 1, 9)).list
 });
 const statsData = useSimpleDataLoader(async () => {
   const data = (await IndexContent.getStats());

+ 60 - 0
src/views/fusion/point.vue

@@ -0,0 +1,60 @@
+<template>
+  <!-- 文旅融合 - 非遗研学点 -->
+   <CommonListPage
+    :title="'非遗研学点'"
+    :prevPage="{ title: '文旅融合' }"
+    :dropDownNames="[]"
+    :pageSize="8"
+    rowType="4"
+    :load="loadData"
+    :loadDetail="loadDetail"
+  />
+</template>
+
+<script setup lang="ts">
+import CommonContent, { GetContentListParams } from '@/api/CommonContent';
+import DiscussContent from '@/api/research/DiscussContent';
+
+async function loadDetail(id: number, item: any) {
+  const res = await DiscussContent.getContentDetail(id);
+  res.content = res.content || res.intro as string;
+  res.addItems = [
+  ];
+  return res;
+}
+async function loadData(
+  page: number, 
+  pageSize: number,
+  selectedTag: number,
+  searchText: string,
+  dropDownValues: number[]
+) {
+
+  const res = await CommonContent.getContentList(new GetContentListParams()
+    .setModelId(17)
+    .setMainBodyColumnId(319)
+    .setKeywords(searchText)
+  , page, pageSize);
+
+  return { 
+    page: page,
+    total: res.total,
+    data: res.list.map((item, index) => {
+      return {
+        id: item.id,
+        title: item.title,
+        desc: item.desc,
+        image: item.image,
+        addItems: [
+          { name: '联系人', text: item.contact as string, span: 12 },
+          { name: '联系电话', text: item.mobile as string, span: 12 },
+        ],
+      };
+    }),
+  }
+}
+</script>
+
+<style>
+</style>
+

+ 1 - 0
src/views/research/discuss.vue

@@ -5,6 +5,7 @@
     :prevPage="{ title: '理论研究' }"
     :dropDownNames="[]"
     :pageSize="8"
+    rowType="4"
     :load="loadData"
     :loadDetail="loadDetail"
   />