From 03cec15c5f30cb7eda1e76bbf4183ad9c89e4f83 Mon Sep 17 00:00:00 2001
From: zhaowei <zhaowei>
Date: 星期五, 05 九月 2025 15:39:54 +0800
Subject: [PATCH] 1、设备TEEP页面删除滚动加载功能 2、mdc首页工段级看板调整样式及功能

---
 src/views/dashboard/WorkshopSectionSignage.vue |  529 ++++++++++++++++++++++++++++++++--------------------------
 1 files changed, 289 insertions(+), 240 deletions(-)

diff --git a/src/views/dashboard/WorkshopSectionSignage.vue b/src/views/dashboard/WorkshopSectionSignage.vue
index 7523ffb..4ff428c 100644
--- a/src/views/dashboard/WorkshopSectionSignage.vue
+++ b/src/views/dashboard/WorkshopSectionSignage.vue
@@ -11,7 +11,8 @@
           <div id="warranty_malfunction_chart" style="width:100%;height: 240px;"></div>
           <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
+                style="width:45%;height:60px;color: rgba(0,0,0,.45);font-size: 20px;align-self: flex-start">涓変繚璁″垝
               </dv-decoration-11>
               <div class="support-plan-container">
                 <div v-for="(item,index) in supportPlanList" :key="index" class="support-plan-item"
@@ -26,9 +27,10 @@
             </div>
 
             <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>
+              <dv-decoration-11 style="width:45%;height:60px;font-size: 20px;color: rgba(0,0,0,.45)">浜屼繚璁″垝
+              </dv-decoration-11>
               <div
-                style="flex:1;text-align:center;font-size: 25px;color: #9BD890;overflow: hidden;text-overflow: ellipsis;white-space: nowrap">
+                style="flex:1;text-align:center;font-size: 25px;color: rgba(0,0,0,.45);overflow: hidden;text-overflow: ellipsis;white-space: nowrap">
                 2024骞�4鏈�1鏃ュぇ淇�
               </div>
             </div>
@@ -79,6 +81,7 @@
   import signageApi from '@/api/signage'
   import moment from 'moment'
   import SignageModal from './modules/SignageModal'
+  import * as echarts from 'echarts'
 
   export default {
     name: 'WorkshopSectionSignage',
@@ -124,40 +127,38 @@
           {
             planTime: '鏈湀涓変繚璁″垝',
             planValueLabel: 'thisMonthMaintenancePlanNum',
-            backgroundColor: '#5FE0AF',
-            apiUrl: '/eam/calibrationOrder/showThisMonthMaintenanceList'
+            backgroundColor: '#719D8E',
+            code: 'bysbzs'
           },
-
           {
             planTime: '鏈湀瀹屾垚閲�',
             planValueLabel: 'thisMonthMaintenanceRealNum',
             backgroundColor: '#409EFF',
-            apiUrl: '/eam/calibrationOrder/showThisMonthMaintenanceFinishList'
+            code: 'bwc'
           },
           {
             planTime: '寤舵湡',
             planValueLabel: 'maintenanceExtensionNum',
-            backgroundColor: '#FCAA29',
-            apiUrl: '/eam/calibrationOrder/show3MaintenancePostponeList'
+            backgroundColor: '#E89D29',
+            code: ''
           },
-
           {
             planTime: '瓒呮湡',
             planValueLabel: 'maintenanceOverdueNum',
             backgroundColor: '#F56C6C',
-            apiUrl: '/eam/calibrationOrder/show3MaintenanceOverdueList'
+            code: ''
           },
           {
             planTime: '涓嬫湀璁″垝',
             planValueLabel: 'nextMonthMaintenancePlanNum',
-            backgroundColor: '#D6BC52',
-            apiUrl: '/eam/calibrationOrder/showNextMonthMaintenanceList'
+            backgroundColor: '#A8985D',
+            code: 'xysb'
           },
           {
             planTime: '涓嬩笅鏈堣鍒�',
             planValueLabel: 'nextNextMonthMaintenancePlanNum',
             backgroundColor: '#58D9F9',
-            apiUrl: '/eam/calibrationOrder/showNextNextMonthMaintenanceList'
+            code: 'xxysb'
           }
         ],
         thisMonthMaintenancePlanNum: 0,
