From 4e87920494fd491b6ec584bbd208879dda6d0d00 Mon Sep 17 00:00:00 2001
From: loulijun2021 <1694218219@qq.com>
Date: 星期六, 26 十一月 2022 15:31:14 +0800
Subject: [PATCH] 1.看板地图背景色变浅
---
src/views/kb/index.vue | 238 +++++++++++++++++++++++++++++++++--------------------------
1 files changed, 132 insertions(+), 106 deletions(-)
diff --git a/src/views/kb/index.vue b/src/views/kb/index.vue
index 84a0179..5f5cb22 100644
--- a/src/views/kb/index.vue
+++ b/src/views/kb/index.vue
@@ -4,7 +4,7 @@
<div class="kb_body">
<div class="kb_background" />
<div class="kb_background2" />
- <div class="kb_head" style="height: 90px">鑴夐摼澶ф暟鎹垎鏋愬钩鍙�</div>
+ <div class="kb_head" style="height: 90px">鏈潵宸ュ巶鍒嗘瀽骞冲彴</div>
<div class="kb_headerPic" />
<div class="kb_flex" style="height: 660px">
<div class="kb_flex_column">
@@ -21,17 +21,27 @@
<div class="kb_center_block">
<div style="display: flex;justify-content: center">
<div class="kb_center_block_children">
- <div>{{ value1 }} 浜垮害</div>
- <!-- <div class="box01" />-->
+ <div style="font-size: 18px;">129,768</div>
<div class="box02" />
- <div>褰撴棩鎬昏�楃數閲�</div>
+ <div>鍛ㄨ�楄兘</div>
</div>
<div class="kb_center_block_children">
- <div>{{ value2 }} 浜跨珛鏂�</div>
- <div class="box01" />
- <div>褰撴棩鎬昏�楁皵閲�</div>
- <!-- <div class="box02" />-->
+ <div style="font-size: 18px;">228,702</div>
+ <div class="box02" />
+ <div>鏈堣�楄兘</div>
</div>
+ <div class="kb_center_block_children">
+ <div style="font-size: 18px;">337,035</div>
+ <div class="box02" />
+ <div>瀛h�楄兘</div>
+ </div>
+
+ <!-- <div class="kb_center_block_children">-->
+ <!-- <div>{{ value2 }} 浜跨珛鏂�</div>-->
+ <!-- <div class="box01" />-->
+ <!-- <div>褰撴棩鎬昏�楁皵閲�</div>-->
+ <!-- <!– <div class="box02" />–>-->
+ <!-- </div>-->
</div>
</div>
</div>
@@ -40,7 +50,8 @@
<div id="bar3" style="width: 100%;height: 100%" />
</div>
<div class="kb_block">
- <div id="custom1" style="width: 100%;height: 100%" />
+ <!-- <div id="custom1" style="width: 100%;height: 100%" />-->
+ <div id="barline1" style="width: 100%;height: 100%" />
</div>
</div>
</div>
@@ -64,7 +75,7 @@
<script>
import * as echarts from 'echarts'
import '@/utils/world'
-import { bar1, bar2, bar3, bar4, line1, loadEcharts, pie1, pie2 } from '@/utils/myEcharts'
+import { bar1, bar2, bar3, bar4, barline1, line1, loadEcharts, pie1, pie2 } from '@/utils/myEcharts'
export default {
name: 'Index',
@@ -81,94 +92,100 @@
this.loadArea()
// 鍔犺浇鎵�鏈�
this.loadAll()
- // 鍔犺浇鍙充腑
- this.loadCustom1()
- setInterval(() => {
- this.loadCustom1()
- }, 5000)
+ // // 鍔犺浇鍙充腑
+ // this.loadCustom1()
+ // setInterval(() => {
+ // this.loadCustom1()
+ // }, 5000)
setInterval(() => {
this.value1 = Math.floor(Math.random() * 10000 + 5000)
this.value2 = Math.floor(Math.random() * 10000 + 5000)
- }, 3000)
+ }, 9000)
},
methods: {
loadAll() {
// 鍔犺浇澶撮儴楗煎浘
- let pie1data = [
+ const pie1data = [
{
- name: '瑁呭鍒堕��',
- value: 54
+ name: '閲囪喘閫炬湡',
+ value: 3
}, {
- name: '鐜颁唬鏉愭枡',
- value: 44
+ name: '杩涙枡妫�楠�',
+ value: 95
}, {
- name: '鏂板お鑳芥簮',
- value: 35
+ name: '褰撴棩褰撴垚鐜�',
+ value: 83
}, {
- name: '淇℃伅鎶�鏈�',
- value: 30
+ name: '璁惧OEE',
+ value: 91
}, {
- name: '鍟嗚锤鐗╂祦',
- value: 20
+ name: '閿�鍞彂璐�',
+ value: 100
}
]
loadEcharts('pie1', pie1(pie1data))
setInterval(() => {
- pie1data = [
- {
- name: '瑁呭鍒堕��',
- value: Math.floor(Math.random() * 10) + 60
- }, {
- name: '鐜颁唬鏉愭枡',
- value: Math.floor(Math.random() * 10) + 60
- }, {
- name: '鏂板お鑳芥簮',
- value: Math.floor(Math.random() * 20) + 40
- }, {
- name: '淇℃伅鎶�鏈�',
- value: Math.floor(Math.random() * 20) + 40
- }, {
- name: '鍟嗚锤鐗╂祦',
- value: Math.floor(Math.random() * 20) + 40
- }
- ]
+ // pie1data = [
+ // {
+ // name: '瑁呭鍒堕��',
+ // value: Math.floor(Math.random() * 10) + 60
+ // }, {
+ // name: '鐜颁唬鏉愭枡',
+ // value: Math.floor(Math.random() * 10) + 60
+ // }, {
+ // name: '鏂板お鑳芥簮',
+ // value: Math.floor(Math.random() * 20) + 40
+ // }, {
+ // name: '淇℃伅鎶�鏈�',
+ // value: Math.floor(Math.random() * 20) + 40
+ // }, {
+ // name: '鍟嗚锤鐗╂祦',
+ // value: Math.floor(Math.random() * 20) + 40
+ // }
+ // ]
loadEcharts('pie1', pie1(pie1data))
- }, 10000)
+ }, 20000)
- let bar1data1 = ['92', '90', '96', '98', '99']
+ let bar1data1 = ['92', '90', '96', '98', '99', '97']
let bar1data2 = ['70', '60', '50', '40', '30']
// 鍔犺浇宸︿笅
loadEcharts('bar1', bar1(bar1data1, bar1data2))
setInterval(() => {
// bar1data1 = [1, 2, 3, 4, 5]
// bar1data2 = [1, 2, 3, 4, 5]
- bar1data1 = [Math.floor(Math.random() * 8 + 92), Math.floor(Math.random() * 8 + 92), Math.floor(Math.random() * 8 + 92), Math.floor(Math.random() * 8 + 92), Math.floor(Math.random() * 8 + 92)]
+ bar1data1 = [Math.floor(Math.random() * 8 + 92), Math.floor(Math.random() * 8 + 92), Math.floor(Math.random() * 8 + 92), Math.floor(Math.random() * 8 + 92), Math.floor(Math.random() * 8 + 92), Math.floor(Math.random() * 8 + 92)]
bar1data2 = [Math.floor(Math.random() * 15 + 70), Math.floor(Math.random() * 15 + 70), Math.floor(Math.random() * 15 + 70), Math.floor(Math.random() * 15 + 70), Math.floor(Math.random() * 15 + 70)]
loadEcharts('bar1', bar1(bar1data1, bar1data2))
- }, 9000)
+ }, 15000)
+
// 鍔犺浇宸︿腑
- let dataY = ['200', '400', '500', '300', '400', '440', '330', '380', '400', '460', '390', '270']
- loadEcharts('line1', line1(dataY))
+ // let dataY = ['200', '400', '500', '300', '400', '440', '330', '380', '400', '460', '390', '270']
+ const dataY = [8101, 6382, 7541, 7279, 5288, 7562, 7163, 7541, 4288]
+ const dataY2 = [5000 + Math.floor(Math.random() * 2000), 5000 + Math.floor(Math.random() * 2000), 5000 + Math.floor(Math.random() * 2000), 5000 + Math.floor(Math.random() * 2000), 5000 + Math.floor(Math.random() * 2000), 5000 + Math.floor(Math.random() * 2000), 5000 + Math.floor(Math.random() * 2000), 5000 + Math.floor(Math.random() * 2000), 5000 + Math.floor(Math.random() * 2000)]
+ const dataY3 = [5000 + Math.floor(Math.random() * 2000), 5000 + Math.floor(Math.random() * 2000), 5000 + Math.floor(Math.random() * 2000), 5000 + Math.floor(Math.random() * 2000), 5000 + Math.floor(Math.random() * 2000), 5000 + Math.floor(Math.random() * 2000), 5000 + Math.floor(Math.random() * 2000), 5000 + Math.floor(Math.random() * 2000), 5000 + Math.floor(Math.random() * 2000)]
+ const dataY4 = [3000 + Math.floor(Math.random() * 2000), 3000 + Math.floor(Math.random() * 2000), 3000 + Math.floor(Math.random() * 2000), 3000 + Math.floor(Math.random() * 2000), 3000 + Math.floor(Math.random() * 2000), 3000 + Math.floor(Math.random() * 2000), 3000 + Math.floor(Math.random() * 2000), 3000 + Math.floor(Math.random() * 2000), 3000 + Math.floor(Math.random() * 2000)]
+ const dataY5 = [3000 + Math.floor(Math.random() * 2000), 3000 + Math.floor(Math.random() * 2000), 3000 + Math.floor(Math.random() * 2000), 3000 + Math.floor(Math.random() * 2000), 3000 + Math.floor(Math.random() * 2000), 3000 + Math.floor(Math.random() * 2000), 3000 + Math.floor(Math.random() * 2000), 3000 + Math.floor(Math.random() * 2000), 3000 + Math.floor(Math.random() * 2000)]
+ loadEcharts('line1', line1(dataY, dataY2, dataY3, dataY4, dataY5))
setInterval(() => {
- dataY = [
- Math.floor(Math.random() * 100 + 200),
- Math.floor(Math.random() * 100 + 400),
- Math.floor(Math.random() * 100 + 300),
- Math.floor(Math.random() * 100 + 400),
- Math.floor(Math.random() * 100 + 300),
- Math.floor(Math.random() * 100 + 300),
- Math.floor(Math.random() * 100 + 200),
- Math.floor(Math.random() * 100 + 400),
- Math.floor(Math.random() * 100 + 400),
- Math.floor(Math.random() * 100 + 300),
- Math.floor(Math.random() * 100 + 200),
- Math.floor(Math.random() * 100 + 400)
- ]
- loadEcharts('line1', line1(dataY))
- }, 8000)
+ // dataY = [
+ // Math.floor(Math.random() * 100 + 200),
+ // Math.floor(Math.random() * 100 + 400),
+ // Math.floor(Math.random() * 100 + 300),
+ // Math.floor(Math.random() * 100 + 400),
+ // Math.floor(Math.random() * 100 + 300),
+ // Math.floor(Math.random() * 100 + 300),
+ // Math.floor(Math.random() * 100 + 200),
+ // Math.floor(Math.random() * 100 + 400),
+ // Math.floor(Math.random() * 100 + 400),
+ // Math.floor(Math.random() * 100 + 300),
+ // Math.floor(Math.random() * 100 + 200),
+ // Math.floor(Math.random() * 100 + 400)
+ // ]
+ loadEcharts('line1', line1(dataY, dataY2, dataY3, dataY4, dataY5))
+ }, 18000)
// 鍔犺浇鍙充笅
let scaleData1 = [
@@ -210,7 +227,7 @@
'name': '璁惧',
'value': 30
}, {
- 'name': '鍏跺畠',
+ 'name': '浜哄憳',
'value': 20
}
@@ -278,13 +295,13 @@
'name': '璁惧',
'value': b4
}, {
- 'name': '鍏跺畠',
+ 'name': '浜哄憳',
'value': b5
}
]
loadEcharts('pie2', pie2('鍝佽川宸紓姣斿垪', scaleData1))
loadEcharts('pie3', pie2('寮傚父棰勮姣斿垪', scaleData2))
- }, 7000)
+ }, 17000)
let list = [500, 400, 300, 200, 100]
// 鍔犺浇宸︿笂
@@ -292,20 +309,25 @@
setInterval(() => {
list = [Math.floor(Math.random() * 100) + 500, Math.floor(Math.random() * 100) + 400, Math.floor(Math.random() * 100) + 300, Math.floor(Math.random() * 100) + 200, Math.floor(Math.random() * 100) + 100]
loadEcharts('bar2', bar2(list))
- }, 6000)
+ }, 26000)
// 鍔犺浇鍙充笂
loadEcharts('bar3', bar3())
setInterval(() => {
loadEcharts('bar3', bar3())
- }, 5500)
+ }, 22000)
// 鍔犺浇涓笅
loadEcharts('bar4', bar4())
setInterval(() => {
loadEcharts('bar4', bar4())
- }, 6500)
+ }, 16500)
+
+ loadEcharts('barline1', barline1())
+ setInterval(() => {
+ loadEcharts('barline1', barline1())
+ }, 17500)
},
- // 鍔犺浇鍙充腑
+ // 鍔犺浇鍙充腑锛堝純鐢級
loadCustom1() {
const list = [
{
@@ -595,8 +617,8 @@
textStyle: {
// color: '#fff',
color: '#00ffff',
- fontSize: '18',
- fontWeight: 'lighter'
+ fontSize: '20',
+ fontWeight: 'bolder'
}
},
grid: {
@@ -632,34 +654,36 @@
return res
}
},
- xAxis: [{
- type: 'category',
- boundaryGap: true,
- axisLabel: {
- interval: 0,
- formatter: '{value}',
- fontSize: 14,
- margin: 20,
- textStyle: {
- color: this.colorX
- }
- },
- axisLine: {
- lineStyle: {
- color: '#032c58'
- }
- },
- splitLine: {
- show: false,
- lineStyle: {
- color: '#032c58'
- }
- },
- axisTick: {
- show: false
- },
- data: xList
- }],
+ xAxis: [
+ {
+ type: 'category',
+ boundaryGap: true,
+ axisLabel: {
+ interval: 0,
+ formatter: '{value}',
+ fontSize: 14,
+ margin: 20,
+ textStyle: {
+ color: this.colorX
+ }
+ },
+ axisLine: {
+ lineStyle: {
+ color: '#032c58'
+ }
+ },
+ splitLine: {
+ show: false,
+ lineStyle: {
+ color: '#032c58'
+ }
+ },
+ axisTick: {
+ show: false
+ },
+ data: xList
+ }
+ ],
yAxis: [
{
boundaryGap: false,
@@ -671,7 +695,7 @@
color: this.colorY
}
},
- name: '浜匡紙鍗曪級',
+ name: '涓囷紙鍗曪級',
nameTextStyle: {
color: this.colorY,
fontSize: 14,
@@ -949,6 +973,8 @@
margin: auto;
z-index: 2;
color: #09d8f2;
+ letter-spacing: 2px;
+ font-weight: bolder;
}
.kb_headerPic {
@@ -990,7 +1016,7 @@
.kb_center_block_children {
height: 120px;
//border: 1px solid $kbBorderColor;
- width: 360px;
+ width: 240px;
display: flex;
z-index: 2;
justify-content: space-around;
--
Gitblit v1.9.3