|
@@ -1,13 +1,290 @@
|
|
|
<template>
|
|
|
- <el-scrollbar>
|
|
|
- 123
|
|
|
- </el-scrollbar>
|
|
|
- </template>
|
|
|
-
|
|
|
- <script setup>
|
|
|
-
|
|
|
- </script>
|
|
|
-
|
|
|
- <style scoped>
|
|
|
- </style>
|
|
|
-
|
|
|
+ <el-scrollbar class="analysis">
|
|
|
+ <div class="head">
|
|
|
+ <div class="title">分类舆情</div>
|
|
|
+ <div class="searchRow">
|
|
|
+ <div class="searchCol searchTitle">分类:</div>
|
|
|
+ <div
|
|
|
+ :class="{
|
|
|
+ searchCol: true,
|
|
|
+ searchActive: searchActive.classification === optionindex,
|
|
|
+ }"
|
|
|
+ v-for="(optionitem, optionindex) in classification"
|
|
|
+ :key="optionindex + 'option'"
|
|
|
+ v-text="optionitem.name"
|
|
|
+ @click="() => clickSelect('classification', optionindex)"
|
|
|
+ ></div>
|
|
|
+ </div>
|
|
|
+ <div class="searchRow">
|
|
|
+ <div class="searchCol searchTitle">时间:</div>
|
|
|
+ <div
|
|
|
+ :class="{
|
|
|
+ searchCol: true,
|
|
|
+ searchActive: searchActive.time === optionindex,
|
|
|
+ }"
|
|
|
+ v-for="(optionitem, optionindex) in time"
|
|
|
+ :key="optionindex + 'option'"
|
|
|
+ v-text="optionitem.name"
|
|
|
+ @click="() => clickSelect('time', optionindex)"
|
|
|
+ ></div>
|
|
|
+ <div
|
|
|
+ :class="{
|
|
|
+ searchCol: true,
|
|
|
+ searchActive: searchActive[1] === -1,
|
|
|
+ }"
|
|
|
+ @click="() => clickSelect('time', -1)"
|
|
|
+ >
|
|
|
+ 自定义
|
|
|
+ </div>
|
|
|
+ <div class="searchCol">
|
|
|
+ <el-date-picker
|
|
|
+ v-model="date"
|
|
|
+ :disabled="searchActive.time !== -1"
|
|
|
+ type="daterange"
|
|
|
+ range-separator="-"
|
|
|
+ start-placeholder="开始时间"
|
|
|
+ end-placeholder="结束时间"
|
|
|
+ />
|
|
|
+ </div>
|
|
|
+ </div>
|
|
|
+ <div class="searchRow">
|
|
|
+ <div class="searchCol searchTitle">搜索:</div>
|
|
|
+ <div class="searchCol">
|
|
|
+ <el-input
|
|
|
+ v-model="searchText"
|
|
|
+ placeholder="搜索文章"
|
|
|
+ :suffix-icon="Search"
|
|
|
+ />
|
|
|
+ </div>
|
|
|
+ </div>
|
|
|
+ </div>
|
|
|
+ <div class="body">
|
|
|
+ <div class="mainTitle">
|
|
|
+ <div class="mainTitleTool">
|
|
|
+ <el-checkbox v-model="removal" label="去重" @change="changeBox" />
|
|
|
+ <el-select
|
|
|
+ v-model="selectValue"
|
|
|
+ class="m-2"
|
|
|
+ placeholder="Select"
|
|
|
+ @change="changeSelect"
|
|
|
+ >
|
|
|
+ <el-option
|
|
|
+ v-for="item in selectlist"
|
|
|
+ :key="item.value"
|
|
|
+ :label="item.label"
|
|
|
+ :value="item.value"
|
|
|
+ />
|
|
|
+ </el-select>
|
|
|
+ </div>
|
|
|
+ 文章列表
|
|
|
+ </div>
|
|
|
+ <br />
|
|
|
+ <div class="lists">
|
|
|
+ <div class="list">
|
|
|
+ <div class="listHead">
|
|
|
+ #唐嫣何广智说脱口秀# 《我们的客栈》唐嫣何广智说脱口...
|
|
|
+ </div>
|
|
|
+ <div class="listSubtitle">
|
|
|
+ #唐嫣何广智说脱口秀# 《我们的客栈》唐嫣何广智说脱口秀好期待!
|
|
|
+ </div>
|
|
|
+ <el-row>
|
|
|
+ <el-col :span="12">
|
|
|
+ <el-icon><Clock /></el-icon> 2023-02-16 16:11:49
|
|
|
+ </el-col>
|
|
|
+ <el-col :span="12" style="text-align: right"> 2 </el-col>
|
|
|
+ </el-row>
|
|
|
+ </div>
|
|
|
+ </div>
|
|
|
+ </div>
|
|
|
+ </el-scrollbar>
|
|
|
+</template>
|
|
|
+
|
|
|
+<script setup>
|
|
|
+import { ref, reactive } from 'vue';
|
|
|
+import { Search } from '@element-plus/icons-vue';
|
|
|
+const searchActive = ref({
|
|
|
+ classification: 0,
|
|
|
+ time: 0,
|
|
|
+});
|
|
|
+const classification = ref([
|
|
|
+ {
|
|
|
+ type: 'option',
|
|
|
+ name: '全部',
|
|
|
+ id: 0,
|
|
|
+ },
|
|
|
+ {
|
|
|
+ type: 'option',
|
|
|
+ name: '综合',
|
|
|
+ id: 1,
|
|
|
+ },
|
|
|
+ {
|
|
|
+ type: 'option',
|
|
|
+ name: '国际',
|
|
|
+ id: 2,
|
|
|
+ },
|
|
|
+ {
|
|
|
+ type: 'option',
|
|
|
+ name: '时事',
|
|
|
+ id: 3,
|
|
|
+ },
|
|
|
+ {
|
|
|
+ type: 'option',
|
|
|
+ name: '教育',
|
|
|
+ id: 4,
|
|
|
+ },
|
|
|
+]);
|
|
|
+const time = ref([
|
|
|
+ {
|
|
|
+ type: 'option',
|
|
|
+ name: '全部',
|
|
|
+ id: 0,
|
|
|
+ },
|
|
|
+ {
|
|
|
+ type: 'option',
|
|
|
+ name: '24小时',
|
|
|
+ id: 1,
|
|
|
+ },
|
|
|
+ {
|
|
|
+ type: 'option',
|
|
|
+ name: '48小时',
|
|
|
+ id: 2,
|
|
|
+ },
|
|
|
+ {
|
|
|
+ type: 'option',
|
|
|
+ name: '近7天',
|
|
|
+ id: 3,
|
|
|
+ },
|
|
|
+ {
|
|
|
+ type: 'option',
|
|
|
+ name: '近30天',
|
|
|
+ id: 4,
|
|
|
+ },
|
|
|
+]);
|
|
|
+const searchText = ref('');
|
|
|
+const removal = ref(false);
|
|
|
+const selectlist = reactive([
|
|
|
+ {
|
|
|
+ label: '按发布时间降序',
|
|
|
+ value: 0,
|
|
|
+ },
|
|
|
+ {
|
|
|
+ label: '按发布时间升序',
|
|
|
+ value: 1,
|
|
|
+ },
|
|
|
+ {
|
|
|
+ label: '按发情感值升序',
|
|
|
+ value: 2,
|
|
|
+ },
|
|
|
+ {
|
|
|
+ label: '按发情感值降序',
|
|
|
+ value: 3,
|
|
|
+ },
|
|
|
+]);
|
|
|
+const selectValue = ref(0);
|
|
|
+const date = ref([]);
|
|
|
+
|
|
|
+const clickSelect = (select, index) => {
|
|
|
+ searchActive.value[select] = index;
|
|
|
+ console.log(select, index);
|
|
|
+};
|
|
|
+
|
|
|
+const changeSelect = () => {
|
|
|
+ console.log(selectValue.value);
|
|
|
+};
|
|
|
+const changeBox = () => {
|
|
|
+ console.log(removal.value);
|
|
|
+};
|
|
|
+</script>
|
|
|
+
|
|
|
+<style scoped>
|
|
|
+.analysis {
|
|
|
+ height: 100%;
|
|
|
+}
|
|
|
+.analysis .head,
|
|
|
+.analysis .body {
|
|
|
+ margin: 0 1em;
|
|
|
+}
|
|
|
+
|
|
|
+.analysis .body {
|
|
|
+ border: 1px solid #f3f3f3;
|
|
|
+ margin: 1em;
|
|
|
+}
|
|
|
+
|
|
|
+.title {
|
|
|
+ font-size: 18px;
|
|
|
+ font-weight: 600;
|
|
|
+ height: 49px;
|
|
|
+ line-height: 49px;
|
|
|
+ padding-left: 8px;
|
|
|
+ border-bottom: 1px solid #f5f5f5;
|
|
|
+}
|
|
|
+
|
|
|
+.searchRow {
|
|
|
+ margin: 0.5em 0;
|
|
|
+}
|
|
|
+
|
|
|
+.searchCol {
|
|
|
+ display: inline-block;
|
|
|
+ margin: 0 0.5em;
|
|
|
+ padding: 0 0.5em;
|
|
|
+ height: 35px;
|
|
|
+ line-height: 35px;
|
|
|
+ cursor: pointer;
|
|
|
+}
|
|
|
+.searchCol:hover {
|
|
|
+ color: rgb(64, 158, 255);
|
|
|
+}
|
|
|
+
|
|
|
+.searchActive {
|
|
|
+ font-weight: 600;
|
|
|
+ color: rgb(64, 158, 255);
|
|
|
+ border-radius: 5px;
|
|
|
+ background-color: rgba(64, 158, 255, 0.1);
|
|
|
+}
|
|
|
+
|
|
|
+.searchRow .searchTitle {
|
|
|
+ color: #b9c0d3;
|
|
|
+}
|
|
|
+
|
|
|
+.body .mainTitle {
|
|
|
+ padding: 0 20px;
|
|
|
+ position: relative;
|
|
|
+ line-height: 60px;
|
|
|
+ border-bottom: 1px solid #f5f5f5;
|
|
|
+}
|
|
|
+.body .mainTitleTool {
|
|
|
+ position: absolute;
|
|
|
+ right: 20px;
|
|
|
+ line-height: 60px;
|
|
|
+ top: 0;
|
|
|
+ text-align: right;
|
|
|
+}
|
|
|
+.body .el-checkbox {
|
|
|
+ margin-right: 15px;
|
|
|
+}
|
|
|
+
|
|
|
+.listHead,
|
|
|
+.listSubtitle {
|
|
|
+ overflow: hidden;
|
|
|
+ white-space: nowrap;
|
|
|
+ text-overflow: ellipsis;
|
|
|
+}
|
|
|
+
|
|
|
+.lists {
|
|
|
+ padding: 0.5em;
|
|
|
+}
|
|
|
+
|
|
|
+.list {
|
|
|
+ border-radius: 5px;
|
|
|
+ padding: 0.5em;
|
|
|
+ cursor: pointer;
|
|
|
+ line-height: 1.8em;
|
|
|
+ font-size: 16px;
|
|
|
+}
|
|
|
+.list:hover {
|
|
|
+ background-color: rgba(64, 158, 255, 0.1);
|
|
|
+}
|
|
|
+.listSubtitle {
|
|
|
+ color: #b9c0d3;
|
|
|
+}
|
|
|
+</style>
|