@@ -204,78 +205,83 @@
     methods: {
       /* 璋冪敤鎺ュ彛鑾峰彇鍥捐〃鏁版嵁姹囨�绘柟娉� */
       getChartDataByApi() {
-        this.getTechConditionDataByApi()
-        this.getWarrantyMalfunctionDataByApi()
+        this.getTechConditionAndWarrantyMalfunctionDataByApi()
         this.getRunningStateDataByApi()
-        this.getMonthMaintenanceNumByApi()
+        this.getThirdMaintenanceNumByApi()
         this.getFirst7DaysEfficiencyDataByApi()
         this.getGaugeChartDataByApi()
         this.getBarChartDataByApi()
       },
 
-      /* 璋冪敤鎺ュ彛鑾峰彇鎶�鏈姸鎬� */
-      getTechConditionDataByApi() {
+      /* 璋冪敤鎺ュ彛鑾峰彇鎶�鏈姸鎬佷笌鏁呴殰鎶ヤ慨 */
+      getTechConditionAndWarrantyMalfunctionDataByApi() {
         this.techConditionChart = this.$echarts.init(document.getElementById('tech_condition_chart'))
+        this.warrantyMalfunctionChart = this.$echarts.init(document.getElementById('warranty_malfunction_chart'))
         this.techConditionChart.showLoading({
           text: '鏁版嵁鍔犺浇涓� ...',
           color: '#0696e1', // 鍔犺浇鍔ㄧ敾棰滆壊
-          textColor: '#fff',
-          maskColor: 'rgba(1, 25, 75, 0.2)' // 閬僵灞�
+          textColor: 'rgba(0, 0, 0, .45)'
         })
-        signageApi.getEquipmentTechnologyStatusListApi(this.productionCode)
-          .then(res => {
-            if (res.success && res.result) {
-              this.techConditionData = [
-                { value: res.result[0].qualifiedCount, name: '鍚堟牸', technologyStatus: 'qualified' },
-                { value: res.result[0].disabledCount, name: '绂佺敤', technologyStatus: 'disabled' },
-                { value: res.result[0].limitedUseCount, name: '闄愮敤', technologyStatus: 'limitedUse' }
-              ]
-              this.techConditionChartRequireFinished = true
-              this.drawTechConditionChart()
-            }
-          })
-      },
-
-      /* 璋冪敤鎺ュ彛鑾峰彇璁惧鎶ヤ慨鏁呴殰 */
-      getWarrantyMalfunctionDataByApi() {
-        this.warrantyMalfunctionChart = this.$echarts.init(document.getElementById('warranty_malfunction_chart'))
         this.warrantyMalfunctionChart.showLoading({
           text: '鏁版嵁鍔犺浇涓� ...',
           color: '#0696e1', // 鍔犺浇鍔ㄧ敾棰滆壊
-          textColor: '#fff',
-          maskColor: 'rgba(1, 25, 75, 0.2)' // 閬僵灞�
+          textColor: 'rgba(0, 0, 0, .45)'
         })
-        signageApi.getReportRepairEquipmentListApi(this.productionCode)
+        signageApi.getEquipmentTechnologyStatusAndReportRepairEquipmentListApi(this.productionCode)
           .then(res => {
             if (res.success && res.result) {
-              this.warrantyMalfunctionData = [
-                { value: res.result[0].failurTotalCount, name: '鎶ヤ慨', isStop: '' },
-                { value: res.result[0].stopCount, name: '鍋滄満', isStop: '2' },
-                { value: res.result[0].noStopCount, name: '杩愯', isStop: '1' }
+              this.techConditionData = [
+                {
+                  value: res.result.jszt.length > 0 ? res.result.jszt.find(item => item.code === 'QUALIFIED').value : 0,
+                  name: '鍚堟牸',
+                  technologyStatus: 'QUALIFIED'
+                },
+                {
+                  value: res.result.jszt.length > 0 ? res.result.jszt.find(item => item.code === 'RESTRICTED').value : 0,
+                  name: '闄愮敤',
+                  technologyStatus: 'RESTRICTED'
+                },
+                {
+                  value: res.result.jszt.length > 0 ? res.result.jszt.find(item => item.code === 'PROHIBITED').value : 0,
+                  name: '绂佺敤',
+                  technologyStatus: 'PROHIBITED'
+                }
               ]
+              this.warrantyMalfunctionData = [
+                {
+                  value: res.result.bxqk.length > 0 ? res.result.bxqk.find(item => item.code === 'run').value : 0,
+                  name: '杩愯',
+                  code: 'run'
+                },
+                {
+                  value: res.result.bxqk.length > 0 ? res.result.bxqk.find(item => item.code === 'stop').value : 0,
+                  name: '鍋滄満',
+                  code: 'stop'
+                },
+                {
+                  value: res.result.bxqk.length > 0 ? res.result.bxqk.find(item => item.code === 'bx').value : 0,
+                  name: '鎶ヤ慨',
+                  code: 'bx'
+                }
+              ]
+              this.techConditionChartRequireFinished = true
               this.warrantyMalfunctionChartRequireFinished = true
+              this.drawTechConditionChart()
               this.drawWarrantyMalfunctionChart()
             }
           })
       },
 
       /* 璋冪敤鎺ュ彛鑾峰彇涓変繚璁″垝 */
-      getMonthMaintenanceNumByApi() {
-        signageApi.getThisMonthMaintenanceListApi(this.productionCode)
+      getThirdMaintenanceNumByApi() {
+        signageApi.getThirdMaintenanceConditionApi(this.productionCode)
           .then(res => {
-            if (res.success && res.result) this.thisMonthMaintenancePlanNum = res.result[0].totalCount
-          })
-        signageApi.getThisMonthMaintenanceFinishListApi(this.productionCode)
-          .then(res => {
-            if (res.success && res.result) this.thisMonthMaintenanceRealNum = res.result[0].totalCount
-          })
-        signageApi.getNextMonthMaintenanceList(this.productionCode)
-          .then(res => {
-            if (res.success && res.result) this.nextMonthMaintenancePlanNum = res.result[0].totalCount
-          })
-        signageApi.getNextNextMonthMaintenanceListApi(this.productionCode)
-          .then(res => {
-            if (res.success && res.result) this.nextNextMonthMaintenancePlanNum = res.result[0].totalCount
+            if (res.success && res.result) {
+              this.thisMonthMaintenancePlanNum = res.result.find(item => item.code === 'bysbzs').value
+              this.thisMonthMaintenanceRealNum = res.result.find(item => item.code === 'bwc').value
+              this.nextMonthMaintenancePlanNum = res.result.find(item => item.code === 'xysb').value
+              this.nextNextMonthMaintenancePlanNum = res.result.find(item => item.code === 'xxysb').value
+            }
           })
       },
 
@@ -285,8 +291,7 @@
         this.runningStateChart.showLoading({
           text: '鏁版嵁鍔犺浇涓� ...',
           color: '#0696e1', // 鍔犺浇鍔ㄧ敾棰滆壊
-          textColor: '#fff',
-          maskColor: 'rgba(1, 25, 75, 0.2)' // 閬僵灞�
+          textColor: 'rgba(0,0,0,.45)'
         })
         signageApi.getEquipmentStatusStatisticsApi(this.productionCode)
           .then(res => {
@@ -305,8 +310,7 @@
         this.first7DaysEfficiencyChart.showLoading({
           text: '鏁版嵁鍔犺浇涓� ...',
           color: '#0696e1', // 鍔犺浇鍔ㄧ敾棰滆壊
-          textColor: '#fff',
-          maskColor: 'rgba(1, 25, 75, 0.2)' // 閬僵灞�
+          textColor: 'rgba(0,0,0,.45)'
         })
         signageApi.getEquipmentDayUtilizationStatisticsApi(this.productionCode)
           .then(res => {
@@ -326,26 +330,22 @@
         this.gaugeChart1.showLoading({
           text: '鏁版嵁鍔犺浇涓� ...',
           color: '#0696e1', // 鍔犺浇鍔ㄧ敾棰滆壊
-          textColor: '#fff',
-          maskColor: 'rgba(1, 25, 75, 0.2)' // 閬僵灞�
+          textColor: 'rgba(0,0,0,.45)'
         })
         this.gaugeChart2.showLoading({
           text: '鏁版嵁鍔犺浇涓� ...',
           color: '#0696e1', // 鍔犺浇鍔ㄧ敾棰滆壊
-          textColor: '#fff',
-          maskColor: 'rgba(1, 25, 75, 0.2)' // 閬僵灞�
+          textColor: 'rgba(0,0,0,.45)'
         })
         this.gaugeChart3.showLoading({
           text: '鏁版嵁鍔犺浇涓� ...',
           color: '#0696e1', // 鍔犺浇鍔ㄧ敾棰滆壊
-          textColor: '#fff',
-          maskColor: 'rgba(1, 25, 75, 0.2)' // 閬僵灞�
+          textColor: 'rgba(0,0,0,.45)'
         })
         this.gaugeChart4.showLoading({
           text: '鏁版嵁鍔犺浇涓� ...',
           color: '#0696e1', // 鍔犺浇鍔ㄧ敾棰滆壊
-          textColor: '#fff',
-          maskColor: 'rgba(1, 25, 75, 0.2)' // 閬僵灞�
+          textColor: 'rgba(0,0,0,.45)'
         })
         signageApi.getEquipmentEfficiencyStatisticsApi(this.productionCode)
           .then(res => {
@@ -360,12 +360,51 @@
         this.barChart.showLoading({
           text: '鏁版嵁鍔犺浇涓� ...',
           color: '#0696e1', // 鍔犺浇鍔ㄧ敾棰滆壊
-          textColor: '#fff',
-          maskColor: 'rgba(1, 25, 75, 0.2)' // 閬僵灞�
+          textColor: 'rgba(0,0,0,.45)'
         })
         signageApi.getEquipmentOEEMonthStatisticsApi(this.productionCode)
           .then(res => {
-            if (res.success && res.result && res.result.length > 0) {
+            if (res.success && res.result) {
+              const res = {
+                result: [
+                  {
+                    equipmentId: '2140311',
+                    overallEquipmentEfficiency: 12
+                  },
+                  {
+                    equipmentId: '2140511',
+                    overallEquipmentEfficiency: 32
+                  },
+                  {
+                    equipmentId: '2420011',
+                    overallEquipmentEfficiency: 15
+                  },
+                  {
+                    equipmentId: '2140023',
+                    overallEquipmentEfficiency: 62
+                  },
+                  {
+                    equipmentId: '2110011',
+                    overallEquipmentEfficiency: 46
+                  },
+                  {
+                    equipmentId: '2140211',
+                    overallEquipmentEfficiency: 75
+                  },
+                  {
+                    equipmentId: '2144011',
+                    overallEquipmentEfficiency: 86
+                  },
+                  {
+                    equipmentId: '2140021',
+                    overallEquipmentEfficiency: 97
+                  },
+                  {
+                    equipmentId: '2145031',
+                    overallEquipmentEfficiency: 57
+                  }
+                ]
+              }
               this.barChartData = res.result.map(item => {
                 return {
                   name: item.equipmentId,
@@ -374,7 +413,6 @@
               })
               this.drawBarChart()
             }
-
           })
       },
 
@@ -404,17 +442,15 @@
             top: 'bottom',
             orient: 'horizontal',
             right: 0,
-            // bottom: "0",
             itemWidth: 14,
             itemHeight: 14,
             icon: 'roundRect',
             itemGap: 15,
             textStyle: {
-              color: 'inherit',
-              fontSize: 14,
-              padding: [0, 0, 0, 0]
+              color: 'rgba(0,0,0,.45)',
+              fontSize: 14
             },
-            data: ['鍚堟牸', '绂佺敤', '闄愮敤']
+            data: ['鍚堟牸', '闄愮敤', '绂佺敤']
           },
           grid: {
             containLabel: true
@@ -422,20 +458,17 @@
           series: [
             {
               type: 'pie',
-              // selectedMode: "single",
               radius: this.pieChartRadius,
               center: ['50%', '50%'],
               color: [
-                '#0FC61A',
-                '#F56436',
-                '#8B8B8B'
+                '#0AA012',
+                '#247F49',
+                '#757160'
               ],
               label: {
                 position: 'outside',
                 show: true,
-                color: 'inherit',
-                // textBorderColor: 'inherit',
-                // textBorderWidth: 1,
+                color: 'rgba(0,0,0,.45)',
                 fontSize: 16,
                 formatter: function(params) {
                   if (params.name !== '') {
@@ -446,7 +479,10 @@
               labelLine: {
                 show: true,
                 length2: 15,
-                length: 15
+                length: 15,
+                lineStyle: {
+                  color: 'rgba(0,0,0,.45)'
+                }
               },
               data: this.techConditionData
             }
@@ -466,12 +502,12 @@
         })
       },
 
-      /* 缁樺埗璁惧鎶ヤ慨鏁呴殰楗煎浘 */
+      /* 缁樺埗璁惧鎶ヤ慨鏁呴殰鎯呭喌楗煎浘 */
       drawWarrantyMalfunctionChart() {
         const option = {
           title: {
             show: true, // 鏄惁鏄剧ず鏍囬锛岄粯璁や负true
-            text: '璁惧鎶ヤ慨鏁呴殰', // 涓绘爣棰樻枃鏈�
+            text: '璁惧鎶ヤ慨鏁呴殰鎯呭喌', // 涓绘爣棰樻枃鏈�
             x: 'left', // 鏍囬姘村钩瀹夋斁浣嶇疆锛屽彲閫夊�间负'left'銆�'center'銆�'right'鎴栧叿浣撶殑姘村钩鍧愭爣鍊�
             y: 'top', // 鏍囬鍨傜洿瀹夋斁浣嶇疆锛屽彲閫夊�间负'top'銆�'bottom'銆�'center'鎴栧叿浣撶殑鍨傜洿鍧愭爣鍊�
             textStyle: {
@@ -492,15 +528,13 @@
             top: 'bottom',
             orient: 'horizontal',
             right: 0,
-            // bottom: "0",
             itemWidth: 14,
             itemHeight: 14,
             icon: 'roundRect',
             itemGap: 15,
             textStyle: {
-              color: 'inherit',
-              fontSize: 14,
-              padding: [0, 0, 0, 0]
+              color: 'rgba(0,0,0,.45)',
+              fontSize: 14
             },
             data: ['鎶ヤ慨', '鍋滄満', '杩愯']
           },
@@ -510,20 +544,17 @@
           series: [
             {
               type: 'pie',
-              // selectedMode: "single",
               radius: this.pieChartRadius,
               center: ['50%', '50%'],
               color: [
-                '#24F2F5',
-                '#F56436',
-                '#FFFF40'
+                '#00CED1',
+                '#B85B38',
+                '#FFFF88'
               ],
               label: {
                 position: 'outside',
                 show: true,
-                color: 'inherit',
-                // textBorderColor: 'inherit',
-                // textBorderWidth: 1,
+                color: 'rgba(0,0,0,.45)',
                 fontSize: 16,
                 formatter: function(params) {
                   if (params.name !== '') {
@@ -534,7 +565,10 @@
               labelLine: {
                 show: true,
                 length2: 15,
-                length: 15
+                length: 15,
+                lineStyle: {
+                  color: 'rgba(0,0,0,.45)'
+                }
               },
               data: this.warrantyMalfunctionData
             }
@@ -559,7 +593,7 @@
         const option = {
           title: {
             show: true, // 鏄惁鏄剧ず鏍囬锛岄粯璁や负true
-            text: '璁惧鐘舵��', // 涓绘爣棰樻枃鏈�
+            text: '璁惧杩愯鐘舵�佺粺璁�', // 涓绘爣棰樻枃鏈�
             x: 'left', // 鏍囬姘村钩瀹夋斁浣嶇疆锛屽彲閫夊�间负'left'銆�'center'銆�'right'鎴栧叿浣撶殑姘村钩鍧愭爣鍊�
             y: 'top', // 鏍囬鍨傜洿瀹夋斁浣嶇疆锛屽彲閫夊�间负'top'銆�'bottom'銆�'center'鎴栧叿浣撶殑鍨傜洿鍧愭爣鍊�
             textStyle: {
@@ -580,17 +614,15 @@
             top: 'bottom',
             orient: 'horizontal',
             right: 0,
-            // bottom: "0",
             itemWidth: 14,
             itemHeight: 14,
             icon: 'roundRect',
             itemGap: 15,
             textStyle: {
-              color: 'inherit',
-              fontSize: 14,
-              padding: [0, 0, 0, 0]
+              color: 'rgba(0,0,0,.45)',
+              fontSize: 14
             },
-            data: ['鍏虫満', '鎶ヨ', '寰呮満', '杩愯']
+            data: ['杩愯', '寰呮満', '鎶ヨ', '鍏虫満']
           },
           grid: {
             containLabel: true
@@ -599,22 +631,19 @@
             {
               type: 'pie',
               roseType: 'angle', // 鐜懓鍥�
-              // selectedMode: "single",
               radius: this.pieChartRadius,
               center: ['50%', '50%'],
               color: [
-                '#8B8B8B',
-                '#F56436',
-                '#FFFF40',
-                '#0FC61A'
+                '#686869',
+                '#AA6349',
+                '#FFFF88',
+                '#5D975D'
               ],
               label: {
                 position: 'outside',
                 show: true,
-                color: 'inherit',
-                // textBorderColor: 'inherit',
-                // textBorderWidth: 1,
-                fontSize: 30,
+                color: 'rgba(0,0,0,.45)',
+                fontSize: 16,
                 formatter: function(params) {
                   if (params.name !== '') {
                     return `${params.name}:${params.value}`
@@ -624,7 +653,10 @@
               labelLine: {
                 show: true,
                 length2: 20,
-                length: 30
+                length: 30,
+                lineStyle: {
+                  color: 'rgba(0,0,0,.45)'
+                }
               },
               data: this.runningStateData
             }
@@ -648,9 +680,9 @@
             const equipmentIdObj = {
               equipmentId: item.equipmentId,
               equipmentName: item.equipmentName,
-              openRate: 0,
-              startRate: 0,
-              utilizationRate: 0
+              openRate: 84,
+              startRate: 70,
+              utilizationRate: 42
             }
             this.first7DaysEfficiencyData.dataList.push(equipmentIdObj)
           }
@@ -671,22 +703,22 @@
               name: '寮�鏈虹巼',
               value: this.first7DaysEfficiencyData.dataList.map(item => item.openRate)
             }
-          ],
-          yAxisName: '鍓�7澶㏕EEP(%)'
+          ]
         }
         let legendData = []
         let seriesData = []
-        let colorArr = ['#A7F0C1', '#FAE893', '#66DFE2']
+        let colorArr = ['#1890FF', '#2EC35C', '#EA967B']
         legendData = newData.yAxis.map((item) => item.name)
         seriesData = newData.yAxis.map((item1, index1) => {
           return {
             name: item1.name,
             type: 'bar',
             symbol: 'circle',
+            barGap: '0%',
             symbolSize: 8,
             itemStyle: {
               color: colorArr[index1],
-              barBorderRadius: 100
+              barBorderRadius: 4
             },
             lineStyle: {
               width: 2
@@ -695,10 +727,35 @@
               show: true
             },
             yAxisIndex: 1,
-            data: item1.value // 鎶樼嚎鍥剧殑鏁版嵁
+            data: item1.value,// 鎶樼嚎鍥剧殑鏁版嵁
+            label: {
+              show: true,
+              lineHeight: 10,
+              formatter: params => {
+                if (+params.value === 0) return ''
+                else return params.value
+              },
+              position: index1 % 2 === 0 ? 'top' : 'inside',
+              textStyle: {
+                color: 'rgba(0,0,0,.45)',
+                fontSize: 10
+              }
+            }
           }
         })
         const option = {
+          title: {
+            show: true, // 鏄惁鏄剧ず鏍囬锛岄粯璁や负true
+            text: '鍓�7澶㏕EEP(%)', // 涓绘爣棰樻枃鏈�
+            x: 'left', // 鏍囬姘村钩瀹夋斁浣嶇疆锛屽彲閫夊�间负'left'銆�'center'銆�'right'鎴栧叿浣撶殑姘村钩鍧愭爣鍊�
+            y: 'top', // 鏍囬鍨傜洿瀹夋斁浣嶇疆锛屽彲閫夊�间负'top'銆�'bottom'銆�'center'鎴栧叿浣撶殑鍨傜洿鍧愭爣鍊�
+            textStyle: {
+              // 涓绘爣棰樻枃鏈牱寮�
+              fontSize: 18,
+              fontWeight: 'normal',
+              color: '#1AD8DE'
+            }
+          },
           grid: {
             containLabel: true,
             bottom: '1%',
@@ -730,7 +787,7 @@
             itemGap: 10,
             textStyle: {
               fontSize: 14,
-              color: '#fff'
+              color: 'rgba(0,0,0,.45)'
             }
           },
           xAxis: {
@@ -739,13 +796,13 @@
               interval: 0,
               show: true,
               fontSize: 14,
-              color: '#fff'
-              // rotate: -30,
+              margin: 10,
+              color: 'rgba(0,0,0,.45)'
             },
             axisLine: {
               show: true,
               lineStyle: {
-                color: '#fff'
+                color: 'rgba(0,0,0,.45)'
               }
             },
             axisTick: {
@@ -758,8 +815,7 @@
               name: newData.yAxisName,
               nameTextStyle: {
                 color: '#1AD8DE',
-                fontSize: 18,
-                padding: [0, 0, 0, 110]
+                fontSize: 18
               },
               nameGap: 30,
               type: 'value',
@@ -767,17 +823,14 @@
               axisLine: {
                 show: true,
                 lineStyle: {
-                  color: '#fff'
+                  color: 'rgba(0,0,0,.45)'
                 }
               },
               axisTick: {
                 show: false
               },
               splitLine: {
-                show: false,
-                lineStyle: {
-                  color: '#fff'
-                }
+                show: false
               }
             },
             {
@@ -787,23 +840,20 @@
               max: 100,
               axisLabel: {
                 show: true,
-                color: '#fff',
+                color: 'rgba(0,0,0,.45)',
                 fontSize: 14
               },
               axisLine: {
                 show: true,
                 lineStyle: {
-                  color: '#fff'
+                  color: 'rgba(0,0,0,.45)'
                 }
               },
               axisTick: {
                 show: true
               },
               splitLine: {
-                show: false,
-                lineStyle: {
-                  color: '#fff'
-                }
+                show: false
               }
             }
           ],
@@ -813,15 +863,6 @@
             startValue: 0, // 浠庡ご寮�濮嬨��
             endValue: 6 // 涓�娆℃�у睍绀哄嚑涓�
           }
-          // toolbox: {
-          //   show: true,
-          //   feature: {
-          //     mark: { show: true },
-          //     magicType: { show: true, type: ['line', 'bar'] },
-          //     restore: { show: true },
-          //     saveAsImage: { show: true, name: '鍓�7澶╁埄鐢ㄧ巼缁熻鍥�', pixelRatio: 1 }
-          //   }
-          // }
         }
         this.first7DaysEfficiencyChart.setOption(option, true)
         this.first7DaysEfficiencyChart.hideLoading()
@@ -841,6 +882,7 @@
         // 璁惧鍒楄〃澶т簬7涓椂寮�鍚嚜鍔ㄨ疆鎾�
         if (this.first7DaysEfficiencyData.mdcEquipmentList.length <= 7) return
         this.first7DaysEfficiencyChartCarouselTime = setInterval(() => {
+          colorArr.push(colorArr.shift())
           newData.xAxis.push(newData.xAxis.shift())
           newData.yAxis.forEach(item => item.value.push(item.value.shift()))
           this.$nextTick(() => {
@@ -893,14 +935,14 @@
                 show: true,
                 length: 10,
                 lineStyle: {
-                  color: '#fff',
+                  color: 'rgba(0,0,0,.45)',
                   width: 2
                 }
               },
               axisTick: {
                 length: 5,
                 lineStyle: {
-                  color: '#fff',
+                  color: 'rgba(0,0,0,.45)',
                   width: 1
                 }
               },
@@ -1078,7 +1120,9 @@
       drawBarChart() {
         const defaultData = []
         const colorArray = ['#79CEAA', '#F589A2', '#6FBF9D', '#66DFE2', '#A7F0C1', '#FAE893', '#F7B7A0']
-        const dataMax = +this.barChartData.sort((x, y) => +y.value - +x.value)[0].value
+        let barTopColor = ['#EA967B', '#62AC75', '#32ACBF', '#7196CE']
+        let barBottomColor = ['#F8E18B', '#A8D07C', '#7BCAC5', '#8DCCEF']
+        const dataMax = this.barChartData.length > 0 ? +this.barChartData.sort((x, y) => +y.value - +x.value)[0].value : 0
         let yAxisMax
         if (dataMax === 0) yAxisMax = 1 // 鑻ユ暟鎹腑鏈�澶у�间负0锛屽垯灏嗚儗鏅粯璁ゅ�艰缃负1
         else yAxisMax = Math.ceil(dataMax / 5) * 5 // 璁剧疆鏌卞浘鑳屾櫙闃村奖榛樿鍊硷紝鎬濊矾涓烘暟鎹渶澶у�兼渶鎺ヨ繎鐨勮兘琚�5鏁撮櫎鐨勬暟瀛�
@@ -1116,31 +1160,26 @@
             left: '6%',
             right: '3%'
           },
-          xAxis: [
-            {
-              // name: '涓婁釜鏈圤EE',
-              // nameLocation: 'middle',
-              // nameGap: 40, // x杞磏ame涓庢í鍧愭爣杞寸嚎鐨勯棿璺�
-              type: 'category',
-              data: xAisData,
-              axisLine: {
-                lineStyle: {
-                  color: '#fff'
-                }
-              },
-              axisLabel: {
-                show: true, // 鏄惁鏄剧ず鍒诲害鏍囩锛岄粯璁ゆ樉绀�
-                interval: 0, // 鍧愭爣杞村埢搴︽爣绛剧殑鏄剧ず闂撮殧锛屽湪绫荤洰杞翠腑鏈夋晥锛涢粯璁や細閲囩敤鏍囩涓嶉噸鍙犵殑绛栫暐闂撮殧鏄剧ず鏍囩锛涘彲浠ヨ缃垚0寮哄埗鏄剧ず鎵�鏈夋爣绛撅紱濡傛灉璁剧疆涓�1锛岃〃绀恒�庨殧涓�涓爣绛炬樉绀轰竴涓爣绛俱�忥紝濡傛灉鍊间负2锛岃〃绀洪殧涓や釜鏍囩鏄剧ず涓�涓爣绛撅紝浠ユ绫绘帹銆�
-                // rotate: this.barChartData.length >= 5 ? -30 : 0, // 鍒诲害鏍囩鏃嬭浆鐨勮搴︼紝鍦ㄧ被鐩酱鐨勭被鐩爣绛炬樉绀轰笉涓嬬殑鏃跺�欏彲浠ラ�氳繃鏃嬭浆闃叉鏍囩涔嬮棿閲嶅彔锛涙棆杞殑瑙掑害浠�-90搴﹀埌90搴�
-                inside: false, // 鍒诲害鏍囩鏄惁鏈濆唴锛岄粯璁ゆ湞澶�
-                margin: 6, // 鍒诲害鏍囩涓庤酱绾夸箣闂寸殑璺濈
-                fontSize: 14
-              },
-              axisTick: {
-                show: true,
-                alignWithLabel: true
+          xAxis: {
+            type: 'category',
+            data: xAisData,
+            axisLine: {
+              lineStyle: {
+                color: 'rgba(0,0,0,.45)'
               }
-            }],
+            },
+            axisLabel: {
+              show: true, // 鏄惁鏄剧ず鍒诲害鏍囩锛岄粯璁ゆ樉绀�
+              interval: 0, // 鍧愭爣杞村埢搴︽爣绛剧殑鏄剧ず闂撮殧锛屽湪绫荤洰杞翠腑鏈夋晥锛涢粯璁や細閲囩敤鏍囩涓嶉噸鍙犵殑绛栫暐闂撮殧鏄剧ず鏍囩锛涘彲浠ヨ缃垚0寮哄埗鏄剧ず鎵�鏈夋爣绛撅紱濡傛灉璁剧疆涓�1锛岃〃绀恒�庨殧涓�涓爣绛炬樉绀轰竴涓爣绛俱�忥紝濡傛灉鍊间负2锛岃〃绀洪殧涓や釜鏍囩鏄剧ず涓�涓爣绛撅紝浠ユ绫绘帹銆�
+              inside: false, // 鍒诲害鏍囩鏄惁鏈濆唴锛岄粯璁ゆ湞澶�
+              margin: 10, // 鍒诲害鏍囩涓庤酱绾夸箣闂寸殑璺濈
+              fontSize: 14
+            },
+            axisTick: {
+              show: true,
+              alignWithLabel: true
+            }
+          },
           yAxis: [
             {
               name: '%',
@@ -1150,7 +1189,7 @@
               position: 'left',
               axisLabel: {
                 formatter: '{value}',
-                color: '#fff',
+                color: 'rgba(0,0,0,.45)',
                 fontSize: 14
               },
               axisTick: {
@@ -1159,14 +1198,11 @@
               axisLine: {
                 show: true,
                 lineStyle: {
-                  color: '#fff'
+                  color: 'rgba(0,0,0,.45)'
                 }
               },
               splitLine: {
-                show: false,
-                lineStyle: {
-                  color: 'rgba(255,255,255,0.12)'
-                }
+                show: false
               }
             },
             {
@@ -1174,48 +1210,68 @@
               axisLine: {
                 show: true,
                 lineStyle: {
-                  color: '#fff'
+                  color: 'rgba(0,0,0,.45)'
                 }
               }
             }
           ],
-          series: [{
-            type: 'bar',
-            data: this.barChartData,
-            barWidth: this.barChartData.length > 5 ? '40%' : 30,
-            itemStyle: {
-              color: function(params) {
-                let num = colorArray.length
-                return colorArray[params.dataIndex % num]
-              },
-              barBorderRadius: 100
-            },
-            label: {
-              show: false,
-              lineHeight: 10,
-              formatter: params => {
-                if (+params.value === 0) return ''
-                else return params.value
-              },
-              position: 'inside',
-              textStyle: {
-                color: '#fff',
-                fontSize: 18
-              }
-            },
-            zlevel: 1
-          },
+          series: [
             {
-              name: '鑳屾櫙',
-              type: 'bar',
-              barWidth: this.barChartData.length > 5 ? '40%' : 30,
-              barGap: '-100%',
-              data: defaultData,
+              type: 'pictorialBar',
+              symbolSize: [26, 10],
+              symbolOffset: [0, -5],
+              z: 12,
               itemStyle: {
-                color: '#11294d',
-                barBorderRadius: 100
-              }
-            }],
+                color: function(params) {
+                  return barBottomColor[params.dataIndex % barBottomColor.length]
+                }
+              },
+              label: {
+                show: true,
+                position: 'top',
+                fontSize: 12,
+                color: 'rgba(0,0,0,.45)'
+              },
+              symbolPosition: 'end',
+              data: this.barChartData
+            },
+            {
+              type: 'pictorialBar',
+              symbolSize: [26, 10],
+              symbolOffset: [0, 5],
+              z: 12,
+              itemStyle: {
+                color: function(params) {
+                  return barTopColor[params.dataIndex % barTopColor.length]
+                }
+              },
+              data: this.barChartData
+            },
+            {
+              type: 'bar',
+              itemStyle: {
+                color: function(params) {
+                  return new echarts.graphic.LinearGradient(
+                    0, 0, 0, 1,
+                    [{
+                      offset: 1,
+                      color: barTopColor[params.dataIndex % barTopColor.length]
+                    },
+                      {
+                        offset: 0,
+                        color: barBottomColor[params.dataIndex % barBottomColor.length]
+                      }
+                    ]
+                  )
+                },
+                opacity: .9
+              },
+              z: 16,
+              barWidth: 26,
+              barGap: '-100%',
+              data: this.barChartData
+            }
+          ],
           dataZoom: {
             show: false,
             startValue: 0, // 浠庡ご寮�濮嬨��
@@ -1239,7 +1295,8 @@
         this.barChartCarouselTime = setInterval(() => {
           this.barChartData.push(this.barChartData.shift())
           xAisData.push(xAisData.shift())
-          colorArray.push(colorArray.shift())
+          barTopColor.push(barTopColor.shift())
+          barBottomColor.push(barBottomColor.shift())
           this.$nextTick(() => {
             this.barChart.setOption(option, true)
           })
@@ -1272,9 +1329,10 @@
       openMaintenanceModal(record) {
         this.modalTitle = record.planTime
         this.modalDataApiParams = {
-          productionCode: this.productionCode
+          productionCode: this.productionCode,
+          code: record.code
         }
-        this.modalDataApiUrl = record.apiUrl
+        this.modalDataApiUrl = '/eam/home/maintenanceList'
         this.modalVisible = true
       },
 
@@ -1314,15 +1372,6 @@
 
 <style lang="less" scoped>
   .page-container {
-    .page-title {
-      display: flex;
-      justify-content: space-evenly;
-      flex-wrap: wrap;
-      color: #fff;
-      margin-bottom: 10px;
-
-    }
-
     .content-container {
       padding-top: 5px;
       display: flex;
@@ -1352,7 +1401,7 @@
               .plan-value {
                 margin-right: 20px;
                 font-size: 30px;
-                color: #EAC910;
+                color: #fff;
               }
             }
           }
@@ -1374,7 +1423,7 @@
   }
 
   /deep/ .ant-form .ant-form-item-label label {
-    color: #fff;
+    color: rgba(0, 0, 0, .45);
     font-size: 18px;
   }
 
@@ -1384,16 +1433,16 @@
 
   /deep/ .ant-select-selection__clear {
     background: transparent !important;
-    color: #fff;
+    color: rgba(0, 0, 0, .45);
   }
 
   /deep/ .ant-select {
-    color: #fff;
+    color: rgba(0, 0, 0, .45);
   }
 
   /deep/ .ant-input {
-    border: 1px solid #689ACA;
-    color: #fff;
+    border: 1px solid rgba(0, 0, 0, .45);
+    color: rgba(0, 0, 0, .45);
     background: transparent !important;
   }
 </style>
\ No newline at end of file

--
Gitblit v1.9.3