|
|
|
|
<template>
|
|
|
|
|
<v-scale-screen width="1920" height="1080" :fullScreen="false">
|
|
|
|
|
<div class="app-container home" style="">
|
|
|
|
|
<div class="head">
|
|
|
|
|
<div class="head-content">
|
|
|
|
|
<div class="title">榄菊质量管理平台</div>
|
|
|
|
|
</div>
|
|
|
|
|
<div class="head-logo">
|
|
|
|
|
<img src="../../../assets/images/logo.png" alt="" />
|
|
|
|
|
</div>
|
|
|
|
|
<div class="back">
|
|
|
|
|
<el-button @click="back()" type="primary" icon="el-icon-s-home"></el-button>
|
|
|
|
|
</div>
|
|
|
|
|
</div>
|
|
|
|
|
<div class="content-top">
|
|
|
|
|
<div class="factory">
|
|
|
|
|
<div class="selectborder">
|
|
|
|
|
<select v-model="selectxt" class="select1" @change="selectline(selectxt)">
|
|
|
|
|
<option :key="index" :value="x.parentName" v-for="(x, index) in getLineList">
|
|
|
|
|
{{ x.deptName }}
|
|
|
|
|
</option>
|
|
|
|
|
<!-- <option :key="index" :value="x.seriesName" v-for="(x, index) in ceshib">{{ x.seriesName }}</option> -->
|
|
|
|
|
</select>
|
|
|
|
|
</div>
|
|
|
|
|
<div class="selectborder selectborder1">
|
|
|
|
|
<select v-model="selectxtclasses" class="select1" @change="selectline2(selectxtclasses)">
|
|
|
|
|
<option :key="index" :value="x.ymdType" v-for="(x, index) in dictDatatype">
|
|
|
|
|
{{ x.ymdTypeName }}
|
|
|
|
|
</option>
|
|
|
|
|
</select>
|
|
|
|
|
</div>
|
|
|
|
|
</div>
|
|
|
|
|
<div class="timebox">
|
|
|
|
|
<div class="time">
|
|
|
|
|
{{ gettimedata }}
|
|
|
|
|
</div>
|
|
|
|
|
</div>
|
|
|
|
|
</div>
|
|
|
|
|
<div class="content">
|
|
|
|
|
<div class="itemtop">
|
|
|
|
|
<div class="item-table item-table1">
|
|
|
|
|
<div class="titlebox" style="margin-bottom: 14px;">
|
|
|
|
|
<div class="titlename">检验统计</div>
|
|
|
|
|
</div>
|
|
|
|
|
<div class="equipmentinfobox">
|
|
|
|
|
<div class="box">
|
|
|
|
|
<div class="number">
|
|
|
|
|
<span class="number1">
|
|
|
|
|
{{ Statistics.todayPro }}
|
|
|
|
|
</span>
|
|
|
|
|
</div>
|
|
|
|
|
<div class="name2">
|
|
|
|
|
今日产量(PC)
|
|
|
|
|
</div>
|
|
|
|
|
</div>
|
|
|
|
|
<div class="box">
|
|
|
|
|
<div class="number">
|
|
|
|
|
<span class="number1" style="color: #66FFFF;">
|
|
|
|
|
{{ Statistics.todaySample }}
|
|
|
|
|
</span>
|
|
|
|
|
</div>
|
|
|
|
|
<div class="name2">
|
|
|
|
|
今日抽检数量(PC)
|
|
|
|
|
</div>
|
|
|
|
|
</div>
|
|
|
|
|
<div class="box">
|
|
|
|
|
<div class="number">
|
|
|
|
|
<span class="number1" style="color: #FF4D4F;">
|
|
|
|
|
{{ Statistics.todayNoOk }}
|
|
|
|
|
</span>
|
|
|
|
|
</div>
|
|
|
|
|
<div class="name2">
|
|
|
|
|
今日不良数(PC)
|
|
|
|
|
</div>
|
|
|
|
|
</div>
|
|
|
|
|
</div>
|
|
|
|
|
<div class="equipmentinfobox1">
|
|
|
|
|
<div class="box">
|
|
|
|
|
<div class="number">
|
|
|
|
|
<span class="number1">
|
|
|
|
|
{{ Statistics.monthPro }}
|
|
|
|
|
</span>
|
|
|
|
|
</div>
|
|
|
|
|
<div class="name2">
|
|
|
|
|
本月产量(PC)
|
|
|
|
|
</div>
|
|
|
|
|
</div>
|
|
|
|
|
<div class="box">
|
|
|
|
|
<div class="number">
|
|
|
|
|
<span class="number1" style="color: #FF4D4F;">
|
|
|
|
|
{{ Statistics.monthNoOk }}
|
|
|
|
|
</span>
|
|
|
|
|
</div>
|
|
|
|
|
<div class="name2">
|
|
|
|
|
本月不良数(PC)
|
|
|
|
|
</div>
|
|
|
|
|
</div>
|
|
|
|
|
</div>
|
|
|
|
|
<div class="bigechartbox">
|
|
|
|
|
|
|
|
|
|
<div class="echartbox" id="echart1"
|
|
|
|
|
style="margin: auto; margin-top: 10px;width: 128px; height: 128px">
|
|
|
|
|
</div>
|
|
|
|
|
<div class="echartbox" id="echart4"
|
|
|
|
|
style="margin: auto; margin-top: 10px;width: 128px; height: 128px">
|
|
|
|
|
</div>
|
|
|
|
|
<div class="title1">
|
|
|
|
|
今日合格率
|
|
|
|
|
</div>
|
|
|
|
|
<div class="title2">
|
|
|
|
|
本月合格率
|
|
|
|
|
</div>
|
|
|
|
|
</div>
|
|
|
|
|
|
|
|
|
|
</div>
|
|
|
|
|
<div class="item-table item-table1">
|
|
|
|
|
<div class="titlebox" style="margin-bottom: 14px;">
|
|
|
|
|
<div class="titlename">质量异常信息</div>
|
|
|
|
|
</div>
|
|
|
|
|
<vue-seamless-scroll :data="Qualitylist" class="wrapscroll" :class-option="classOption" style="height:400px">
|
|
|
|
|
<div class="table-tbody">
|
|
|
|
|
<div class="item" :class="[index % 2 == 1 ? 'active1' : 'active2']" style="height:48px"
|
|
|
|
|
:key="index" v-for="(n, index) in Qualitylist">
|
|
|
|
|
<div class="icon">
|
|
|
|
|
|
|
|
|
|
</div>
|
|
|
|
|
<div class="itemname1" style="max-width: 210px;">
|
|
|
|
|
{{ n.projectName }}
|
|
|
|
|
|
|
|
|
|
</div>
|
|
|
|
|
<div class="itemname2">
|
|
|
|
|
{{ n.checkManName }} {{ n.checkTime }}
|
|
|
|
|
</div>
|
|
|
|
|
</div>
|
|
|
|
|
</div>
|
|
|
|
|
</vue-seamless-scroll>
|
|
|
|
|
</div>
|
|
|
|
|
<div class="item-table item-table1">
|
|
|
|
|
<div class="titlebox" style="margin-bottom: 14px;">
|
|
|
|
|
<div class="titlename">不良类型占比</div>
|
|
|
|
|
</div>
|
|
|
|
|
<div id="echart2" style="margin: auto; width: 425px; height: 410.26px;top: -10px;"></div>
|
|
|
|
|
</div>
|
|
|
|
|
<div class="item-table item-table1">
|
|
|
|
|
<div class="titlebox" style="margin-bottom: 14px;">
|
|
|
|
|
<div class="titlename">产品不合格数量对比</div>
|
|
|
|
|
</div>
|
|
|
|
|
<div id="echart3" style="margin: auto; width: 395px; height: 400.26px"></div>
|
|
|
|
|
</div>
|
|
|
|
|
</div>
|
|
|
|
|
<div class="itembottom">
|
|
|
|
|
<div class="item-table item-table1">
|
|
|
|
|
<div class="titlebox" style="margin-bottom: 14px;">
|
|
|
|
|
<div class="titlename">产品异常趋势</div>
|
|
|
|
|
</div>
|
|
|
|
|
<div id="echart5" style="margin: auto; width: 900px; height:304.15px"></div>
|
|
|
|
|
</div>
|
|
|
|
|
<div class="item-table item-table1">
|
|
|
|
|
<div class="titlebox" style="margin-bottom: 14px;">
|
|
|
|
|
<div class="titlename">产品不同工序异常对比</div>
|
|
|
|
|
</div>
|
|
|
|
|
<div id="echart6" style="margin: auto; width: 900px; height:304.15px"></div>
|
|
|
|
|
</div>
|
|
|
|
|
</div>
|
|
|
|
|
</div>
|
|
|
|
|
<!-- <div class="item"></div> -->
|
|
|
|
|
<!-- <div class="item"></div> -->
|
|
|
|
|
</div>
|
|
|
|
|
</v-scale-screen>
|
|
|
|
|
</template>
|
|
|
|
|
|
|
|
|
|
<script>
|
|
|
|
|
import {
|
|
|
|
|
getBoardFactory,
|
|
|
|
|
getProduceStaticInfo,
|
|
|
|
|
getProduceNoOkList,
|
|
|
|
|
getCheckProjectsPie,
|
|
|
|
|
getProMonthNoOk,
|
|
|
|
|
getLineDayNoOk,
|
|
|
|
|
getMonthOfYearContrast,
|
|
|
|
|
getDictData,
|
|
|
|
|
} from "@/api/kanban/quality";
|
|
|
|
|
import {
|
|
|
|
|
getDeviceRefreshTime,
|
|
|
|
|
} from "@/api/kanban/equipment";
|
|
|
|
|
import * as echarts from "echarts";
|
|
|
|
|
import moment from "moment";
|
|
|
|
|
// import Echarts3D from "./echarts3d.vue";
|
|
|
|
|
// import Echarts3D2 from "./echarts3d2.vue";
|
|
|
|
|
export default {
|
|
|
|
|
name: "Index",
|
|
|
|
|
components: {
|
|
|
|
|
},
|
|
|
|
|
data() {
|
|
|
|
|
return {
|
|
|
|
|
classOption:{
|
|
|
|
|
direction: 1,
|
|
|
|
|
hoverstop:true, step: 0.5,
|
|
|
|
|
openNatch: true,
|
|
|
|
|
limitMoveNum:7
|
|
|
|
|
},
|
|
|
|
|
gettimedata: "",
|
|
|
|
|
selectxt: null,
|
|
|
|
|
selectxtclasses: null,
|
|
|
|
|
getLineList: [],
|
|
|
|
|
classesList: [],
|
|
|
|
|
number1: 0,
|
|
|
|
|
number2: 0,
|
|
|
|
|
number3: 0,
|
|
|
|
|
number4: 0,
|
|
|
|
|
nameList: [
|
|
|
|
|
"成型机一",
|
|
|
|
|
"成型机二",
|
|
|
|
|
"成型机三",
|
|
|
|
|
"成型机四",
|
|
|
|
|
"成型机五",
|
|
|
|
|
"成型机六",
|
|
|
|
|
"成型机五",
|
|
|
|
|
"成型机六",
|
|
|
|
|
],
|
|
|
|
|
valueList: [1639, 1422, 1306, 1131, 1040, 732, 1040, 732],
|
|
|
|
|
optionDatalist2: [],
|
|
|
|
|
optionDatalist3: [],
|
|
|
|
|
optionDatalist4: [],
|
|
|
|
|
colorlist: ["#005aff", "#f8b551"],
|
|
|
|
|
datetime: null,
|
|
|
|
|
time1: null,
|
|
|
|
|
repairlist: [],
|
|
|
|
|
equipmentlist: [],
|
|
|
|
|
equipmentrepairlist: [],
|
|
|
|
|
equipmentstabilizelist: [],
|
|
|
|
|
equipmentinfo: [],
|
|
|
|
|
Statistics: {},
|
|
|
|
|
Qualitylist: [],
|
|
|
|
|
seriesmyChart5: [],
|
|
|
|
|
dictDatatype: [],
|
|
|
|
|
RefreshTime: null,
|
|
|
|
|
};
|
|
|
|
|
},
|
|
|
|
|
created() { },
|
|
|
|
|
destroyed() {
|
|
|
|
|
clearInterval(this.time1);
|
|
|
|
|
this.time1 = null;
|
|
|
|
|
},
|
|
|
|
|
mounted() {
|
|
|
|
|
// this.datetime = moment().subtract(2, "day").format("yyyy-MM-DD");
|
|
|
|
|
//console.log('zhuanhuahou',this.dateRangeone)
|
|
|
|
|
// this.getdatalist(this.selectxt)
|
|
|
|
|
this.selectFactorylist();
|
|
|
|
|
this.gettime();
|
|
|
|
|
},
|
|
|
|
|
methods: {
|
|
|
|
|
back() {
|
|
|
|
|
this.$router.push({ path: "/index" });
|
|
|
|
|
},
|
|
|
|
|
gettime() {
|
|
|
|
|
this.gettimedata = moment().format("YYYY-MM-DD HH:mm:ss ");
|
|
|
|
|
setInterval(() => {
|
|
|
|
|
this.gettimedata = moment().format("YYYY-MM-DD HH:mm:ss ");
|
|
|
|
|
}, 1000);
|
|
|
|
|
},
|
|
|
|
|
selectFactorylist() {
|
|
|
|
|
const _this = this;
|
|
|
|
|
getBoardFactory({
|
|
|
|
|
factory: null,
|
|
|
|
|
}).then((response) => {
|
|
|
|
|
if (response.data) {
|
|
|
|
|
_this.getLineList = response.data;
|
|
|
|
|
_this.selectxt = _this.getLineList[0].parentName;
|
|
|
|
|
|
|
|
|
|
this.getDictData()
|
|
|
|
|
this.getDeviceRefreshTime()
|
|
|
|
|
}
|
|
|
|
|
});
|
|
|
|
|
},
|
|
|
|
|
getDeviceRefreshTime() {
|
|
|
|
|
const _this = this;
|
|
|
|
|
getDeviceRefreshTime().then((response) => {
|
|
|
|
|
if (response.data) {
|
|
|
|
|
// console.log(response.data)
|
|
|
|
|
this.RefreshTime = response.data
|
|
|
|
|
this.time1 = setInterval(() => {
|
|
|
|
|
_this.getdatalist(_this.selectxt)
|
|
|
|
|
_this.initChart1()
|
|
|
|
|
}, 1000 * 60 * this.RefreshTime);
|
|
|
|
|
}
|
|
|
|
|
});
|
|
|
|
|
},
|
|
|
|
|
getDictData() {
|
|
|
|
|
const _this = this;
|
|
|
|
|
getDictData(
|
|
|
|
|
{
|
|
|
|
|
dictType: 'static_dims',
|
|
|
|
|
}
|
|
|
|
|
).then((response) => {
|
|
|
|
|
if (response) {
|
|
|
|
|
// console.log(response)
|
|
|
|
|
this.dictDatatype = response
|
|
|
|
|
_this.selectxtclasses = _this.dictDatatype[0].ymdType;
|
|
|
|
|
this.getDeviceRefreshTime()
|
|
|
|
|
this.getdatalist()
|
|
|
|
|
this.initChart1()
|
|
|
|
|
}
|
|
|
|
|
});
|
|
|
|
|
},
|
|
|
|
|
getdatalist() {
|
|
|
|
|
const _this = this;
|
|
|
|
|
getProduceStaticInfo({
|
|
|
|
|
ymdType: _this.selectxtclasses,//moment().format(_this.selectxtclasses),
|
|
|
|
|
typeCode: 'produce',
|
|
|
|
|
factoryCode: 'ds_' + _this.selectxt,
|
|
|
|
|
}).then((response) => {
|
|
|
|
|
if (response) {
|
|
|
|
|
_this.Statistics = response
|
|
|
|
|
_this.equipmentinfo = response
|
|
|
|
|
this.initChart2()
|
|
|
|
|
}
|
|
|
|
|
});
|
|
|
|
|
getProduceNoOkList({
|
|
|
|
|
typeCode: 'produce',
|
|
|
|
|
ymdType: _this.selectxtclasses,
|
|
|
|
|
factoryCode: 'ds_' + _this.selectxt,
|
|
|
|
|
}).then((response) => {
|
|
|
|
|
if (response) {
|
|
|
|
|
_this.Qualitylist = response
|
|
|
|
|
}
|
|
|
|
|
});
|
|
|
|
|
getCheckProjectsPie({
|
|
|
|
|
typeCode: 'produce',
|
|
|
|
|
ymdType: _this.selectxtclasses,//moment().format(_this.selectxtclasses),
|
|
|
|
|
factoryCode: 'ds_' + _this.selectxt,
|
|
|
|
|
}).then((response) => {
|
|
|
|
|
if (response) {
|
|
|
|
|
_this.optionDatalist2 = []
|
|
|
|
|
response.forEach((item) => {
|
|
|
|
|
let a = {}
|
|
|
|
|
a.name = item.projectName
|
|
|
|
|
a.value = item.quality
|
|
|
|
|
_this.optionDatalist2.push(a)
|
|
|
|
|
});
|
|
|
|
|
this.initChart3()
|
|
|
|
|
}
|
|
|
|
|
});
|
|
|
|
|
|
|
|
|
|
},
|
|
|
|
|
initChart1() {
|
|
|
|
|
const _this = this
|
|
|
|
|
var myChart3 = echarts.init(document.querySelector("#echart3"));
|
|
|
|
|
var option3 = {
|
|
|
|
|
grid: {
|
|
|
|
|
left: "60",
|
|
|
|
|
right: "10%",
|
|
|
|
|
top: "5%",
|
|
|
|
|
bottom: "1%",
|
|
|
|
|
containLabel: true,
|
|
|
|
|
},
|
|
|
|
|
tooltip: {
|
|
|
|
|
trigger: "axis",
|
|
|
|
|
show: true,
|
|
|
|
|
axisPointer: {
|
|
|
|
|
type: "none",
|
|
|
|
|
},
|
|
|
|
|
formatter: function (e) {
|
|
|
|
|
return `${e[0].data.name}\n${e[0].marker}${e[0].data.value}`;
|
|
|
|
|
},
|
|
|
|
|
},
|
|
|
|
|
xAxis: {
|
|
|
|
|
name: "数量",
|
|
|
|
|
// max: total,
|
|
|
|
|
splitLine: {
|
|
|
|
|
show: false,
|
|
|
|
|
},
|
|
|
|
|
axisLine: {
|
|
|
|
|
show: true,
|
|
|
|
|
},
|
|
|
|
|
axisLabel: {
|
|
|
|
|
show: true,
|
|
|
|
|
},
|
|
|
|
|
axisTick: {
|
|
|
|
|
show: true,
|
|
|
|
|
},
|
|
|
|
|
},
|
|
|
|
|
yAxis: [
|
|
|
|
|
{
|
|
|
|
|
type: "category",
|
|
|
|
|
inverse: false,
|
|
|
|
|
data: ['1', '2', '3', '4'],
|
|
|
|
|
axisLine: {
|
|
|
|
|
show: true,
|
|
|
|
|
},
|
|
|
|
|
axisTick: {
|
|
|
|
|
show: false,
|
|
|
|
|
},
|
|
|
|
|
axisLabel: {
|
|
|
|
|
show: false,
|
|
|
|
|
},
|
|
|
|
|
},
|
|
|
|
|
],
|
|
|
|
|
|
|
|
|
|
series: [
|
|
|
|
|
{
|
|
|
|
|
type: "pictorialBar",
|
|
|
|
|
symbol: "rect",
|
|
|
|
|
// symbolRepeat: "fixed",
|
|
|
|
|
// symbolMargin: "2",
|
|
|
|
|
// symbolClip: true,
|
|
|
|
|
// symbolSize: [5, 20],
|
|
|
|
|
barWidth: 20,
|
|
|
|
|
data: [],
|
|
|
|
|
label: {
|
|
|
|
|
normal: {
|
|
|
|
|
formatter: "{b}",
|
|
|
|
|
textStyle: {
|
|
|
|
|
color: "#D0DEEE",
|
|
|
|
|
fontSize: 14,
|
|
|
|
|
},
|
|
|
|
|
position: "left",
|
|
|
|
|
distance: 10, //
|
|
|
|
|
show: true,
|
|
|
|
|
},
|
|
|
|
|
},
|
|
|
|
|
z: 10,
|
|
|
|
|
},
|
|
|
|
|
{
|
|
|
|
|
type: "bar",
|
|
|
|
|
itemStyle: {
|
|
|
|
|
color: "#141A27",
|
|
|
|
|
},
|
|
|
|
|
label: {
|
|
|
|
|
normal: {
|
|
|
|
|
formatter: "{b}",
|
|
|
|
|
textStyle: {
|
|
|
|
|
color: "#D0DEEE",
|
|
|
|
|
fontSize: 14,
|
|
|
|
|
},
|
|
|
|
|
position: "right",
|
|
|
|
|
distance: 10, //
|
|
|
|
|
show: true,
|
|
|
|
|
},
|
|
|
|
|
},
|
|
|
|
|
data: [], // value鍊<65>
|
|
|
|
|
tooltip: {
|
|
|
|
|
show: false,
|
|
|
|
|
},
|
|
|
|
|
barWidth: 30,
|
|
|
|
|
},
|
|
|
|
|
],
|
|
|
|
|
};
|
|
|
|
|
myChart3.setOption(option3);
|
|
|
|
|
// console.log(_this.selectxt)
|
|
|
|
|
getProMonthNoOk({
|
|
|
|
|
typeCode: 'produce',
|
|
|
|
|
factoryCode: 'ds_' + _this.selectxt,
|
|
|
|
|
}).then((response) => {
|
|
|
|
|
if (response) {
|
|
|
|
|
let numberlist = [];
|
|
|
|
|
let dataoption = [];
|
|
|
|
|
let totalArr = [];
|
|
|
|
|
_this.optionDatalist3 = [];
|
|
|
|
|
// console.log(response)
|
|
|
|
|
for (let index = 0; index < response.month.length; index++) {
|
|
|
|
|
let a = {};
|
|
|
|
|
response.month[index] = moment(response.month[index]).format('MM')
|
|
|
|
|
a.name = response.month[index] + '月'
|
|
|
|
|
a.value = response.monthData[index]
|
|
|
|
|
a.code = response.monthData[index]
|
|
|
|
|
dataoption.push(a);
|
|
|
|
|
numberlist.push(response.monthData[index]);
|
|
|
|
|
}
|
|
|
|
|
// dataoption.sort((a, b) => {
|
|
|
|
|
// return a.value - b.value;
|
|
|
|
|
// });
|
|
|
|
|
dataoption = dataoption.reverse()
|
|
|
|
|
let max = Math.max(...numberlist);
|
|
|
|
|
max = max + 100;
|
|
|
|
|
dataoption.forEach((item) => {
|
|
|
|
|
totalArr.push(max);
|
|
|
|
|
});
|
|
|
|
|
// console.log(dataoption, numberlist)
|
|
|
|
|
// response = [{ name: "1月", code: "100", value: '100', }]
|
|
|
|
|
// if (response.length > 0) {
|
|
|
|
|
option3 = {
|
|
|
|
|
yAxis: [
|
|
|
|
|
{
|
|
|
|
|
data: dataoption,
|
|
|
|
|
},
|
|
|
|
|
],
|
|
|
|
|
series: [
|
|
|
|
|
{
|
|
|
|
|
data: dataoption,
|
|
|
|
|
itemStyle: {
|
|
|
|
|
normal: {
|
|
|
|
|
color: function (params) {
|
|
|
|
|
var index_num = params.value;
|
|
|
|
|
|
|
|
|
|
for (var i = 0; i < dataoption.length; i++) {
|
|
|
|
|
//判断数据是否大于1
|
|
|
|
|
if (index_num > 1131) {
|
|
|
|
|
//var colorList = ['#ff7f50', '#87cefa', '#da70d6', '#32cd32', '#6495ed', '#ff69b4', '#ba55d3', '#cd5c5c', '#ffa500', '#40e0d0'];
|
|
|
|
|
//return colorList[params.dataIndex];
|
|
|
|
|
return new echarts.graphic.LinearGradient(
|
|
|
|
|
0,
|
|
|
|
|
0,
|
|
|
|
|
1,
|
|
|
|
|
0,
|
|
|
|
|
[
|
|
|
|
|
{ offset: 0, color: "#FFB742" },
|
|
|
|
|
{ offset: 1, color: "#FFB742" },
|
|
|
|
|
]
|
|
|
|
|
);
|
|
|
|
|
} else {
|
|
|
|
|
//var colorList = ['blue'];
|
|
|
|
|
//return colorList[params.dataIndex];
|
|
|
|
|
return new echarts.graphic.LinearGradient(
|
|
|
|
|
0,
|
|
|
|
|
0,
|
|
|
|
|
1,
|
|
|
|
|
0,
|
|
|
|
|
[
|
|
|
|
|
{ offset: 0, color: "#005954" },
|
|
|
|
|
{ offset: 1, color: "#66E1DF" },
|
|
|
|
|
]
|
|
|
|
|
);
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
},
|
|
|
|
|
},
|
|
|
|
|
},
|
|
|
|
|
},
|
|
|
|
|
{
|
|
|
|
|
data: totalArr,
|
|
|
|
|
},
|
|
|
|
|
],
|
|
|
|
|
};
|
|
|
|
|
myChart3.setOption(option3);
|
|
|
|
|
// }
|
|
|
|
|
}
|
|
|
|
|
});
|
|
|
|
|
var myChart5 = echarts.init(document.querySelector("#echart5"));
|
|
|
|
|
var fontColor = '#D0DEEE';
|
|
|
|
|
var option5 = {
|
|
|
|
|
grid: {
|
|
|
|
|
left: '2%',
|
|
|
|
|
right: '4%',
|
|
|
|
|
top: '15%',
|
|
|
|
|
bottom: '2%',
|
|
|
|
|
containLabel: true
|
|
|
|
|
},
|
|
|
|
|
tooltip: {
|
|
|
|
|
show: true,
|
|
|
|
|
trigger: 'item'
|
|
|
|
|
},
|
|
|
|
|
legend: {
|
|
|
|
|
show: true,
|
|
|
|
|
x: 'center',
|
|
|
|
|
y: '0',
|
|
|
|
|
icon: 'stack',
|
|
|
|
|
itemWidth: 10,
|
|
|
|
|
itemHeight: 10,
|
|
|
|
|
textStyle: {
|
|
|
|
|
color: '#D0DEEE'
|
|
|
|
|
},
|
|
|
|
|
// nameTextStyle:{
|
|
|
|
|
// color: '#D0DEEE'
|
|
|
|
|
// },
|
|
|
|
|
data: ['已采纳', '已发布', '浏览量']
|
|
|
|
|
},
|
|
|
|
|
xAxis: [
|
|
|
|
|
{
|
|
|
|
|
type: 'category',
|
|
|
|
|
boundaryGap: true,
|
|
|
|
|
axisLabel: {
|
|
|
|
|
color: fontColor
|
|
|
|
|
},
|
|
|
|
|
axisLine: {
|
|
|
|
|
show: true,
|
|
|
|
|
lineStyle: {
|
|
|
|
|
color: '#397cbc'
|
|
|
|
|
}
|
|
|
|
|
},
|
|
|
|
|
axisTick: {
|
|
|
|
|
show: false,
|
|
|
|
|
},
|
|
|
|
|
splitLine: {
|
|
|
|
|
show: true,
|
|
|
|
|
lineStyle: {
|
|
|
|
|
color: '#2B3241'
|
|
|
|
|
}
|
|
|
|
|
},
|
|
|
|
|
data: []
|
|
|
|
|
}
|
|
|
|
|
],
|
|
|
|
|
yAxis: [
|
|
|
|
|
{
|
|
|
|
|
type: 'value',
|
|
|
|
|
name: '',
|
|
|
|
|
nameTextStyle: {
|
|
|
|
|
color: '#D0DEEE'
|
|
|
|
|
},
|
|
|
|
|
min: 0,
|
|
|
|
|
max: 1000,
|
|
|
|
|
axisLabel: {
|
|
|
|
|
formatter: '{value}',
|
|
|
|
|
textStyle: {
|
|
|
|
|
color: '#D0DEEE'
|
|
|
|
|
}
|
|
|
|
|
},
|
|
|
|
|
axisLine: {
|
|
|
|
|
lineStyle: {
|
|
|
|
|
color: '#27b4c2'
|
|
|
|
|
}
|
|
|
|
|
},
|
|
|
|
|
axisTick: {
|
|
|
|
|
show: false,
|
|
|
|
|
},
|
|
|
|
|
splitLine: {
|
|
|
|
|
show: true,
|
|
|
|
|
lineStyle: {
|
|
|
|
|
color: '#2B3241'
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
},
|
|
|
|
|
],
|
|
|
|
|
series: []
|
|
|
|
|
};
|
|
|
|
|
myChart5.setOption(option5);
|
|
|
|
|
getLineDayNoOk({
|
|
|
|
|
typeCode: 'produce',
|
|
|
|
|
factoryCode: 'ds_' + _this.selectxt,
|
|
|
|
|
}).then((response) => {
|
|
|
|
|
if (response) {
|
|
|
|
|
let seriesmyChart5 = []
|
|
|
|
|
let legenddata = []
|
|
|
|
|
let dataoption = response.series;
|
|
|
|
|
let xAxisdata = response.dayStr
|
|
|
|
|
let yAxismax = []
|
|
|
|
|
let yAxismaxall = 0
|
|
|
|
|
dataoption.forEach((n) => {
|
|
|
|
|
if (n.data) {
|
|
|
|
|
// console.log(Math.max(...n.data), n.data)
|
|
|
|
|
yAxismax.push(Math.max(...n.data))
|
|
|
|
|
}
|
|
|
|
|
var item = {
|
|
|
|
|
name: n.machineName,
|
|
|
|
|
data: n.data,
|
|
|
|
|
emphasis: {
|
|
|
|
|
focus: 'series'
|
|
|
|
|
},
|
|
|
|
|
type: "bar",
|
|
|
|
|
stack: n.machineName,
|
|
|
|
|
}
|
|
|
|
|
legenddata.push(n.machineName)
|
|
|
|
|
seriesmyChart5.push(item);
|
|
|
|
|
});
|
|
|
|
|
yAxismaxall = Math.max(...yAxismax) + 5
|
|
|
|
|
option5 = {
|
|
|
|
|
xAxis: [
|
|
|
|
|
{
|
|
|
|
|
data: xAxisdata,
|
|
|
|
|
},
|
|
|
|
|
],
|
|
|
|
|
legend:{
|
|
|
|
|
data:legenddata
|
|
|
|
|
},
|
|
|
|
|
yAxis: [
|
|
|
|
|
{
|
|
|
|
|
max: yAxismaxall
|
|
|
|
|
}
|
|
|
|
|
],
|
|
|
|
|
series: seriesmyChart5
|
|
|
|
|
};
|
|
|
|
|
// console.log(seriesmyChart5,'111111111111111')
|
|
|
|
|
myChart5.setOption(option5);
|
|
|
|
|
}
|
|
|
|
|
});
|
|
|
|
|
var myChart6 = echarts.init(document.querySelector("#echart6"));
|
|
|
|
|
var option6 = {
|
|
|
|
|
|
|
|
|
|
grid: {
|
|
|
|
|
left: '2%',
|
|
|
|
|
right: '4%',
|
|
|
|
|
top: '15%',
|
|
|
|
|
bottom: '2%',
|
|
|
|
|
containLabel: true
|
|
|
|
|
},
|
|
|
|
|
tooltip: {
|
|
|
|
|
trigger: 'axis',
|
|
|
|
|
axisPointer: {
|
|
|
|
|
type: 'cross',
|
|
|
|
|
crossStyle: {
|
|
|
|
|
color: '#999'
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
},
|
|
|
|
|
legend: {
|
|
|
|
|
show: true,
|
|
|
|
|
x: 'center',
|
|
|
|
|
y: '0',
|
|
|
|
|
icon: 'stack',
|
|
|
|
|
itemWidth: 10,
|
|
|
|
|
itemHeight: 10,
|
|
|
|
|
textStyle: {
|
|
|
|
|
color: '#D0DEEE'
|
|
|
|
|
},
|
|
|
|
|
// nameTextStyle:{
|
|
|
|
|
// color: '#D0DEEE'
|
|
|
|
|
// },
|
|
|
|
|
data: ['已采纳', '已发布', '浏览量']
|
|
|
|
|
},
|
|
|
|
|
xAxis: [
|
|
|
|
|
{
|
|
|
|
|
type: 'category',
|
|
|
|
|
boundaryGap: true,
|
|
|
|
|
axisLabel: {
|
|
|
|
|
color: fontColor
|
|
|
|
|
},
|
|
|
|
|
axisLine: {
|
|
|
|
|
show: true,
|
|
|
|
|
lineStyle: {
|
|
|
|
|
color: '#397cbc'
|
|
|
|
|
}
|
|
|
|
|
},
|
|
|
|
|
axisTick: {
|
|
|
|
|
show: false,
|
|
|
|
|
},
|
|
|
|
|
splitLine: {
|
|
|
|
|
show: false,
|
|
|
|
|
lineStyle: {
|
|
|
|
|
color: '#2B3241'
|
|
|
|
|
}
|
|
|
|
|
},
|
|
|
|
|
data: []
|
|
|
|
|
}
|
|
|
|
|
],
|
|
|
|
|
yAxis: [
|
|
|
|
|
{
|
|
|
|
|
type: 'value',
|
|
|
|
|
name: '数量',
|
|
|
|
|
nameTextStyle: {
|
|
|
|
|
color: '#D0DEEE'
|
|
|
|
|
},
|
|
|
|
|
min: 0,
|
|
|
|
|
max: 1000,
|
|
|
|
|
axisLabel: {
|
|
|
|
|
formatter: '{value}',
|
|
|
|
|
textStyle: {
|
|
|
|
|
color: '#D0DEEE'
|
|
|
|
|
}
|
|
|
|
|
},
|
|
|
|
|
axisLine: {
|
|
|
|
|
lineStyle: {
|
|
|
|
|
color: '#27b4c2'
|
|
|
|
|
}
|
|
|
|
|
},
|
|
|
|
|
axisTick: {
|
|
|
|
|
show: false,
|
|
|
|
|
},
|
|
|
|
|
splitLine: {
|
|
|
|
|
show: true,
|
|
|
|
|
lineStyle: {
|
|
|
|
|
color: '#2B3241'
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
},
|
|
|
|
|
{
|
|
|
|
|
type: 'value',
|
|
|
|
|
name: '比例',
|
|
|
|
|
nameTextStyle: {
|
|
|
|
|
color: '#D0DEEE'
|
|
|
|
|
},
|
|
|
|
|
min: 0,
|
|
|
|
|
max: 100,
|
|
|
|
|
axisLabel: {
|
|
|
|
|
formatter: '{value} %',
|
|
|
|
|
textStyle: {
|
|
|
|
|
color: '#D0DEEE'
|
|
|
|
|
}
|
|
|
|
|
},
|
|
|
|
|
axisLine: {
|
|
|
|
|
lineStyle: {
|
|
|
|
|
color: '#27b4c2'
|
|
|
|
|
}
|
|
|
|
|
},
|
|
|
|
|
axisTick: {
|
|
|
|
|
show: false,
|
|
|
|
|
},
|
|
|
|
|
splitLine: {
|
|
|
|
|
show: true,
|
|
|
|
|
lineStyle: {
|
|
|
|
|
color: '#2B3241'
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
},
|
|
|
|
|
],
|
|
|
|
|
series: [
|
|
|
|
|
{
|
|
|
|
|
name: '不合格比例',
|
|
|
|
|
type: 'line',
|
|
|
|
|
stack: '总量',
|
|
|
|
|
symbol: 'circle',
|
|
|
|
|
symbolSize: 8,
|
|
|
|
|
yAxisIndex: 1,
|
|
|
|
|
itemStyle: {
|
|
|
|
|
normal: {
|
|
|
|
|
color: '#5260CE',
|
|
|
|
|
lineStyle: {
|
|
|
|
|
color: "#5260CE",
|
|
|
|
|
width: 1
|
|
|
|
|
},
|
|
|
|
|
|
|
|
|
|
}
|
|
|
|
|
},
|
|
|
|
|
data: []
|
|
|
|
|
},
|
|
|
|
|
{
|
|
|
|
|
name: '不合格比例',
|
|
|
|
|
type: 'line',
|
|
|
|
|
stack: '总量',
|
|
|
|
|
symbol: 'circle',
|
|
|
|
|
symbolSize: 8,
|
|
|
|
|
yAxisIndex: 1,
|
|
|
|
|
itemStyle: {
|
|
|
|
|
normal: {
|
|
|
|
|
color: '#88E4E3',
|
|
|
|
|
lineStyle: {
|
|
|
|
|
color: "#88E4E3",
|
|
|
|
|
width: 1
|
|
|
|
|
},
|
|
|
|
|
|
|
|
|
|
}
|
|
|
|
|
},
|
|
|
|
|
data: []
|
|
|
|
|
},
|
|
|
|
|
{
|
|
|
|
|
name: '不合格数量',
|
|
|
|
|
data: [],
|
|
|
|
|
type: 'bar',
|
|
|
|
|
showBackground: true,
|
|
|
|
|
backgroundStyle: {
|
|
|
|
|
color: 'rgba(180, 180, 180, 0.2)'
|
|
|
|
|
},
|
|
|
|
|
itemStyle: {
|
|
|
|
|
normal: {
|
|
|
|
|
barBorderRadius: 5,
|
|
|
|
|
color: new echarts.graphic.LinearGradient(
|
|
|
|
|
0, 0, 0, 1,
|
|
|
|
|
[
|
|
|
|
|
{ offset: 0, color: '#586AF2' },
|
|
|
|
|
{ offset: 1, color: '#1C293A' }
|
|
|
|
|
]
|
|
|
|
|
)
|
|
|
|
|
}
|
|
|
|
|
},
|
|
|
|
|
},
|
|
|
|
|
{
|
|
|
|
|
name: '不合格数量',
|
|
|
|
|
data: [],
|
|
|
|
|
type: 'bar',
|
|
|
|
|
showBackground: true,
|
|
|
|
|
backgroundStyle: {
|
|
|
|
|
color: 'rgba(180, 180, 180, 0.2)'
|
|
|
|
|
},
|
|
|
|
|
itemStyle: {
|
|
|
|
|
normal: {
|
|
|
|
|
barBorderRadius: 5,
|
|
|
|
|
color: new echarts.graphic.LinearGradient(
|
|
|
|
|
0, 0, 0, 1,
|
|
|
|
|
[
|
|
|
|
|
{ offset: 0, color: "#66E1DF" },
|
|
|
|
|
{ offset: 1, color: "#005954" },
|
|
|
|
|
]
|
|
|
|
|
)
|
|
|
|
|
}
|
|
|
|
|
},
|
|
|
|
|
}
|
|
|
|
|
]
|
|
|
|
|
|
|
|
|
|
};
|
|
|
|
|
myChart6.setOption(option6);
|
|
|
|
|
getMonthOfYearContrast({
|
|
|
|
|
typeCode: 'produce',
|
|
|
|
|
factoryCode: 'ds_' + _this.selectxt,
|
|
|
|
|
}).then((response) => {
|
|
|
|
|
if (response) {
|
|
|
|
|
let seriesdata1 = response[0].dataBarArrays
|
|
|
|
|
let seriesdata2 = response[0].dataLineArrays
|
|
|
|
|
let xAxisdata = response[0].dayStr
|
|
|
|
|
let seriesdata3 = response[1].dataBarArrays
|
|
|
|
|
let seriesdata4 = response[1].dataLineArrays
|
|
|
|
|
let max1 = Math.max(...seriesdata1) + 5
|
|
|
|
|
let max2 = Math.max(...seriesdata3) + 5
|
|
|
|
|
let max3 = Math.max(...seriesdata2) + 5
|
|
|
|
|
let max4 = Math.max(...seriesdata4) + 5
|
|
|
|
|
let yAxismax1 = 0
|
|
|
|
|
let yAxismax2 = 0
|
|
|
|
|
if (max1 > max2) {
|
|
|
|
|
yAxismax1 = max1
|
|
|
|
|
} else {
|
|
|
|
|
yAxismax1 = max2
|
|
|
|
|
}
|
|
|
|
|
if (max3 > max4) {
|
|
|
|
|
yAxismax2 = max3
|
|
|
|
|
} else {
|
|
|
|
|
yAxismax2 = max4
|
|
|
|
|
}
|
|
|
|
|
option6 = {
|
|
|
|
|
xAxis: [
|
|
|
|
|
{
|
|
|
|
|
data: xAxisdata,
|
|
|
|
|
},
|
|
|
|
|
],
|
|
|
|
|
yAxis: [
|
|
|
|
|
{
|
|
|
|
|
max: yAxismax1
|
|
|
|
|
},
|
|
|
|
|
{
|
|
|
|
|
max: yAxismax2
|
|
|
|
|
}
|
|
|
|
|
],
|
|
|
|
|
series: [
|
|
|
|
|
{
|
|
|
|
|
data: seriesdata2,
|
|
|
|
|
},
|
|
|
|
|
{
|
|
|
|
|
data: seriesdata4,
|
|
|
|
|
},
|
|
|
|
|
{
|
|
|
|
|
data: seriesdata1,
|
|
|
|
|
},
|
|
|
|
|
{
|
|
|
|
|
data: seriesdata3,
|
|
|
|
|
}
|
|
|
|
|
]
|
|
|
|
|
};
|
|
|
|
|
myChart6.setOption(option6);
|
|
|
|
|
}
|
|
|
|
|
});
|
|
|
|
|
},
|
|
|
|
|
initChart2() {
|
|
|
|
|
const _this = this
|
|
|
|
|
// "todayOkRate":今日合格率","monthOkRate":"当月合理率",
|
|
|
|
|
let intactRate = 0
|
|
|
|
|
let numberAngle = 360
|
|
|
|
|
let intactRate1 = 0
|
|
|
|
|
let numberAngle1 = 360
|
|
|
|
|
if (_this.equipmentinfo.todayOkRate) {
|
|
|
|
|
intactRate = parseFloat(_this.equipmentinfo.todayOkRate)
|
|
|
|
|
numberAngle = (100 - parseInt(_this.equipmentinfo.todayOkRate)) * 3.6
|
|
|
|
|
}
|
|
|
|
|
if (_this.equipmentinfo.monthOkRate) {
|
|
|
|
|
intactRate1 = parseFloat(_this.equipmentinfo.monthOkRate)
|
|
|
|
|
numberAngle1 = (100 - parseInt(_this.equipmentinfo.monthOkRate)) * 3.6
|
|
|
|
|
}
|
|
|
|
|
var myChart1 = echarts.init(document.querySelector("#echart1"));
|
|
|
|
|
var option1 = {
|
|
|
|
|
//提示框组件。开发实际中去掉了指针,提示框可以不用设置。
|
|
|
|
|
tooltip: {
|
|
|
|
|
formatter: "{a} <br/>{b} : {c}%",
|
|
|
|
|
},
|
|
|
|
|
grid: {
|
|
|
|
|
},
|
|
|
|
|
//下面属性才是仪表盘的核心!!反正我是这么认为的!!!
|
|
|
|
|
series: [
|
|
|
|
|
{
|
|
|
|
|
//类型
|
|
|
|
|
splitNumber: 4, //刻度数量
|
|
|
|
|
type: "gauge",
|
|
|
|
|
//半径
|
|
|
|
|
radius: 60,
|
|
|
|
|
//起始角度。圆心 正右手侧为0度,正上方为90度,正左手侧为180度。
|
|
|
|
|
startAngle: 360,
|
|
|
|
|
//结束角度。
|
|
|
|
|
endAngle: 0,
|
|
|
|
|
center: ["50%", "50%"],
|
|
|
|
|
//仪表盘轴线相关配置。
|
|
|
|
|
name: "内层盘",
|
|
|
|
|
type: "gauge",
|
|
|
|
|
axisLine: {
|
|
|
|
|
lineStyle: {
|
|
|
|
|
width: 10,
|
|
|
|
|
color: [
|
|
|
|
|
[
|
|
|
|
|
1,
|
|
|
|
|
new echarts.graphic.LinearGradient(0, 0, 1, 0, [
|
|
|
|
|
{
|
|
|
|
|
offset: 0,
|
|
|
|
|
color: "#334046",
|
|
|
|
|
},
|
|
|
|
|
{
|
|
|
|
|
offset: 1,
|
|
|
|
|
color: "#334046",
|
|
|
|
|
},
|
|
|
|
|
]),
|
|
|
|
|
],
|
|
|
|
|
],
|
|
|
|
|
},
|
|
|
|
|
},
|
|
|
|
|
axisTick: {
|
|
|
|
|
lineStyle: {
|
|
|
|
|
color: "#fff",
|
|
|
|
|
width: 1,
|
|
|
|
|
},
|
|
|
|
|
length: 6,
|
|
|
|
|
splitNumber: 1,
|
|
|
|
|
show: false,
|
|
|
|
|
},
|
|
|
|
|
splitLine: {
|
|
|
|
|
show: false,
|
|
|
|
|
},
|
|
|
|
|
axisLabel: {
|
|
|
|
|
show: false,
|
|
|
|
|
},
|
|
|
|
|
pointer: {
|
|
|
|
|
show: false,
|
|
|
|
|
},
|
|
|
|
|
data: [
|
|
|
|
|
{
|
|
|
|
|
show: false,
|
|
|
|
|
value: "0",
|
|
|
|
|
},
|
|
|
|
|
],
|
|
|
|
|
detail: {
|
|
|
|
|
show: 0,
|
|
|
|
|
},
|
|
|
|
|
},
|
|
|
|
|
{
|
|
|
|
|
//类型
|
|
|
|
|
splitNumber: 4, //刻度数量
|
|
|
|
|
type: "gauge",
|
|
|
|
|
//半径
|
|
|
|
|
radius: 60,
|
|
|
|
|
//起始角度。圆心 正右手侧为0度,正上方为90度,正左手侧为180度。
|
|
|
|
|
startAngle: 360,
|
|
|
|
|
//结束角度。
|
|
|
|
|
endAngle: numberAngle,
|
|
|
|
|
center: ["50%", "50%"],
|
|
|
|
|
//仪表盘轴线相关配置。
|
|
|
|
|
name: "内层盘",
|
|
|
|
|
type: "gauge",
|
|
|
|
|
axisLine: {
|
|
|
|
|
lineStyle: {
|
|
|
|
|
width: 10,
|
|
|
|
|
color: [
|
|
|
|
|
[
|
|
|
|
|
1,
|
|
|
|
|
new echarts.graphic.LinearGradient(0, 0, 1, 0, [
|
|
|
|
|
{
|
|
|
|
|
offset: 0,
|
|
|
|
|
color: "#4789E1",
|
|
|
|
|
},
|
|
|
|
|
{
|
|
|
|
|
offset: 1,
|
|
|
|
|
color: "#4789E1",
|
|
|
|
|
},
|
|
|
|
|
]),
|
|
|
|
|
],
|
|
|
|
|
],
|
|
|
|
|
},
|
|
|
|
|
},
|
|
|
|
|
axisTick: {
|
|
|
|
|
lineStyle: {
|
|
|
|
|
color: "#fff",
|
|
|
|
|
width: 1,
|
|
|
|
|
},
|
|
|
|
|
length: 6,
|
|
|
|
|
splitNumber: 1,
|
|
|
|
|
show: false,
|
|
|
|
|
},
|
|
|
|
|
splitLine: {
|
|
|
|
|
show: false,
|
|
|
|
|
},
|
|
|
|
|
axisLabel: {
|
|
|
|
|
show: false,
|
|
|
|
|
},
|
|
|
|
|
pointer: {
|
|
|
|
|
show: false,
|
|
|
|
|
},
|
|
|
|
|
data: [
|
|
|
|
|
{
|
|
|
|
|
show: false,
|
|
|
|
|
value: "0",
|
|
|
|
|
},
|
|
|
|
|
],
|
|
|
|
|
detail: {
|
|
|
|
|
show: 0,
|
|
|
|
|
},
|
|
|
|
|
},
|
|
|
|
|
{
|
|
|
|
|
//类型
|
|
|
|
|
splitNumber: 4, //刻度数量
|
|
|
|
|
type: "gauge",
|
|
|
|
|
//半径
|
|
|
|
|
radius: 40,
|
|
|
|
|
//起始角度。圆心 正右手侧为0度,正上方为90度,正左手侧为180度。
|
|
|
|
|
startAngle: 360,
|
|
|
|
|
//结束角度。
|
|
|
|
|
endAngle: 0,
|
|
|
|
|
center: ["50%", "50%"],
|
|
|
|
|
//仪表盘轴线相关配置。
|
|
|
|
|
name: "内层盘",
|
|
|
|
|
type: "gauge",
|
|
|
|
|
axisLine: {
|
|
|
|
|
lineStyle: {
|
|
|
|
|
width: 5,
|
|
|
|
|
color: [
|
|
|
|
|
[
|
|
|
|
|
1,
|
|
|
|
|
new echarts.graphic.LinearGradient(0, 0, 1, 0, [
|
|
|
|
|
{
|
|
|
|
|
offset: 0.1,
|
|
|
|
|
color: "#334046",
|
|
|
|
|
},
|
|
|
|
|
{
|
|
|
|
|
offset: 0.6,
|
|
|
|
|
color: "#334046",
|
|
|
|
|
},
|
|
|
|
|
{
|
|
|
|
|
offset: 1,
|
|
|
|
|
color: "#334046",
|
|
|
|
|
},
|
|
|
|
|
]),
|
|
|
|
|
],
|
|
|
|
|
],
|
|
|
|
|
},
|
|
|
|
|
},
|
|
|
|
|
axisTick: {
|
|
|
|
|
lineStyle: {
|
|
|
|
|
color: "#334046",
|
|
|
|
|
width: 1,
|
|
|
|
|
},
|
|
|
|
|
length: 4,
|
|
|
|
|
splitNumber: 1,
|
|
|
|
|
distance: 0,
|
|
|
|
|
show: true,
|
|
|
|
|
},
|
|
|
|
|
splitLine: {
|
|
|
|
|
show: false,
|
|
|
|
|
},
|
|
|
|
|
axisLabel: {
|
|
|
|
|
show: false,
|
|
|
|
|
},
|
|
|
|
|
pointer: {
|
|
|
|
|
show: false,
|
|
|
|
|
},
|
|
|
|
|
axisLabel: {
|
|
|
|
|
show: false,
|
|
|
|
|
},
|
|
|
|
|
detail: {
|
|
|
|
|
show: true,
|
|
|
|
|
valueAnimation: true,
|
|
|
|
|
formatter: "{value}%",
|
|
|
|
|
offsetCenter: [0, "10%"],
|
|
|
|
|
textStyle: {
|
|
|
|
|
color: "#fff",
|
|
|
|
|
fontSize: 25,
|
|
|
|
|
},
|
|
|
|
|
|
|
|
|
|
},
|
|
|
|
|
data: [
|
|
|
|
|
{
|
|
|
|
|
value: intactRate,
|
|
|
|
|
},
|
|
|
|
|
|
|
|
|
|
],
|
|
|
|
|
},
|
|
|
|
|
|
|
|
|
|
],
|
|
|
|
|
};
|
|
|
|
|
myChart1.setOption(option1);
|
|
|
|
|
var myChart4 = echarts.init(document.querySelector("#echart4"));
|
|
|
|
|
var option4 = {
|
|
|
|
|
//提示框组件。开发实际中去掉了指针,提示框可以不用设置。
|
|
|
|
|
tooltip: {
|
|
|
|
|
formatter: "{a} <br/>{b} : {c}%",
|
|
|
|
|
},
|
|
|
|
|
grid: {
|
|
|
|
|
},
|
|
|
|
|
//下面属性才是仪表盘的核心!!反正我是这么认为的!!!
|
|
|
|
|
series: [
|
|
|
|
|
{
|
|
|
|
|
//类型
|
|
|
|
|
splitNumber: 4, //刻度数量
|
|
|
|
|
type: "gauge",
|
|
|
|
|
//半径
|
|
|
|
|
radius: 60,
|
|
|
|
|
//起始角度。圆心 正右手侧为0度,正上方为90度,正左手侧为180度。
|
|
|
|
|
startAngle: 360,
|
|
|
|
|
//结束角度。
|
|
|
|
|
endAngle: 0,
|
|
|
|
|
center: ["50%", "50%"],
|
|
|
|
|
//仪表盘轴线相关配置。
|
|
|
|
|
name: "内层盘",
|
|
|
|
|
type: "gauge",
|
|
|
|
|
axisLine: {
|
|
|
|
|
lineStyle: {
|
|
|
|
|
width: 10,
|
|
|
|
|
color: [
|
|
|
|
|
[
|
|
|
|
|
1,
|
|
|
|
|
new echarts.graphic.LinearGradient(0, 0, 1, 0, [
|
|
|
|
|
{
|
|
|
|
|
offset: 0,
|
|
|
|
|
color: "#334046",
|
|
|
|
|
},
|
|
|
|
|
{
|
|
|
|
|
offset: 1,
|
|
|
|
|
color: "#334046",
|
|
|
|
|
},
|
|
|
|
|
]),
|
|
|
|
|
],
|
|
|
|
|
],
|
|
|
|
|
},
|
|
|
|
|
},
|
|
|
|
|
axisTick: {
|
|
|
|
|
lineStyle: {
|
|
|
|
|
color: "#fff",
|
|
|
|
|
width: 1,
|
|
|
|
|
},
|
|
|
|
|
length: 6,
|
|
|
|
|
splitNumber: 1,
|
|
|
|
|
show: false,
|
|
|
|
|
},
|
|
|
|
|
splitLine: {
|
|
|
|
|
show: false,
|
|
|
|
|
},
|
|
|
|
|
axisLabel: {
|
|
|
|
|
show: false,
|
|
|
|
|
},
|
|
|
|
|
pointer: {
|
|
|
|
|
show: false,
|
|
|
|
|
},
|
|
|
|
|
data: [
|
|
|
|
|
{
|
|
|
|
|
show: false,
|
|
|
|
|
value: "0",
|
|
|
|
|
},
|
|
|
|
|
],
|
|
|
|
|
detail: {
|
|
|
|
|
show: 0,
|
|
|
|
|
},
|
|
|
|
|
},
|
|
|
|
|
{
|
|
|
|
|
//类型
|
|
|
|
|
splitNumber: 4, //刻度数量
|
|
|
|
|
type: "gauge",
|
|
|
|
|
//半径
|
|
|
|
|
radius: 60,
|
|
|
|
|
//起始角度。圆心 正右手侧为0度,正上方为90度,正左手侧为180度。
|
|
|
|
|
startAngle: 360,
|
|
|
|
|
//结束角度。
|
|
|
|
|
endAngle: numberAngle1,
|
|
|
|
|
center: ["50%", "50%"],
|
|
|
|
|
//仪表盘轴线相关配置。
|
|
|
|
|
name: "内层盘",
|
|
|
|
|
type: "gauge",
|
|
|
|
|
axisLine: {
|
|
|
|
|
lineStyle: {
|
|
|
|
|
width: 10,
|
|
|
|
|
color: [
|
|
|
|
|
[
|
|
|
|
|
1,
|
|
|
|
|
new echarts.graphic.LinearGradient(0, 0, 1, 0, [
|
|
|
|
|
{
|
|
|
|
|
offset: 0,
|
|
|
|
|
color: "#89F7F6",
|
|
|
|
|
},
|
|
|
|
|
{
|
|
|
|
|
offset: 1,
|
|
|
|
|
color: "#89F7F6",
|
|
|
|
|
},
|
|
|
|
|
]),
|
|
|
|
|
],
|
|
|
|
|
],
|
|
|
|
|
},
|
|
|
|
|
},
|
|
|
|
|
axisTick: {
|
|
|
|
|
lineStyle: {
|
|
|
|
|
color: "#fff",
|
|
|
|
|
width: 1,
|
|
|
|
|
},
|
|
|
|
|
length: 6,
|
|
|
|
|
splitNumber: 1,
|
|
|
|
|
show: false,
|
|
|
|
|
},
|
|
|
|
|
splitLine: {
|
|
|
|
|
show: false,
|
|
|
|
|
},
|
|
|
|
|
axisLabel: {
|
|
|
|
|
show: false,
|
|
|
|
|
},
|
|
|
|
|
pointer: {
|
|
|
|
|
show: false,
|
|
|
|
|
},
|
|
|
|
|
data: [
|
|
|
|
|
{
|
|
|
|
|
show: false,
|
|
|
|
|
value: "0",
|
|
|
|
|
},
|
|
|
|
|
],
|
|
|
|
|
detail: {
|
|
|
|
|
show: 0,
|
|
|
|
|
},
|
|
|
|
|
},
|
|
|
|
|
{
|
|
|
|
|
//类型
|
|
|
|
|
splitNumber: 4, //刻度数量
|
|
|
|
|
type: "gauge",
|
|
|
|
|
//半径
|
|
|
|
|
radius: 40,
|
|
|
|
|
//起始角度。圆心 正右手侧为0度,正上方为90度,正左手侧为180度。
|
|
|
|
|
startAngle: 360,
|
|
|
|
|
//结束角度。
|
|
|
|
|
endAngle: 0,
|
|
|
|
|
center: ["50%", "50%"],
|
|
|
|
|
//仪表盘轴线相关配置。
|
|
|
|
|
name: "内层盘",
|
|
|
|
|
type: "gauge",
|
|
|
|
|
axisLine: {
|
|
|
|
|
lineStyle: {
|
|
|
|
|
width: 5,
|
|
|
|
|
color: [
|
|
|
|
|
[
|
|
|
|
|
1,
|
|
|
|
|
new echarts.graphic.LinearGradient(0, 0, 1, 0, [
|
|
|
|
|
{
|
|
|
|
|
offset: 0.1,
|
|
|
|
|
color: "#334046",
|
|
|
|
|
},
|
|
|
|
|
{
|
|
|
|
|
offset: 0.6,
|
|
|
|
|
color: "#334046",
|
|
|
|
|
},
|
|
|
|
|
{
|
|
|
|
|
offset: 1,
|
|
|
|
|
color: "#334046",
|
|
|
|
|
},
|
|
|
|
|
]),
|
|
|
|
|
],
|
|
|
|
|
],
|
|
|
|
|
},
|
|
|
|
|
},
|
|
|
|
|
axisTick: {
|
|
|
|
|
lineStyle: {
|
|
|
|
|
color: "#334046",
|
|
|
|
|
width: 1,
|
|
|
|
|
},
|
|
|
|
|
length: 4,
|
|
|
|
|
splitNumber: 1,
|
|
|
|
|
distance: 0,
|
|
|
|
|
show: true,
|
|
|
|
|
},
|
|
|
|
|
splitLine: {
|
|
|
|
|
show: false,
|
|
|
|
|
},
|
|
|
|
|
axisLabel: {
|
|
|
|
|
show: false,
|
|
|
|
|
},
|
|
|
|
|
pointer: {
|
|
|
|
|
show: false,
|
|
|
|
|
},
|
|
|
|
|
axisLabel: {
|
|
|
|
|
show: false,
|
|
|
|
|
},
|
|
|
|
|
detail: {
|
|
|
|
|
show: true,
|
|
|
|
|
valueAnimation: true,
|
|
|
|
|
formatter: "{value}%",
|
|
|
|
|
offsetCenter: [0, "10%"],
|
|
|
|
|
textStyle: {
|
|
|
|
|
color: "#fff",
|
|
|
|
|
fontSize: 25,
|
|
|
|
|
},
|
|
|
|
|
|
|
|
|
|
},
|
|
|
|
|
data: [
|
|
|
|
|
{
|
|
|
|
|
value: intactRate1,
|
|
|
|
|
},
|
|
|
|
|
|
|
|
|
|
],
|
|
|
|
|
},
|
|
|
|
|
|
|
|
|
|
],
|
|
|
|
|
};
|
|
|
|
|
myChart4.setOption(option4);
|
|
|
|
|
},
|
|
|
|
|
initChart3() {
|
|
|
|
|
const _this = this
|
|
|
|
|
var colorList = ['#2D6ACA', '#72C6B5', '#F0D766', '#80B5F4', '#FD866A', '#9E87FF', '#58D5FF'];
|
|
|
|
|
var data = _this.optionDatalist2
|
|
|
|
|
// var data = [{
|
|
|
|
|
// 'name': '热点网格',
|
|
|
|
|
// 'value': 5600
|
|
|
|
|
// }, {
|
|
|
|
|
// 'name': '大气污染',
|
|
|
|
|
// 'value': 3600
|
|
|
|
|
// }, {
|
|
|
|
|
// 'name': '水质超标',
|
|
|
|
|
// 'value': 1500
|
|
|
|
|
// }, {
|
|
|
|
|
// 'name': '在线超标',
|
|
|
|
|
// 'value': 2000
|
|
|
|
|
// }, {
|
|
|
|
|
// 'name': '未知',
|
|
|
|
|
// 'value': 899
|
|
|
|
|
// }, {
|
|
|
|
|
// 'name': '系统对接',
|
|
|
|
|
// 'value': 4000
|
|
|
|
|
// }, {
|
|
|
|
|
// 'name': '系统对接1',
|
|
|
|
|
// 'value': 4000
|
|
|
|
|
// }, {
|
|
|
|
|
// 'name': '系统对接2',
|
|
|
|
|
// 'value': 4000
|
|
|
|
|
// }, {
|
|
|
|
|
// 'name': '系统对接3',
|
|
|
|
|
// 'value': 4000
|
|
|
|
|
// }, {
|
|
|
|
|
// 'name': '系统对接4',
|
|
|
|
|
// 'value': 4000
|
|
|
|
|
// }]
|
|
|
|
|
var myChart2 = echarts.init(document.querySelector("#echart2"));
|
|
|
|
|
var option2 = {
|
|
|
|
|
//提示框组件。开发实际中去掉了指针,提示框可以不用设置。
|
|
|
|
|
tooltip: {
|
|
|
|
|
trigger: 'item'
|
|
|
|
|
},
|
|
|
|
|
grid: {
|
|
|
|
|
top: '60',
|
|
|
|
|
},
|
|
|
|
|
legend: {
|
|
|
|
|
bottom: '10',
|
|
|
|
|
// itemGap: 40,
|
|
|
|
|
icon: 'pin',
|
|
|
|
|
textStyle: {
|
|
|
|
|
rich: {
|
|
|
|
|
a: {
|
|
|
|
|
color: '#FFFFFF',
|
|
|
|
|
width: 30,
|
|
|
|
|
fontSize: 13,
|
|
|
|
|
},
|
|
|
|
|
b: {
|
|
|
|
|
color: '#FFFFFF',
|
|
|
|
|
fontSize: 13,
|
|
|
|
|
padding: [0, 30, 0, 40]
|
|
|
|
|
},
|
|
|
|
|
b0: {
|
|
|
|
|
color: '#73DDFF',
|
|
|
|
|
fontSize: 20,
|
|
|
|
|
padding: [0, 30, 0, 40]
|
|
|
|
|
},
|
|
|
|
|
}
|
|
|
|
|
},
|
|
|
|
|
formatter: function (name) {
|
|
|
|
|
let title = ''
|
|
|
|
|
var total = 0;
|
|
|
|
|
var target;
|
|
|
|
|
var index;
|
|
|
|
|
for (var i = 0, l = data.length; i < l; i++) {
|
|
|
|
|
if (data[i].name == name) {
|
|
|
|
|
target = data[i].value;
|
|
|
|
|
title = data[i].label
|
|
|
|
|
index = i < 6 ? i : 5
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
return `{a| ${name}}{b| ${target}}`
|
|
|
|
|
}
|
|
|
|
|
},
|
|
|
|
|
//下面属性才是仪表盘的核心!!反正我是这么认为的!!!
|
|
|
|
|
series: [
|
|
|
|
|
{
|
|
|
|
|
//类型
|
|
|
|
|
splitNumber: 4, //刻度数量
|
|
|
|
|
type: "gauge",
|
|
|
|
|
//半径
|
|
|
|
|
radius: 150,
|
|
|
|
|
//起始角度。圆心 正右手侧为0度,正上方为90度,正左手侧为180度。
|
|
|
|
|
startAngle: 360,
|
|
|
|
|
//结束角度。
|
|
|
|
|
endAngle: 0,
|
|
|
|
|
center: ["50%", "40%"],
|
|
|
|
|
//仪表盘轴线相关配置。
|
|
|
|
|
type: "gauge",
|
|
|
|
|
axisLine: {
|
|
|
|
|
lineStyle: {
|
|
|
|
|
width: 50,
|
|
|
|
|
color: [
|
|
|
|
|
[
|
|
|
|
|
1,
|
|
|
|
|
new echarts.graphic.LinearGradient(0, 0, 1, 0, [
|
|
|
|
|
{
|
|
|
|
|
offset: 0.1,
|
|
|
|
|
color: "#1C2738",
|
|
|
|
|
},
|
|
|
|
|
{
|
|
|
|
|
offset: 0.6,
|
|
|
|
|
color: "#1C2738",
|
|
|
|
|
},
|
|
|
|
|
{
|
|
|
|
|
offset: 1,
|
|
|
|
|
color: "#1C2738",
|
|
|
|
|
},
|
|
|
|
|
]),
|
|
|
|
|
],
|
|
|
|
|
],
|
|
|
|
|
},
|
|
|
|
|
},
|
|
|
|
|
axisTick: {
|
|
|
|
|
lineStyle: {
|
|
|
|
|
color: "#070E19",
|
|
|
|
|
width: 3,
|
|
|
|
|
},
|
|
|
|
|
length: 50,
|
|
|
|
|
splitNumber: 2,
|
|
|
|
|
distance: -50,
|
|
|
|
|
show: true,
|
|
|
|
|
},
|
|
|
|
|
splitLine: {
|
|
|
|
|
show: false,
|
|
|
|
|
},
|
|
|
|
|
axisLabel: {
|
|
|
|
|
show: false,
|
|
|
|
|
},
|
|
|
|
|
pointer: {
|
|
|
|
|
show: false,
|
|
|
|
|
},
|
|
|
|
|
axisLabel: {
|
|
|
|
|
show: false,
|
|
|
|
|
},
|
|
|
|
|
detail: {
|
|
|
|
|
show: false,
|
|
|
|
|
valueAnimation: true,
|
|
|
|
|
formatter: "{value}%",
|
|
|
|
|
offsetCenter: [0, "10%"],
|
|
|
|
|
textStyle: {
|
|
|
|
|
color: "#fff",
|
|
|
|
|
fontSize: 25,
|
|
|
|
|
},
|
|
|
|
|
|
|
|
|
|
},
|
|
|
|
|
data: [
|
|
|
|
|
{
|
|
|
|
|
value: 80,
|
|
|
|
|
show: false,
|
|
|
|
|
},
|
|
|
|
|
|
|
|
|
|
],
|
|
|
|
|
},
|
|
|
|
|
{
|
|
|
|
|
type: "pie",
|
|
|
|
|
radius: ["44%", "63%"],
|
|
|
|
|
center: ["50%", "40%"],
|
|
|
|
|
roseType: "radius",
|
|
|
|
|
// itemStyle: {
|
|
|
|
|
// normal: {
|
|
|
|
|
// color: function (params) {
|
|
|
|
|
// return colorList[params.dataIndex]
|
|
|
|
|
// }
|
|
|
|
|
// }
|
|
|
|
|
// },
|
|
|
|
|
label: {
|
|
|
|
|
show: false
|
|
|
|
|
},
|
|
|
|
|
emphasis: {
|
|
|
|
|
label: {
|
|
|
|
|
show: false
|
|
|
|
|
}
|
|
|
|
|
},
|
|
|
|
|
data: data,
|
|
|
|
|
},
|
|
|
|
|
{
|
|
|
|
|
//类型
|
|
|
|
|
splitNumber: 4, //刻度数量
|
|
|
|
|
type: "gauge",
|
|
|
|
|
//半径
|
|
|
|
|
radius: 140,
|
|
|
|
|
//起始角度。圆心 正右手侧为0度,正上方为90度,正左手侧为180度。
|
|
|
|
|
startAngle: 360,
|
|
|
|
|
//结束角度。
|
|
|
|
|
endAngle: 0,
|
|
|
|
|
center: ["50%", "40%"],
|
|
|
|
|
//仪表盘轴线相关配置。
|
|
|
|
|
type: "gauge",
|
|
|
|
|
axisLine: {
|
|
|
|
|
lineStyle: {
|
|
|
|
|
width: 1,
|
|
|
|
|
color: [
|
|
|
|
|
[
|
|
|
|
|
1,
|
|
|
|
|
new echarts.graphic.LinearGradient(0, 0, 1, 0, [
|
|
|
|
|
{
|
|
|
|
|
offset: 0.1,
|
|
|
|
|
color: "#619e9d",
|
|
|
|
|
},
|
|
|
|
|
{
|
|
|
|
|
offset: 0.6,
|
|
|
|
|
color: "#619e9d",
|
|
|
|
|
},
|
|
|
|
|
{
|
|
|
|
|
offset: 1,
|
|
|
|
|
color: "#619e9d",
|
|
|
|
|
},
|
|
|
|
|
]),
|
|
|
|
|
],
|
|
|
|
|
],
|
|
|
|
|
},
|
|
|
|
|
},
|
|
|
|
|
axisTick: {
|
|
|
|
|
lineStyle: {
|
|
|
|
|
color: "#070E19",
|
|
|
|
|
width: 3,
|
|
|
|
|
},
|
|
|
|
|
length: 50,
|
|
|
|
|
splitNumber: 2,
|
|
|
|
|
distance: -50,
|
|
|
|
|
show: false,
|
|
|
|
|
},
|
|
|
|
|
splitLine: {
|
|
|
|
|
show: false,
|
|
|
|
|
},
|
|
|
|
|
axisLabel: {
|
|
|
|
|
show: false,
|
|
|
|
|
},
|
|
|
|
|
pointer: {
|
|
|
|
|
show: false,
|
|
|
|
|
},
|
|
|
|
|
axisLabel: {
|
|
|
|
|
show: false,
|
|
|
|
|
},
|
|
|
|
|
detail: {
|
|
|
|
|
show: false,
|
|
|
|
|
valueAnimation: true,
|
|
|
|
|
formatter: "{value}%",
|
|
|
|
|
offsetCenter: [0, "10%"],
|
|
|
|
|
textStyle: {
|
|
|
|
|
color: "#fff",
|
|
|
|
|
fontSize: 25,
|
|
|
|
|
},
|
|
|
|
|
|
|
|
|
|
},
|
|
|
|
|
data: [
|
|
|
|
|
{
|
|
|
|
|
value: 80,
|
|
|
|
|
show: false,
|
|
|
|
|
},
|
|
|
|
|
|
|
|
|
|
],
|
|
|
|
|
},
|
|
|
|
|
{
|
|
|
|
|
//类型
|
|
|
|
|
splitNumber: 4, //刻度数量
|
|
|
|
|
type: "gauge",
|
|
|
|
|
//半径
|
|
|
|
|
radius: 80,
|
|
|
|
|
//起始角度。圆心 正右手侧为0度,正上方为90度,正左手侧为180度。
|
|
|
|
|
startAngle: 360,
|
|
|
|
|
//结束角度。
|
|
|
|
|
endAngle: 0,
|
|
|
|
|
center: ["50%", "40%"],
|
|
|
|
|
//仪表盘轴线相关配置。
|
|
|
|
|
type: "gauge",
|
|
|
|
|
axisLine: {
|
|
|
|
|
lineStyle: {
|
|
|
|
|
width: 1,
|
|
|
|
|
color: [
|
|
|
|
|
[
|
|
|
|
|
1,
|
|
|
|
|
new echarts.graphic.LinearGradient(0, 0, 1, 0, [
|
|
|
|
|
{
|
|
|
|
|
offset: 0.1,
|
|
|
|
|
color: "#619e9d",
|
|
|
|
|
},
|
|
|
|
|
{
|
|
|
|
|
offset: 0.6,
|
|
|
|
|
color: "#619e9d",
|
|
|
|
|
},
|
|
|
|
|
{
|
|
|
|
|
offset: 1,
|
|
|
|
|
color: "#619e9d",
|
|
|
|
|
},
|
|
|
|
|
]),
|
|
|
|
|
],
|
|
|
|
|
],
|
|
|
|
|
},
|
|
|
|
|
},
|
|
|
|
|
axisTick: {
|
|
|
|
|
lineStyle: {
|
|
|
|
|
color: "#070E19",
|
|
|
|
|
width: 3,
|
|
|
|
|
},
|
|
|
|
|
length: 50,
|
|
|
|
|
splitNumber: 2,
|
|
|
|
|
distance: -50,
|
|
|
|
|
show: false,
|
|
|
|
|
},
|
|
|
|
|
splitLine: {
|
|
|
|
|
show: false,
|
|
|
|
|
},
|
|
|
|
|
axisLabel: {
|
|
|
|
|
show: false,
|
|
|
|
|
},
|
|
|
|
|
pointer: {
|
|
|
|
|
show: false,
|
|
|
|
|
},
|
|
|
|
|
axisLabel: {
|
|
|
|
|
show: false,
|
|
|
|
|
},
|
|
|
|
|
detail: {
|
|
|
|
|
show: false,
|
|
|
|
|
valueAnimation: true,
|
|
|
|
|
formatter: "{value}%",
|
|
|
|
|
offsetCenter: [0, "10%"],
|
|
|
|
|
textStyle: {
|
|
|
|
|
color: "#fff",
|
|
|
|
|
fontSize: 25,
|
|
|
|
|
},
|
|
|
|
|
|
|
|
|
|
},
|
|
|
|
|
data: [
|
|
|
|
|
{
|
|
|
|
|
value: 80,
|
|
|
|
|
show: false,
|
|
|
|
|
},
|
|
|
|
|
|
|
|
|
|
],
|
|
|
|
|
},
|
|
|
|
|
{
|
|
|
|
|
//类型
|
|
|
|
|
splitNumber: 4, //刻度数量
|
|
|
|
|
type: "gauge",
|
|
|
|
|
//半径
|
|
|
|
|
radius: 60,
|
|
|
|
|
//起始角度。圆心 正右手侧为0度,正上方为90度,正左手侧为180度。
|
|
|
|
|
startAngle: 360,
|
|
|
|
|
//结束角度。
|
|
|
|
|
endAngle: 0,
|
|
|
|
|
center: ["50%", "40%"],
|
|
|
|
|
//仪表盘轴线相关配置。
|
|
|
|
|
type: "gauge",
|
|
|
|
|
axisLine: {
|
|
|
|
|
lineStyle: {
|
|
|
|
|
width: 1,
|
|
|
|
|
color: [
|
|
|
|
|
[
|
|
|
|
|
1,
|
|
|
|
|
new echarts.graphic.LinearGradient(0, 0, 1, 0, [
|
|
|
|
|
{
|
|
|
|
|
offset: 0.1,
|
|
|
|
|
color: "#619e9d",
|
|
|
|
|
},
|
|
|
|
|
{
|
|
|
|
|
offset: 0.6,
|
|
|
|
|
color: "#619e9d",
|
|
|
|
|
},
|
|
|
|
|
{
|
|
|
|
|
offset: 1,
|
|
|
|
|
color: "#619e9d",
|
|
|
|
|
},
|
|
|
|
|
]),
|
|
|
|
|
],
|
|
|
|
|
],
|
|
|
|
|
},
|
|
|
|
|
},
|
|
|
|
|
axisTick: {
|
|
|
|
|
lineStyle: {
|
|
|
|
|
color: "#070E19",
|
|
|
|
|
width: 3,
|
|
|
|
|
},
|
|
|
|
|
length: 50,
|
|
|
|
|
splitNumber: 2,
|
|
|
|
|
distance: -50,
|
|
|
|
|
show: false,
|
|
|
|
|
},
|
|
|
|
|
splitLine: {
|
|
|
|
|
show: false,
|
|
|
|
|
},
|
|
|
|
|
axisLabel: {
|
|
|
|
|
show: false,
|
|
|
|
|
},
|
|
|
|
|
pointer: {
|
|
|
|
|
show: false,
|
|
|
|
|
},
|
|
|
|
|
axisLabel: {
|
|
|
|
|
show: false,
|
|
|
|
|
},
|
|
|
|
|
detail: {
|
|
|
|
|
show: false,
|
|
|
|
|
valueAnimation: true,
|
|
|
|
|
formatter: "{value}%",
|
|
|
|
|
offsetCenter: [0, "10%"],
|
|
|
|
|
textStyle: {
|
|
|
|
|
color: "#fff",
|
|
|
|
|
fontSize: 25,
|
|
|
|
|
},
|
|
|
|
|
|
|
|
|
|
},
|
|
|
|
|
data: [
|
|
|
|
|
{
|
|
|
|
|
value: 80,
|
|
|
|
|
show: false,
|
|
|
|
|
},
|
|
|
|
|
|
|
|
|
|
],
|
|
|
|
|
},
|
|
|
|
|
],
|
|
|
|
|
|
|
|
|
|
};
|
|
|
|
|
myChart2.setOption(option2);
|
|
|
|
|
},
|
|
|
|
|
selectline() {
|
|
|
|
|
const _this = this;
|
|
|
|
|
this.optionDatalist1 = [];
|
|
|
|
|
this.optionDatalist2 = [];
|
|
|
|
|
this.optionDatalist3 = [];
|
|
|
|
|
this.optionDatalist4 = [];
|
|
|
|
|
this.getdatalist()
|
|
|
|
|
this.initChart1()
|
|
|
|
|
},
|
|
|
|
|
selectline2() {
|
|
|
|
|
const _this = this;
|
|
|
|
|
this.optionDatalist1 = [];
|
|
|
|
|
this.optionDatalist2 = [];
|
|
|
|
|
this.optionDatalist3 = [];
|
|
|
|
|
this.optionDatalist4 = [];
|
|
|
|
|
this.getdatalist()
|
|
|
|
|
this.initChart1()
|
|
|
|
|
},
|
|
|
|
|
//左侧第一个选择类型下拉框 回调函数
|
|
|
|
|
},
|
|
|
|
|
};
|
|
|
|
|
</script>
|
|
|
|
|
|
|
|
|
|
<style lang="scss" scoped>
|
|
|
|
|
.app-container {
|
|
|
|
|
padding: 0px 24px;
|
|
|
|
|
}
|
|
|
|
|
.wrapscroll{
|
|
|
|
|
overflow: hidden;
|
|
|
|
|
}
|
|
|
|
|
.home {
|
|
|
|
|
width: 100%;
|
|
|
|
|
height: 100vh;
|
|
|
|
|
background: url("../../../assets/images/bg-body.png") no-repeat;
|
|
|
|
|
background-size: 100% 100%;
|
|
|
|
|
background-color: #050711;
|
|
|
|
|
|
|
|
|
|
.head {
|
|
|
|
|
width: 100%;
|
|
|
|
|
height: 74px;
|
|
|
|
|
position: relative;
|
|
|
|
|
|
|
|
|
|
.head-content {
|
|
|
|
|
height: 74px;
|
|
|
|
|
background-image: url("../../../assets/images/bg-head.png");
|
|
|
|
|
background-repeat: no-repeat;
|
|
|
|
|
background-size: 100% 100%;
|
|
|
|
|
text-align: center;
|
|
|
|
|
|
|
|
|
|
.title {
|
|
|
|
|
font-size: 42px;
|
|
|
|
|
font-weight: 400;
|
|
|
|
|
color: #ffffff;
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
.head-logo {
|
|
|
|
|
position: absolute;
|
|
|
|
|
left: 0px;
|
|
|
|
|
top: 1px;
|
|
|
|
|
|
|
|
|
|
img {
|
|
|
|
|
height: 38px;
|
|
|
|
|
// width: ;
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
.back {
|
|
|
|
|
position: absolute;
|
|
|
|
|
right: 0px;
|
|
|
|
|
top: 5px;
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
.content-top {
|
|
|
|
|
display: flex;
|
|
|
|
|
justify-content: space-between;
|
|
|
|
|
position: relative;
|
|
|
|
|
|
|
|
|
|
.factory {
|
|
|
|
|
width: 540px;
|
|
|
|
|
height: 60px;
|
|
|
|
|
background: url("../../../assets/images/bg- border1.png") no-repeat;
|
|
|
|
|
background-size: 100% 100%;
|
|
|
|
|
text-align: center;
|
|
|
|
|
position: absolute;
|
|
|
|
|
top: -17px;
|
|
|
|
|
left: 0px;
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
.timebox {
|
|
|
|
|
width: 480px;
|
|
|
|
|
height: 60px;
|
|
|
|
|
background: url("../../../assets/images/bg-border2.png") no-repeat;
|
|
|
|
|
background-size: 100% 100%;
|
|
|
|
|
text-align: center;
|
|
|
|
|
position: absolute;
|
|
|
|
|
top: -17px;
|
|
|
|
|
right: 0px;
|
|
|
|
|
|
|
|
|
|
.time {
|
|
|
|
|
font-size: 30px;
|
|
|
|
|
font-weight: 400;
|
|
|
|
|
color: #ffffff;
|
|
|
|
|
line-height: 71px;
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
.content {
|
|
|
|
|
margin-top: 63px;
|
|
|
|
|
|
|
|
|
|
.itemtop {
|
|
|
|
|
display: flex;
|
|
|
|
|
justify-content: space-between;
|
|
|
|
|
align-items: center;
|
|
|
|
|
|
|
|
|
|
.item-table {
|
|
|
|
|
width: 455px;
|
|
|
|
|
height: 492px;
|
|
|
|
|
background: url('../../../assets/images/equipment/bg-border1.png') no-repeat;
|
|
|
|
|
background-size: 100% 100%;
|
|
|
|
|
padding: 27px 21px 30px 25px;
|
|
|
|
|
box-sizing: border-box;
|
|
|
|
|
box-sizing: border-box;
|
|
|
|
|
|
|
|
|
|
.equipmentinfobox {
|
|
|
|
|
margin-top: 27px;
|
|
|
|
|
display: flex;
|
|
|
|
|
align-items: center;
|
|
|
|
|
justify-content: space-around;
|
|
|
|
|
|
|
|
|
|
.box {
|
|
|
|
|
width: 128px;
|
|
|
|
|
height: 96px;
|
|
|
|
|
background: url('../../../assets/images/equipment/number.png') no-repeat;
|
|
|
|
|
background-size: 100% 100%;
|
|
|
|
|
text-align: center;
|
|
|
|
|
padding-top: 30px;
|
|
|
|
|
box-sizing: border-box;
|
|
|
|
|
|
|
|
|
|
.number {
|
|
|
|
|
.number1 {
|
|
|
|
|
font-size: 30px;
|
|
|
|
|
font-weight: 500;
|
|
|
|
|
color: #66FFFF;
|
|
|
|
|
line-height: 10px;
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
.name2 {
|
|
|
|
|
margin-top: 3px;
|
|
|
|
|
font-size: 16px;
|
|
|
|
|
font-weight: bold;
|
|
|
|
|
color: #FFFFFF;
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
.equipmentinfobox1 {
|
|
|
|
|
margin-top: 22px;
|
|
|
|
|
display: flex;
|
|
|
|
|
align-items: center;
|
|
|
|
|
justify-content: space-between;
|
|
|
|
|
|
|
|
|
|
.box {
|
|
|
|
|
width: 199px;
|
|
|
|
|
height: 96px;
|
|
|
|
|
background: url('../../../assets/images/equipment/number.png') no-repeat;
|
|
|
|
|
background-size: 100% 100%;
|
|
|
|
|
text-align: center;
|
|
|
|
|
padding-top: 30px;
|
|
|
|
|
box-sizing: border-box;
|
|
|
|
|
|
|
|
|
|
.number {
|
|
|
|
|
.number1 {
|
|
|
|
|
font-size: 30px;
|
|
|
|
|
font-weight: 500;
|
|
|
|
|
color: #66FFFF;
|
|
|
|
|
line-height: 10px;
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
.name2 {
|
|
|
|
|
margin-top: 3px;
|
|
|
|
|
font-size: 16px;
|
|
|
|
|
font-weight: bold;
|
|
|
|
|
color: #FFFFFF;
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
.table-tbody {
|
|
|
|
|
.item {
|
|
|
|
|
width: 412px;
|
|
|
|
|
height: 44px;
|
|
|
|
|
display: flex;
|
|
|
|
|
align-items: center;
|
|
|
|
|
justify-content: space-between;
|
|
|
|
|
padding-left: 15px;
|
|
|
|
|
padding-right: 10px;
|
|
|
|
|
margin-bottom: 14px;
|
|
|
|
|
position: relative;
|
|
|
|
|
|
|
|
|
|
.icon {
|
|
|
|
|
position: absolute;
|
|
|
|
|
transform: rotate(45deg);
|
|
|
|
|
top: -2px;
|
|
|
|
|
left: 0px;
|
|
|
|
|
width: 0;
|
|
|
|
|
height: 0;
|
|
|
|
|
border-right: 6px solid #3BE8FF;
|
|
|
|
|
border-top: 6px solid transparent;
|
|
|
|
|
border-bottom: 6px solid transparent;
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
.itemname1 {
|
|
|
|
|
font-size: 16px;
|
|
|
|
|
color: #66E1DF;
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
.itemname2 {
|
|
|
|
|
font-size: 14px;
|
|
|
|
|
color: #D0DEEE;
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
.bigechartbox {
|
|
|
|
|
display: flex;
|
|
|
|
|
position: relative;
|
|
|
|
|
|
|
|
|
|
.title1 {
|
|
|
|
|
font-size: 18px;
|
|
|
|
|
font-weight: 400;
|
|
|
|
|
color: #99B3C8;
|
|
|
|
|
position: absolute;
|
|
|
|
|
bottom: -26px;
|
|
|
|
|
left: 52px;
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
.title2 {
|
|
|
|
|
position: absolute;
|
|
|
|
|
font-size: 18px;
|
|
|
|
|
font-weight: 400;
|
|
|
|
|
color: #99B3C8;
|
|
|
|
|
bottom: -26px;
|
|
|
|
|
right: 58px;
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
.itembottom {
|
|
|
|
|
margin-top: 19px;
|
|
|
|
|
display: flex;
|
|
|
|
|
justify-content: space-around;
|
|
|
|
|
|
|
|
|
|
.item-table {
|
|
|
|
|
width: 929px;
|
|
|
|
|
height: 403px;
|
|
|
|
|
background: url('../../../assets/images/equipment/bg-border1.png') no-repeat;
|
|
|
|
|
background-size: 100% 100%;
|
|
|
|
|
padding: 27px 21px 30px 25px;
|
|
|
|
|
box-sizing: border-box;
|
|
|
|
|
box-sizing: border-box;
|
|
|
|
|
|
|
|
|
|
.table-thead {
|
|
|
|
|
width: 100%;
|
|
|
|
|
height: 44px;
|
|
|
|
|
margin: auto;
|
|
|
|
|
background: #0A1A33;
|
|
|
|
|
|
|
|
|
|
td {
|
|
|
|
|
font-size: 19px;
|
|
|
|
|
font-family: NotoSansHans-Medium, NotoSansHans;
|
|
|
|
|
font-weight: 500;
|
|
|
|
|
color: #159AFF;
|
|
|
|
|
text-align: center;
|
|
|
|
|
white-space: nowrap;
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
.table-tbody {
|
|
|
|
|
height: 192px;
|
|
|
|
|
// width: 1775px;
|
|
|
|
|
margin: auto;
|
|
|
|
|
overflow-y: scroll;
|
|
|
|
|
|
|
|
|
|
table {
|
|
|
|
|
width: 100%;
|
|
|
|
|
|
|
|
|
|
tbody {
|
|
|
|
|
width: 100%;
|
|
|
|
|
|
|
|
|
|
td {
|
|
|
|
|
font-size: 19px;
|
|
|
|
|
font-family: NotoSansHans-Medium, NotoSansHans;
|
|
|
|
|
font-weight: 500;
|
|
|
|
|
color: #FFFFFF;
|
|
|
|
|
text-align: center;
|
|
|
|
|
border-bottom: 1px dashed #6C8097
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
.item-table1:first-child {
|
|
|
|
|
margin-right: 10px;
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
.item-table1 {
|
|
|
|
|
flex: 1;
|
|
|
|
|
margin-top: 20px;
|
|
|
|
|
padding-top: 19px;
|
|
|
|
|
|
|
|
|
|
// .table-thead {
|
|
|
|
|
// width: 565.01px;
|
|
|
|
|
// }
|
|
|
|
|
|
|
|
|
|
.table-tbody {
|
|
|
|
|
height: 144px;
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
.titlebox {
|
|
|
|
|
width: 431px;
|
|
|
|
|
height: 38px;
|
|
|
|
|
background: url("../../../assets/images/bg-title.png") no-repeat;
|
|
|
|
|
background-size: 100% 100%;
|
|
|
|
|
// text-align: center;
|
|
|
|
|
font-size: 20px;
|
|
|
|
|
font-weight: bold;
|
|
|
|
|
color: #ffffff;
|
|
|
|
|
line-height: 38px;
|
|
|
|
|
letter-spacing: 2px;
|
|
|
|
|
text-shadow: 0px 2px 4px rgba(0, 0, 0, 0.5);
|
|
|
|
|
padding-left: 60px;
|
|
|
|
|
// .titlename{
|
|
|
|
|
// position: relative;
|
|
|
|
|
// left: 24px;
|
|
|
|
|
// }
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
.factory {
|
|
|
|
|
display: flex;
|
|
|
|
|
// justify-content: space-around;
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
.selectborder {
|
|
|
|
|
background-color: transparent;
|
|
|
|
|
border-radius: 4px;
|
|
|
|
|
// border: 2px solid #27408c;
|
|
|
|
|
position: relative;
|
|
|
|
|
display: flex;
|
|
|
|
|
align-items: center;
|
|
|
|
|
justify-content: space-around;
|
|
|
|
|
width: 350px;
|
|
|
|
|
margin-left: 50px;
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
.selectborder1 {
|
|
|
|
|
background-color: transparent;
|
|
|
|
|
border-radius: 4px;
|
|
|
|
|
// border: 2px solid #27408c;
|
|
|
|
|
position: relative;
|
|
|
|
|
display: flex;
|
|
|
|
|
align-items: center;
|
|
|
|
|
justify-content: space-around;
|
|
|
|
|
width: 88px;
|
|
|
|
|
margin-left: 25px;
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
.selectborder select {
|
|
|
|
|
/*清除select的边框样式*/
|
|
|
|
|
border: none;
|
|
|
|
|
/*清除select聚焦时候的边框颜色*/
|
|
|
|
|
outline: none;
|
|
|
|
|
background-color: transparent;
|
|
|
|
|
/*将select的宽高等于div的宽高*/
|
|
|
|
|
width: 100%;
|
|
|
|
|
height: 50px;
|
|
|
|
|
/*隐藏select的下拉图标*/
|
|
|
|
|
-webkit-appearance: none;
|
|
|
|
|
-moz-appearance: none;
|
|
|
|
|
appearance: none;
|
|
|
|
|
font-size: 25px;
|
|
|
|
|
font-weight: 400;
|
|
|
|
|
color: #ffffff;
|
|
|
|
|
line-height: 42px;
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
.selectborder option {
|
|
|
|
|
/*清除select的边框样式*/
|
|
|
|
|
border: none;
|
|
|
|
|
/*清除select聚焦时候的边框颜色*/
|
|
|
|
|
outline: none;
|
|
|
|
|
background-color: transparent;
|
|
|
|
|
/*将select的宽高等于div的宽高*/
|
|
|
|
|
width: 100%;
|
|
|
|
|
height: 50px;
|
|
|
|
|
/*隐藏select的下拉图标*/
|
|
|
|
|
-webkit-appearance: none;
|
|
|
|
|
-moz-appearance: none;
|
|
|
|
|
appearance: none;
|
|
|
|
|
padding-left: 20px;
|
|
|
|
|
font-size: 25px;
|
|
|
|
|
font-weight: 500;
|
|
|
|
|
color: #3fa2ff;
|
|
|
|
|
border-radius: 0%;
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
.selectborder1 option {
|
|
|
|
|
/*清除select的边框样式*/
|
|
|
|
|
border: none;
|
|
|
|
|
/*清除select聚焦时候的边框颜色*/
|
|
|
|
|
outline: none;
|
|
|
|
|
background-color: transparent;
|
|
|
|
|
/*将select的宽高等于div的宽高*/
|
|
|
|
|
width: 200px;
|
|
|
|
|
height: 50px;
|
|
|
|
|
/*隐藏select的下拉图标*/
|
|
|
|
|
-webkit-appearance: none;
|
|
|
|
|
-moz-appearance: none;
|
|
|
|
|
appearance: none;
|
|
|
|
|
padding-left: 20px;
|
|
|
|
|
font-size: 25px;
|
|
|
|
|
font-weight: 500;
|
|
|
|
|
color: #3fa2ff;
|
|
|
|
|
border-radius: 0%;
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
.selectborder:after {
|
|
|
|
|
content: "";
|
|
|
|
|
width: 24px;
|
|
|
|
|
height: 24px;
|
|
|
|
|
background: url(../../../assets/images/xiala.png) no-repeat center;
|
|
|
|
|
/*通过定位将图标放在合适的位置*/
|
|
|
|
|
position: absolute;
|
|
|
|
|
right: 0px;
|
|
|
|
|
top: 25%;
|
|
|
|
|
/*给自定义的图标实现点击下来功能*/
|
|
|
|
|
pointer-events: none;
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
.selectborder1:after {
|
|
|
|
|
content: "";
|
|
|
|
|
width: 24px;
|
|
|
|
|
height: 24px;
|
|
|
|
|
background: url(../../../assets/images/xiala.png) no-repeat center;
|
|
|
|
|
/*通过定位将图标放在合适的位置*/
|
|
|
|
|
position: absolute;
|
|
|
|
|
right: 0px;
|
|
|
|
|
top: 25%;
|
|
|
|
|
/*给自定义的图标实现点击下来功能*/
|
|
|
|
|
pointer-events: none;
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
::v-deep .el-button--primary {
|
|
|
|
|
color: #ffffff;
|
|
|
|
|
background-color: #325e82;
|
|
|
|
|
border-color: #0a0f19;
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
.active1 {
|
|
|
|
|
background-color: #0A162A;
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
.active2 {
|
|
|
|
|
background-color: #101F2C;
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
::-webkit-scrollbar {
|
|
|
|
|
width: 3px;
|
|
|
|
|
height: 0px;
|
|
|
|
|
background-color: #0c0642;
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
/*定义滚动条轨道 内阴影+圆角*/
|
|
|
|
|
::-webkit-scrollbar-track {
|
|
|
|
|
-webkit-box-shadow: inset 0 0 6px rgba(0, 0, 0, 0.3);
|
|
|
|
|
border-radius: 8px;
|
|
|
|
|
background-color: #07356a;
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
/*定义滑块 内阴影+圆角*/
|
|
|
|
|
::-webkit-scrollbar-thumb {
|
|
|
|
|
border-radius: 8px;
|
|
|
|
|
-webkit-box-shadow: inset 0 0 6px rgba(0, 0, 0, 0.3);
|
|
|
|
|
background-color: #0091ff;
|
|
|
|
|
// opacity: 0.1;
|
|
|
|
|
}
|
|
|
|
|
</style>
|