update 质量管理数据

This commit is contained in:
lb
2022-11-25 09:25:03 +08:00
parent 0b9dfa27ab
commit 6aa7afb555
4 changed files with 110 additions and 108 deletions

View File

@@ -5,6 +5,7 @@
<script>
import echarts from 'echarts'
import resize from '@/views/OperationalOverview/components/mixins/resize'
import { Random } from 'mockjs'
class ChartOption {
constructor() {
@@ -66,7 +67,7 @@ class ChartOption {
{
name: '成品率 ',
type: 'value',
min: 'dataMin',
min: '80',
splitNumber: 4,
nameGap: 16,
nameTextStyle: {
@@ -106,6 +107,7 @@ class ChartOption {
name: 'A1下片机',
type: 'line',
symbol: 'none',
smooth: true,
areaStyle: {
// color: 'rgba(50,145,152,0.5)'
color: {
@@ -134,26 +136,16 @@ class ChartOption {
this.mode === 'month'
? Array(30)
.fill(1)
.map(_ => {
let v = Math.floor(Math.random() * 100)
while (v < 80) {
v = Math.floor(Math.random() * 100)
}
return v
})
: [11, 199, 140, 63, 185, 5, 78].map(_ => {
let v = Math.floor(Math.random() * 100)
while (v < 80) {
v = Math.floor(Math.random() * 100)
}
return v
})
.map(_ => Random.integer(94, 99))
: Array(7)
.fill(1)
.map(_ => Random.integer(94, 99))
},
{
name: '磨边机',
type: 'line',
symbol: 'none',
smooth: true,
areaStyle: {
// color: 'rgba(50,145,152,0.5)'
color: {
@@ -182,20 +174,10 @@ class ChartOption {
this.mode === 'month'
? Array(30)
.fill(1)
.map(_ => {
let v = Math.floor(Math.random() * 100)
while (v < 80) {
v = Math.floor(Math.random() * 100)
}
return v
})
: [11, 199, 140, 63, 185, 5, 78].map(_ => {
let v = Math.floor(Math.random() * 100)
while (v < 80) {
v = Math.floor(Math.random() * 100)
}
return v
})
.map(_ => Random.integer(94, 99))
: Array(7)
.fill(1)
.map(_ => Random.integer(94, 99))
}
]
}
@@ -278,20 +260,10 @@ export default {
this.mode === 'month'
? Array(30)
.fill(1)
.map(_ => {
let v = Math.floor(Math.random() * 100)
while (v < 80) {
v = Math.floor(Math.random() * 100)
}
return v
})
: [11, 199, 140, 63, 185, 5, 78].map(_ => {
let v = Math.floor(Math.random() * 100)
while (v < 80) {
v = Math.floor(Math.random() * 100)
}
return v
})
.map(_ => Random.integer(94, 99))
: Array(7)
.fill(1)
.map(_ => Random.integer(94, 99))
})
if (this.chart) this.chart.setOption(this.configs)