update date

main
dkwang 2026-10-29 17:13:07 +08:00
parent 4fe21d5bd8
commit 10ef0298e6
2 changed files with 12 additions and 3 deletions

View File

@ -1,7 +1,7 @@
<template> <template>
<div class="module-eight"> <div class="module-eight">
<div class="module-body"> <div class="module-body">
<div class="time-range">(2026-09-28)</div> <div class="time-range">({{ currentDate }})</div>
<div class="liziqiu-wrapper"> <div class="liziqiu-wrapper">
<img class="liziqiu" src="/imgs/liziqiu.png" alt="liziqiu" /> <img class="liziqiu" src="/imgs/liziqiu.png" alt="liziqiu" />
</div> </div>
@ -50,6 +50,10 @@
<script setup> <script setup>
import { ref } from 'vue' import { ref } from 'vue'
const now = new Date()
const pad = (n) => String(n).padStart(2, '0')
const currentDate = `${now.getFullYear()}-${pad(now.getMonth() + 1)}-${pad(now.getDate())}`
const totalData = ref({ const totalData = ref({
label: '施工总数', label: '施工总数',
value: 51 value: 51

View File

@ -1,7 +1,7 @@
<template> <template>
<div class="module-seven"> <div class="module-seven">
<div class="module-body"> <div class="module-body">
<div class="time-range">(2026-09-28)</div> <div class="time-range">({{ currentDate }})</div>
<div class="txt"> <div class="txt">
<div class="txt-item txt-item-1"> <div class="txt-item txt-item-1">
<img src="/imgs/type1.png" alt=""> <img src="/imgs/type1.png" alt="">
@ -27,7 +27,7 @@
<span class="legend-icon"></span> <span class="legend-icon"></span>
<span class="legend-text">维修次数</span> <span class="legend-text">维修次数</span>
</div> </div>
<div class="year-text">2026 年</div> <div class="year-text">{{ currentYear }} 年</div>
</div> </div>
<div class="chart-container"> <div class="chart-container">
<v-chart class="bar-chart" :option="chartOption" autoresize /> <v-chart class="bar-chart" :option="chartOption" autoresize />
@ -41,6 +41,11 @@ import { computed } from 'vue'
import VChart from 'vue-echarts' import VChart from 'vue-echarts'
import * as echarts from 'echarts' import * as echarts from 'echarts'
const now = new Date()
const pad = (n) => String(n).padStart(2, '0')
const currentDate = `${now.getFullYear()}-${pad(now.getMonth() + 1)}-${pad(now.getDate())}`
const currentYear = now.getFullYear()
const months = ['1', '2', '3', '4', '5', '6', '7', '8', '9', '10', '11', '12'] const months = ['1', '2', '3', '4', '5', '6', '7', '8', '9', '10', '11', '12']
const maintenanceData = [145, 142, 138, 148, 143, 140, 146, 144, 139, 147, 141, 145] const maintenanceData = [145, 142, 138, 148, 143, 140, 146, 144, 139, 147, 141, 145]