|
@@ -9,11 +9,13 @@
|
|
|
<el-form-item class="divLine"></el-form-item>
|
|
|
<el-form-item>{{mouldName}}</el-form-item>
|
|
|
<el-form-item class="state" style="float: right;">{{$t('runTest.state')}}:
|
|
|
- <span v-if="mouldState == 0">{{$t('base.static')}}</span>
|
|
|
- <span v-else-if="mouldState == 1">{{$t('base.motion')}}</span>
|
|
|
- <span v-else-if="mouldState == 2">{{$t('base.warning')}}</span>
|
|
|
- <span v-else-if="mouldState == 3">{{$t('mold.beScrapped')}}</span>
|
|
|
- <span v-else-if="mouldState == 4">{{$t('mold.scraped')}}</span>
|
|
|
+ <span style="color:#909399" v-if="mouldState == 0">{{$t('base.static')}}</span>
|
|
|
+ <span style="color:#00CD66" v-else-if="mouldState == 1">{{$t('base.run')}}</span>
|
|
|
+ <span style="color:#F56C6C" v-else-if="mouldState == 2">{{$t('base.warning')}}</span>
|
|
|
+ <span style="color:#909399" v-else-if="mouldState == 3">{{$t('mold.beScrapped')}}</span>
|
|
|
+ <span style="color:#909399" v-else-if="mouldState == 4">{{$t('mold.scraped')}}</span>
|
|
|
+ <span style="color:#F56C6C" v-else-if="mouldState == 5">{{$t('mold.abnormal')}}</span>
|
|
|
+ <span style="color:#F56C6C" v-else-if="mouldState == 6">{{$t('mold.dropped')}}</span>
|
|
|
</el-form-item>
|
|
|
</el-form>
|
|
|
</el-col>
|
|
@@ -52,9 +54,11 @@
|
|
|
<el-col :span="11" :offset="2">
|
|
|
<div style="padding:0 20px">
|
|
|
<b style="font-size:20px;text-align:center;margin-bottom:20px;">{{$t('runTest.openCycleChart')}}</b>
|
|
|
- <el-date-picker v-model="openCycle" style="float:right;width:210px;" format="yyyy-MM-dd" value-format="yyyy-MM-dd"
|
|
|
+ <!-- <el-date-picker v-model="openCycle" style="float:right;width:210px;" format="yyyy-MM-dd" value-format="yyyy-MM-dd"
|
|
|
@change='changeOpen(2)' size="mini" :clearable="false" type="daterange"
|
|
|
- :start-placeholder="$t('el.datepicker.startDate')" :end-placeholder="$t('el.datepicker.endDate')"></el-date-picker>
|
|
|
+ :start-placeholder="$t('el.datepicker.startDate')" :end-placeholder="$t('el.datepicker.endDate')"></el-date-picker> -->
|
|
|
+ <el-date-picker v-model="openCycle" style="float:right;width:125px;" format="yyyy-MM-dd" value-format="yyyy-MM-dd"
|
|
|
+ @change='changeOpen(2)' size="mini" :clearable="false" type="date" :placeholder="$t('el.datepicker.selectDate')"></el-date-picker>
|
|
|
</div>
|
|
|
<div id="myChart2" :style="{ height: '300px'}"></div>
|
|
|
</el-col>
|
|
@@ -224,7 +228,8 @@
|
|
|
},
|
|
|
imageUrl: "",
|
|
|
openNum: util.formatDate.format(new Date(), 'yyyy-MM-dd'),
|
|
|
- openCycle: [util.formatDate.format(new Date(), 'yyyy-MM-dd') , util.formatDate.format(new Date(), 'yyyy-MM-dd')],
|
|
|
+ // openCycle: [util.formatDate.format(new Date(), 'yyyy-MM-dd') , util.formatDate.format(new Date(), 'yyyy-MM-dd')],
|
|
|
+ openCycle: util.formatDate.format(new Date(), 'yyyy-MM-dd'),
|
|
|
allDetail: {
|
|
|
overflow: 'auto',
|
|
|
padding: '0px 5px',
|
|
@@ -540,8 +545,8 @@
|
|
|
sData = [];
|
|
|
|
|
|
for(var i in list) {
|
|
|
- xData.push(i);
|
|
|
- sData.push(list[i])
|
|
|
+ xData.push(list[i].timeSlot);
|
|
|
+ sData.push(list[i].runtime)
|
|
|
}
|
|
|
option.xAxis.data = xData;
|
|
|
option.series[0].data = sData;
|
|
@@ -574,12 +579,12 @@
|
|
|
tooltip: {
|
|
|
trigger: 'axis'
|
|
|
},
|
|
|
- grid: {
|
|
|
- left: '3%',
|
|
|
- right: '4%',
|
|
|
- bottom: '3%',
|
|
|
- containLabel: true
|
|
|
- },
|
|
|
+ // grid: {
|
|
|
+ // left: '3%',
|
|
|
+ // right: '4%',
|
|
|
+ // bottom: '3%',
|
|
|
+ // containLabel: true
|
|
|
+ // },
|
|
|
xAxis: {
|
|
|
type: 'category',
|
|
|
boundaryGap: false,
|
|
@@ -589,10 +594,27 @@
|
|
|
name: this.$t('runTest.sec') + '(s)',
|
|
|
type: 'value'
|
|
|
},
|
|
|
+ dataZoom: [{
|
|
|
+ type: 'inside',
|
|
|
+ start: 0,
|
|
|
+ end: 10
|
|
|
+ }, {
|
|
|
+ start: 0,
|
|
|
+ end: 10,
|
|
|
+ handleIcon: 'M10.7,11.9v-1.3H9.3v1.3c-4.9,0.3-8.8,4.4-8.8,9.4c0,5,3.9,9.1,8.8,9.4v1.3h1.3v-1.3c4.9-0.3,8.8-4.4,8.8-9.4C19.5,16.3,15.6,12.2,10.7,11.9z M13.3,24.4H6.7V23h6.6V24.4z M13.3,19.6H6.7v-1.4h6.6V19.6z',
|
|
|
+ handleSize: '80%',
|
|
|
+ handleStyle: {
|
|
|
+ color: '#fff',
|
|
|
+ shadowBlur: 3,
|
|
|
+ shadowColor: 'rgba(0, 0, 0, 0.6)',
|
|
|
+ shadowOffsetX: 2,
|
|
|
+ shadowOffsetY: 2
|
|
|
+ }
|
|
|
+ }],
|
|
|
series: [{
|
|
|
name: this.$t('runTest.maxOpenCycle'),
|
|
|
type: 'line',
|
|
|
- stack: this.$t('runTest.openCycle'),
|
|
|
+ // stack: this.$t('runTest.openCycle'),
|
|
|
data:[],
|
|
|
itemStyle : {
|
|
|
normal : {
|
|
@@ -606,7 +628,7 @@
|
|
|
{
|
|
|
name: this.$t('runTest.minOpenCycle'),
|
|
|
type:'line',
|
|
|
- stack: this.$t('runTest.openCycle'),
|
|
|
+ // stack: this.$t('runTest.openCycle'),
|
|
|
data:[],
|
|
|
itemStyle : {
|
|
|
normal : {
|
|
@@ -620,7 +642,21 @@
|
|
|
{
|
|
|
name: this.$t('runTest.avgOpenCycle'),
|
|
|
type: 'line',
|
|
|
- stack: this.$t('runTest.openCycle'),
|
|
|
+ // stack: this.$t('runTest.openCycle'),
|
|
|
+ data:[],
|
|
|
+ itemStyle : {
|
|
|
+ normal : {
|
|
|
+ color: "#7fb80e", //改变折线点的颜色
|
|
|
+ lineStyle:{
|
|
|
+ color: "#7fb80e" //改变折线颜色
|
|
|
+ }
|
|
|
+ }
|
|
|
+ }
|
|
|
+ },
|
|
|
+ {
|
|
|
+ name: this.$t('runTest.theoryCycle'),
|
|
|
+ type: 'line',
|
|
|
+ // stack: this.$t('runTest.openCycle'),
|
|
|
data:[],
|
|
|
itemStyle : {
|
|
|
normal : {
|
|
@@ -634,18 +670,20 @@
|
|
|
},
|
|
|
list = res.data,
|
|
|
xData = [],
|
|
|
- avg = [] , max = [] , min = [];
|
|
|
+ avg = [] , max = [] , min = [] , the = [];
|
|
|
|
|
|
for(var i in list) {
|
|
|
- xData.push(list[i].time);
|
|
|
+ xData.push(i);
|
|
|
max.push(list[i].maxCycle/1000);
|
|
|
min.push(list[i].minCycle/1000);
|
|
|
avg.push(list[i].avgCycle/1000);
|
|
|
+ the.push(list[i].theoryCycle/1000);
|
|
|
}
|
|
|
option.xAxis.data = xData;
|
|
|
option.series[0].data = max;
|
|
|
option.series[1].data = min;
|
|
|
option.series[2].data = avg;
|
|
|
+ option.series[3].data = the;
|
|
|
|
|
|
this.drawEchart(2,JSON.stringify(option));
|
|
|
} else {
|