|
@@ -1,7 +1,7 @@
|
|
<template>
|
|
<template>
|
|
<div class="page-container column-container">
|
|
<div class="page-container column-container">
|
|
- <el-row :gutter="24">
|
|
|
|
- <el-col :span="8">
|
|
|
|
|
|
+ <el-row :gutter="24" style="margin-left: 10px;">
|
|
|
|
+ <el-col :span="8" class="notifications-label">
|
|
<!-- <div class="dashboard-total-item">
|
|
<!-- <div class="dashboard-total-item">
|
|
<img :src="totalIcon2" />
|
|
<img :src="totalIcon2" />
|
|
<div class="dashboard-total-item-label">
|
|
<div class="dashboard-total-item-label">
|
|
@@ -13,6 +13,20 @@
|
|
</div>
|
|
</div>
|
|
<div class="number-label">{{ totalCompanies }} 人</div>
|
|
<div class="number-label">{{ totalCompanies }} 人</div>
|
|
</div> -->
|
|
</div> -->
|
|
|
|
+ <div class="notifications-header">公告</div>
|
|
|
|
+ <el-card v-for="item in notifications" style="width: 100%;margin-bottom: 5px;" shadow="always">
|
|
|
|
+ <template #default>
|
|
|
|
+ <div style="display: flex; flex-direction: row;">
|
|
|
|
+ <i class="fa fa-bell-o" aria-hidden="true"
|
|
|
|
+ style="display: inline-block; height: 25px; line-height: 25px;" />
|
|
|
|
+ <div style="margin-left: 5px;display: inline-block; height: 25px; line-height: 25px;">{{ item.title }}
|
|
|
|
+ </div>
|
|
|
|
+ </div>
|
|
|
|
+ </template>
|
|
|
|
+ </el-card>
|
|
|
|
+ <!-- <el-row v-for="item in notifications" style="padding: 5px 10px;">
|
|
|
|
+ {{ item.title }}
|
|
|
|
+ </el-row> -->
|
|
</el-col>
|
|
</el-col>
|
|
<el-col :span="8">
|
|
<el-col :span="8">
|
|
<!-- <div class="dashboard-total-item">
|
|
<!-- <div class="dashboard-total-item">
|
|
@@ -28,7 +42,7 @@
|
|
</div> -->
|
|
</div> -->
|
|
</el-col>
|
|
</el-col>
|
|
</el-row>
|
|
</el-row>
|
|
- <div class="statistic-container">
|
|
|
|
|
|
+ <!-- <div class="statistic-container">
|
|
<el-row :gutter="16">
|
|
<el-row :gutter="16">
|
|
<el-col :span="12">
|
|
<el-col :span="12">
|
|
<div class="item-statistic-container" id="information-statistic"></div>
|
|
<div class="item-statistic-container" id="information-statistic"></div>
|
|
@@ -37,16 +51,14 @@
|
|
<div class="item-statistic-container" id="appointment-statistic"></div>
|
|
<div class="item-statistic-container" id="appointment-statistic"></div>
|
|
</el-col>
|
|
</el-col>
|
|
</el-row>
|
|
</el-row>
|
|
- </div>
|
|
|
|
|
|
+ </div> -->
|
|
</div>
|
|
</div>
|
|
</template>
|
|
</template>
|
|
<script setup>
|
|
<script setup>
|
|
// import totalIcon2 from '@/assets/images/dashboard-total-icon-2.png'
|
|
// import totalIcon2 from '@/assets/images/dashboard-total-icon-2.png'
|
|
// import totalIcon3 from '@/assets/images/dashboard-total-icon-3.png'
|
|
// import totalIcon3 from '@/assets/images/dashboard-total-icon-3.png'
|
|
import { parseTime } from '@/utils/tools.js'
|
|
import { parseTime } from '@/utils/tools.js'
|
|
-
|
|
|
|
-import {
|
|
|
|
-} from '@/api/business/productionTask'
|
|
|
|
|
|
+import { listNotification } from '@/api/business/notification'
|
|
|
|
|
|
// import { index } from '@/api/business/production'
|
|
// import { index } from '@/api/business/production'
|
|
|
|
|
|
@@ -125,14 +137,22 @@ let identityMonthTotal = ref(0)
|
|
|
|
|
|
let currentMonth = ref('')
|
|
let currentMonth = ref('')
|
|
let statisticDom, statistic
|
|
let statisticDom, statistic
|
|
|
|
+const notifications = ref([])
|
|
|
|
|
|
onMounted(() => {
|
|
onMounted(() => {
|
|
currentMonth.value = parseTime(new Date(), '{y}-{m}')
|
|
currentMonth.value = parseTime(new Date(), '{y}-{m}')
|
|
//statisticDom = document.getElementById('information-statistic')
|
|
//statisticDom = document.getElementById('information-statistic')
|
|
//statistic = echarts.init(statisticDom)
|
|
//statistic = echarts.init(statisticDom)
|
|
//getCurrentMonthDayArr()
|
|
//getCurrentMonthDayArr()
|
|
|
|
+ getList()
|
|
})
|
|
})
|
|
|
|
|
|
|
|
+function getList() {
|
|
|
|
+ listNotification({}).then(res => {
|
|
|
|
+ notifications.value = res.rows
|
|
|
|
+ })
|
|
|
|
+}
|
|
|
|
+
|
|
const getCurrentMonthDayArr = (dateStr) => {
|
|
const getCurrentMonthDayArr = (dateStr) => {
|
|
// 获取当前日期
|
|
// 获取当前日期
|
|
var currentDate = dateStr ? new Date(dateStr) : new Date()
|
|
var currentDate = dateStr ? new Date(dateStr) : new Date()
|
|
@@ -168,6 +188,26 @@ const handleChangeMonth = (val) => {
|
|
</script>
|
|
</script>
|
|
|
|
|
|
<style scoped>
|
|
<style scoped>
|
|
|
|
+.notifications-header {
|
|
|
|
+ height: 30px;
|
|
|
|
+ margin: 10px 5px;
|
|
|
|
+ font-size: 20px;
|
|
|
|
+ padding: 0 5px;
|
|
|
|
+}
|
|
|
|
+
|
|
|
|
+:deep(.notifications-label .el-card__body) {
|
|
|
|
+ padding: 5px 10px !important;
|
|
|
|
+}
|
|
|
|
+
|
|
|
|
+.notifications-label .el-card {
|
|
|
|
+ border: 1px solid #fdf1aa;
|
|
|
|
+ border-radius: 2px;
|
|
|
|
+}
|
|
|
|
+
|
|
|
|
+.notifications-label .el-card.is-always-shadow {
|
|
|
|
+ box-shadow: 0 0 5px #fdf1aa;
|
|
|
|
+}
|
|
|
|
+
|
|
.dashboard-total-item {
|
|
.dashboard-total-item {
|
|
display: flex;
|
|
display: flex;
|
|
align-items: center;
|
|
align-items: center;
|