|
@@ -1,6 +1,47 @@
|
|
|
|
|
+
|
|
|
|
|
+<template>
|
|
|
|
|
+ <CommonRoot>
|
|
|
|
|
+ <FlexCol :padding="30" innerClass="bg-base">
|
|
|
|
|
+ <FlexRow>
|
|
|
|
|
+ <SearchBar
|
|
|
|
|
+ v-model="searchText"
|
|
|
|
|
+ placeholder="搜索新闻"
|
|
|
|
|
+ @search="loadNews"
|
|
|
|
|
+ />
|
|
|
|
|
+ <FlexRow align="center">
|
|
|
|
|
+ <Text>选择日期:</Text>
|
|
|
|
|
+ <PickerField
|
|
|
|
|
+ v-model="filterDate"
|
|
|
|
|
+ placeholder="选择日期"
|
|
|
|
|
+ :columns="[filterDates]"
|
|
|
|
|
+ />
|
|
|
|
|
+ <Icon name="arrow-down" />
|
|
|
|
|
+ </FlexRow>
|
|
|
|
|
+ </FlexRow>
|
|
|
|
|
+ <Box2LineImageRightShadow
|
|
|
|
|
+ v-for="(item, i) in newsLoader.list.value"
|
|
|
|
|
+ :key="item.id"
|
|
|
|
|
+ :class="[
|
|
|
|
|
+ 'position-relative d-flex flex-grow-1',
|
|
|
|
|
+ ]"
|
|
|
|
|
+ class="w-100"
|
|
|
|
|
+ titleColor="title-text"
|
|
|
|
|
+ :image="item.thumbnail || item.image"
|
|
|
|
|
+ :title="item.title"
|
|
|
|
|
+ :desc="`来源:${item.from}`"
|
|
|
|
|
+ :badge="item.badge"
|
|
|
|
|
+ :wideImage="true"
|
|
|
|
|
+ @click="goDetails(item, item.id)"
|
|
|
|
|
+ />
|
|
|
|
|
+ <SimplePageListLoader :loader="newsLoader" />
|
|
|
|
|
+ </FlexCol>
|
|
|
|
|
+ </CommonRoot>
|
|
|
|
|
+</template>
|
|
|
|
|
+
|
|
|
<script setup lang="ts">
|
|
<script setup lang="ts">
|
|
|
import { onMounted, ref, watch } from 'vue';
|
|
import { onMounted, ref, watch } from 'vue';
|
|
|
-import { GetContentListItem, GetContentListParams } from '@/api/CommonContent';
|
|
|
|
|
|
|
+import { type GetContentListItem, GetContentListParams } from '@/api/CommonContent';
|
|
|
|
|
+import { type PickerItem } from '@/components/form/Picker.vue';
|
|
|
import { useSimplePageListLoader } from '@/common/composeabe/SimplePageListLoader';
|
|
import { useSimplePageListLoader } from '@/common/composeabe/SimplePageListLoader';
|
|
|
import NewsIndexContent from '@/api/news/NewsIndexContent';
|
|
import NewsIndexContent from '@/api/news/NewsIndexContent';
|
|
|
import SimplePageListLoader from '@/common/components/SimplePageListLoader.vue';
|
|
import SimplePageListLoader from '@/common/components/SimplePageListLoader.vue';
|
|
@@ -8,7 +49,6 @@ import CommonRoot from '@/components/dialog/CommonRoot';
|
|
|
import FlexCol from '@/components/layout/FlexCol.vue';
|
|
import FlexCol from '@/components/layout/FlexCol.vue';
|
|
|
import FlexRow from '@/components/layout/FlexRow.vue';
|
|
import FlexRow from '@/components/layout/FlexRow.vue';
|
|
|
import SearchBar from '@/components/form/SearchBar.vue';
|
|
import SearchBar from '@/components/form/SearchBar.vue';
|
|
|
-import { type PickerItem } from '@/components/form/Picker.vue';
|
|
|
|
|
import PickerField from '@/components/form/PickerField.vue';
|
|
import PickerField from '@/components/form/PickerField.vue';
|
|
|
import Box2LineImageRightShadow from '../parts/Box2LineImageRightShadow.vue';
|
|
import Box2LineImageRightShadow from '../parts/Box2LineImageRightShadow.vue';
|
|
|
import Icon from '@/components/basic/Icon.vue';
|
|
import Icon from '@/components/basic/Icon.vue';
|
|
@@ -50,43 +90,4 @@ watch(filterDate, () => {
|
|
|
onMounted(() => {
|
|
onMounted(() => {
|
|
|
loadNews();
|
|
loadNews();
|
|
|
});
|
|
});
|
|
|
-</script>
|
|
|
|
|
-
|
|
|
|
|
-<template>
|
|
|
|
|
- <CommonRoot>
|
|
|
|
|
- <FlexCol :padding="30" innerClass="bg-base">
|
|
|
|
|
- <FlexRow>
|
|
|
|
|
- <SearchBar
|
|
|
|
|
- v-model="searchText"
|
|
|
|
|
- placeholder="搜索新闻"
|
|
|
|
|
- @search="loadNews"
|
|
|
|
|
- />
|
|
|
|
|
- <FlexRow align="center">
|
|
|
|
|
- <Text>选择日期:</Text>
|
|
|
|
|
- <PickerField
|
|
|
|
|
- v-model="filterDate"
|
|
|
|
|
- placeholder="选择日期"
|
|
|
|
|
- :columns="[filterDates]"
|
|
|
|
|
- />
|
|
|
|
|
- <Icon name="arrow-down" />
|
|
|
|
|
- </FlexRow>
|
|
|
|
|
- </FlexRow>
|
|
|
|
|
- <Box2LineImageRightShadow
|
|
|
|
|
- v-for="(item, i) in newsLoader.list.value"
|
|
|
|
|
- :key="item.id"
|
|
|
|
|
- :class="[
|
|
|
|
|
- 'position-relative d-flex flex-grow-1',
|
|
|
|
|
- ]"
|
|
|
|
|
- class="w-100"
|
|
|
|
|
- titleColor="title-text"
|
|
|
|
|
- :image="item.thumbnail || item.image"
|
|
|
|
|
- :title="item.title"
|
|
|
|
|
- :desc="`来源:${item.from}`"
|
|
|
|
|
- :badge="item.badge"
|
|
|
|
|
- :wideImage="true"
|
|
|
|
|
- @click="goDetails(item, item.id)"
|
|
|
|
|
- />
|
|
|
|
|
- <SimplePageListLoader :loader="newsLoader" />
|
|
|
|
|
- </FlexCol>
|
|
|
|
|
- </CommonRoot>
|
|
|
|
|
-</template>
|
|
|
|
|
|
|
+</script>
|