| | |
| | | <div class="back-nav" @click="$emit('backToLastSignage','BranchFactory')" v-if="userType>=3"> |
| | | <dv-decoration-7>上一级</dv-decoration-7> |
| | | </div> |
| | | <dv-border-box-9 style="padding: 15px"> |
| | | |
| | | <dv-border-box-9 style="padding: 15px 15px 0"> |
| | | <div id="tech_condition_chart" style="width:100%;height: 240px;"></div> |
| | | <div id="warranty_malfunction_chart" style="width:100%;height: 240px;"></div> |
| | | <div style="display: flex;"> |
| | | |
| | | <div style="flex:0.5;display: flex;flex-direction:column;align-items: center"> |
| | | <dv-decoration-11 style="width:90%;height:60px;color: #ccc;font-size: 20px">三保计划</dv-decoration-11> |
| | | <div> |
| | | <div style="display: flex;flex-direction:column;align-items: center"> |
| | | <dv-decoration-11 style="width:45%;height:60px;color: #fff;font-size: 20px;align-self: flex-start">三保计划 |
| | | </dv-decoration-11> |
| | | <div class="support-plan-container"> |
| | | <div class="support-plan-item" style="background:#5FE0AF"> |
| | | <div>三保本月计划</div> |
| | |
| | | <div class="support-plan-item" style="background:#FCAA29"> |
| | | <div>延期</div> |
| | | <div class="plan-value-container"> |
| | | <div class="plan-value">{{nextMonthMaintenancePlanNum}}</div> |
| | | <div class="plan-value">{{maintenanceExtensionNum}}</div> |
| | | <div>台</div> |
| | | </div> |
| | | </div> |
| | | <div class="support-plan-item" style="background:#F56C6C"> |
| | | <div>超期</div> |
| | | <div class="plan-value-container"> |
| | | <div class="plan-value">{{nextNextMonthMaintenancePlanNum}}</div> |
| | | <div class="plan-value">{{maintenanceOverdueNum}}</div> |
| | | <div>台</div> |
| | | </div> |
| | | </div> |
| | | <div class="support-plan-item" style="background:#D6BC52"> |
| | | <div>下月计划</div> |
| | | <div class="plan-value-container"> |
| | | <div class="plan-value">{{nextNextMonthMaintenancePlanNum}}</div> |
| | | <div class="plan-value">{{nextMonthMaintenancePlanNum}}</div> |
| | | <div>台</div> |
| | | </div> |
| | | </div> |
| | |
| | | </div> |
| | | </div> |
| | | |
| | | <div style="flex:0.5;display: flex;justify-content: center"> |
| | | <dv-decoration-11 style="width:90%;height:60px;color: #ccc;font-size: 20px">二保计划</dv-decoration-11> |
| | | <div style="display: flex;margin-top: 10px;justify-content: space-between;align-items: center;"> |
| | | <dv-decoration-11 style="width:45%;height:60px;font-size: 20px;color: #fff">二保计划</dv-decoration-11> |
| | | <div |
| | | style="flex:1;text-align:center;font-size: 25px;color: #9BD890;overflow: hidden;text-overflow: ellipsis;white-space: nowrap"> |
| | | 2024年4月1日大修 |
| | | </div> |
| | | </div> |
| | | </div> |
| | | </dv-border-box-9> |
| | |
| | | ], |
| | | thisMonthMaintenancePlanNum: 0, |
| | | thisMonthMaintenanceRealNum: 0, |
| | | maintenanceExtensionNum: 0, |
| | | maintenanceOverdueNum: 0, |
| | | nextMonthMaintenancePlanNum: 0, |
| | | nextNextMonthMaintenancePlanNum: 0, |
| | | lineChart: '', |
| | | lineChartData: [], |
| | | lineChartData: {}, |
| | | gaugeChart1: '', |
| | | gaugeChart2: '', |
| | | gaugeChart3: '', |
| | |
| | | gaugeChartData3: [], |
| | | gaugeChartData4: [], |
| | | barChart: '', |
| | | barChartData: [ |
| | | { |
| | | name: '2640221', |
| | | value: 20 |
| | | }, |
| | | { |
| | | name: '2640222', |
| | | value: 40 |
| | | }, |
| | | { |
| | | name: '2640223', |
| | | value: 70 |
| | | }, |
| | | { |
| | | name: '2640224', |
| | | value: 30 |
| | | }, |
| | | { |
| | | name: '2640225', |
| | | value: 35 |
| | | }, |
| | | { |
| | | name: '2640226', |
| | | value: 80 |
| | | }, |
| | | { |
| | | name: '2640227', |
| | | value: 40 |
| | | }, |
| | | { |
| | | name: '12640220', |
| | | value: 60 |
| | | }, |
| | | { |
| | | name: '12640221', |
| | | value: 40 |
| | | }, |
| | | { |
| | | name: '12640222', |
| | | value: 35 |
| | | } |
| | | ], |
| | | barChartData: [], |
| | | equipmentId: '' |
| | | } |
| | | }, |
| | |
| | | this.getWarrantyMalfunctionDataByApi() |
| | | this.getRunningStateDataByApi() |
| | | this.getMonthMaintenanceNumByApi() |
| | | this.getLineChartDataByApi() |
| | | this.getBarChartDataByApi() |
| | | }, |
| | | |
| | | /* 调用接口获取技术状态 */ |
| | |
| | | }) |
| | | }, |
| | | |
| | | /* 调用接口获取设备运行状态 */ |
| | | getRunningStateDataByApi() { |
| | | signageApi.getEquipmentStatusStatisticsApi(this.productionCode) |
| | | .then(res => { |
| | | if (res.success) this.runningStateData = res.result.list |
| | | this.drawRunningStateChart(res.result.producitonId) |
| | | }) |
| | | }, |
| | | |
| | | /* 调用接口获取三保计划 */ |
| | | getMonthMaintenanceNumByApi() { |
| | | signageApi.getThisMonthMaintenanceListApi(this.productionCode) |
| | |
| | | }) |
| | | }, |
| | | |
| | | /* 调用接口获取设备运行状态 */ |
| | | getRunningStateDataByApi() { |
| | | signageApi.getEquipmentStatusStatisticsApi(this.productionCode) |
| | | .then(res => { |
| | | if (res.success) this.runningStateData = res.result.list |
| | | this.drawRunningStateChart(res.result.producitonId) |
| | | }) |
| | | }, |
| | | |
| | | /* 调用接口获取前7天利用率 */ |
| | | getLineChartDataByApi() { |
| | | signageApi.getEquipmentDayUtilizationStatisticsApi(this.productionCode) |
| | | .then(res => { |
| | | if (res.success) this.lineChartData = res.result |
| | | this.drawLineChart() |
| | | }) |
| | | }, |
| | | |
| | | getBarChartDataByApi() { |
| | | signageApi.getEquipmentOEEMonthStatisticsApi(this.productionCode) |
| | | .then(res => { |
| | | console.log('res=', res) |
| | | if (res.success) { |
| | | this.barChartData = res.result.map(item => { |
| | | return { |
| | | name: item.equipmentId, |
| | | value: item.overallEquipmentEfficiency |
| | | } |
| | | }) |
| | | } |
| | | this.drawBarChart() |
| | | }) |
| | | }, |
| | | |
| | | /* 绘制图表汇总方法 */ |
| | | drawCharts() { |
| | | this.drawRunningStateChart() |
| | | this.drawTechConditionChart() |
| | | this.drawWarrantyMalfunctionChart() |
| | | this.drawLineChart() |
| | | this.drawGaugeChart() |
| | | this.drawBarChart() |
| | | }, |
| | |
| | | show: true, // 是否显示标题,默认为true |
| | | text: '技术状态', // 主标题文本 |
| | | x: 'left', // 标题水平安放位置,可选值为'left'、'center'、'right'或具体的水平坐标值 |
| | | y: 'top', // 标题垂直安放位置,可选值为'top'、'bottom'、'center'或具体的垂直坐标值 |
| | | y: this.userType >= 3 ? '25' : 'top', // 标题垂直安放位置,可选值为'top'、'bottom'、'center'或具体的垂直坐标值 |
| | | textStyle: { |
| | | // 主标题文本样式 |
| | | fontSize: 18, |
| | |
| | | series: [ |
| | | { |
| | | type: 'pie', |
| | | // roseType: 'angle', // 玫瑰图 |
| | | roseType: 'angle', // 玫瑰图 |
| | | // selectedMode: "single", |
| | | radius: ['35%', '55%'], |
| | | center: ['50%', '50%'], |
| | |
| | | drawLineChart() { |
| | | this.lineChart = this.$echarts.init(document.getElementById('line_chart')) |
| | | const newData = { |
| | | xAxis: ['3月19日', '3月20日', '3月21日', '3月22日', '3月23日', '3月24日', '3月25日'], |
| | | xAxis: this.lineChartData.dateList, |
| | | yAxis: [ |
| | | { |
| | | name: '利用率', |
| | | value: [200, 600, 550, 360, 520, 520, 630] |
| | | value: this.lineChartData.dataList.map(item => item.utilizationRate) |
| | | }, |
| | | { |
| | | name: '开动率', |
| | | value: [230, 630, 440, 400, 740, 800, 600] |
| | | value: this.lineChartData.dataList.map(item => item.startRate) |
| | | }, |
| | | { |
| | | name: '开机率', |
| | | value: [900, 700, 400, 700, 800, 605, 730] |
| | | value: this.lineChartData.dataList.map(item => item.openRate) |
| | | } |
| | | ], |
| | | yAxisName: '前7天利用率(%)' |
| | |
| | | // } |
| | | } |
| | | this.lineChart.setOption(option, true) |
| | | // if (newData.xAxis.length <= 6) return |
| | | // this.lineChartCarouselTime = setInterval(() => { |
| | | // this.barChartData.push(this.barChartData.shift()) |
| | | // newData.xAxis.push(newData.xAxis.shift()) |
| | | // newData.yAxis.forEach(item => item.value.push(item.value.shift())) |
| | | // this.$nextTick(() => { |
| | | // this.lineChart.setOption(option, true) |
| | | // }) |
| | | // }, 3000) |
| | | }, |
| | | |
| | | /* 绘制仪表盘图表 */ |
| | |
| | | height: 260, |
| | | title: { |
| | | show: true, // 是否显示标题,默认为true |
| | | text: '上个月OEE', // 主标题文本 |
| | | text: '', // 主标题文本 |
| | | x: 'center', // 标题水平安放位置,可选值为'left'、'center'、'right'或具体的水平坐标值 |
| | | y: 'top', // 标题垂直安放位置,可选值为'top'、'bottom'、'center'或具体的垂直坐标值 |
| | | textStyle: { |
| | |
| | | color: #fff; |
| | | margin-bottom: 10px; |
| | | |
| | | .workshop-nav { |
| | | width: 120px; |
| | | height: 40px; |
| | | font-size: 12px; |
| | | cursor: pointer; |
| | | } |
| | | } |
| | | |
| | | .content-container { |
| | |
| | | justify-content: space-between; |
| | | |
| | | .left-col { |
| | | .back-nav { |
| | | width: 100px; |
| | | height: 30px; |
| | | color: #fff; |
| | | position: absolute; |
| | | top: 50px; |
| | | left: 10px; |
| | | cursor: pointer; |
| | | z-index: 9999 |
| | | } |
| | | |
| | | .support-plan-container { |
| | | width: 100%; |
| | | display: flex; |
| | | justify-content: space-around; |
| | | flex-wrap: wrap; |
| | | color: #fff; |
| | | padding-top: 5px; |
| | | padding-top: 20px; |
| | | |
| | | .support-plan-item { |
| | | border-radius: 3px; |
| | | width: 45%; |
| | | width: 30%; |
| | | padding: 5px 10px; |
| | | margin-bottom: 10px; |
| | | |
| | |
| | | } |
| | | } |
| | | } |
| | | } |
| | | } |
| | | |
| | | .middle-col { |
| | | .first-title { |
| | | color: #00A8AC; |
| | | font-size: 20px; |
| | | text-align: center; |
| | | font-weight: bold; |
| | | } |
| | | } |
| | | |