| | |
| | | <a-descriptions-item label="工段"> |
| | | {{equipmentInfo.workShopName|equipmentInfoDisplay}} |
| | | </a-descriptions-item> |
| | | <a-descriptions-item label="操作工"> |
| | | {{operationCertificateInfo.realname|equipmentInfoDisplay}} |
| | | </a-descriptions-item> |
| | | <a-descriptions-item label="设备状态"> |
| | | {{equipmentInfo.equipmentStatus|equipmentInfoDisplay}} |
| | | </a-descriptions-item> |
| | |
| | | <dv-border-box-11 title="操作证信息" class="info-container" style="flex:2;"> |
| | | <a-descriptions :column="1"> |
| | | <a-descriptions-item label="操作证编号"> |
| | | {{operationCertificateInfo.num|equipmentInfoDisplay}} |
| | | <a-tooltip> |
| | | <template slot="title"> |
| | | {{operationCertificateInfo.num|equipmentInfoDisplay}} |
| | | </template> |
| | | {{operationCertificateInfo.num|equipmentInfoDisplay}} |
| | | </a-tooltip> |
| | | </a-descriptions-item> |
| | | <a-descriptions-item label="当前周期分数"> |
| | | {{operationCertificateInfo.currentCycleScore|equipmentInfoDisplay}} |
| | | </a-descriptions-item> |
| | | <a-descriptions-item label="发证日期"> |
| | | {{operationCertificateInfo.issueDate|equipmentInfoDisplay}} |
| | | <a-descriptions-item label="发证/截止日期"> |
| | | <a-tooltip> |
| | | <template slot="title" v-if="operationCertificateInfo.issueDate||operationCertificateInfo.endTime"> |
| | | {{operationCertificateInfo.issueDate|equipmentInfoDisplay}}/{{operationCertificateInfo.endTime|equipmentInfoDisplay}} |
| | | </template> |
| | | {{operationCertificateInfo.issueDate|equipmentInfoDisplay}}/{{operationCertificateInfo.endTime|equipmentInfoDisplay}} |
| | | </a-tooltip> |
| | | </a-descriptions-item> |
| | | <a-descriptions-item label="周期截止日期"> |
| | | {{operationCertificateInfo.endTime|equipmentInfoDisplay}} |
| | | <a-descriptions-item label="操作工"> |
| | | {{operationCertificateInfo.realname|equipmentInfoDisplay}} |
| | | </a-descriptions-item> |
| | | </a-descriptions> |
| | | </dv-border-box-11> |
| | |
| | | <dv-border-box-11 title="维护信息" class="info-container" style="flex:2;"> |
| | | <a-descriptions :column="1"> |
| | | <a-descriptions-item label="下次三保日期"> |
| | | {{equipmentInfo.nextThirdMaintenanceTime|equipmentInfoDisplay}} |
| | | <a-tooltip> |
| | | <template slot="title" v-if="equipmentInfo.nextThirdMaintenanceTime"> |
| | | {{equipmentInfo.nextThirdMaintenanceTime}} |
| | | </template> |
| | | {{equipmentInfo.nextThirdMaintenanceTime|equipmentInfoDisplay}} |
| | | </a-tooltip> |
| | | </a-descriptions-item> |
| | | <a-descriptions-item label="下次二保日期"> |
| | | {{equipmentInfo.nextSecondMaintenanceTime|equipmentInfoDisplay}} |
| | | <a-tooltip> |
| | | <template slot="title" v-if="equipmentInfo.nextSecondMaintenanceTime"> |
| | | {{equipmentInfo.nextSecondMaintenanceTime|equipmentInfoDisplay}} |
| | | </template> |
| | | {{equipmentInfo.nextSecondMaintenanceTime|equipmentInfoDisplay}} |
| | | </a-tooltip> |
| | | </a-descriptions-item> |
| | | <a-descriptions-item label="技术状态"> |
| | | {{equipmentInfo.technology_status|equipmentInfoDisplay}} |
| | |
| | | <div style="display: flex;justify-content:space-evenly;flex: 1"> |
| | | <div style="width: 45%;" class="info-card-container"> |
| | | <div class="info-card-title">本月报修次数</div> |
| | | <div class="info-card-value" style="color: #EAC910">{{equipmentInfo.repairCount|equipmentInfoDisplay}}</div> |
| | | <div class="info-card-value" style="color: #EAC910">{{equipmentInfo.repairCount|equipmentInfoDisplay}} |
| | | </div> |
| | | </div> |
| | | |
| | | <div style="width: 45%;" class="info-card-container"> |
| | |
| | | </dv-border-box-12> |
| | | </div> |
| | | </div> |
| | | |
| | | <SignageModal ref="modalRef" :modalVisible="modalVisible" :modalWidth="modalWidth" :modalTitle=modalTitle |
| | | :modalDataApiUrl="modalDataApiUrl" |
| | | :modalDataApiParams="modalDataApiParams" |
| | | @closeModal="modalVisible=false"/> |
| | | </div> |
| | | </template> |
| | | |
| | | <script> |
| | | import signageApi from '@/api/signage' |
| | | import moment from 'moment' |
| | | import SignageModal from './modules/SignageModal' |
| | | |
| | | export default { |
| | | name: 'EquipmentSignage', |
| | | components: { SignageModal }, |
| | | props: { |
| | | productionCode: { |
| | | type: String, |
| | |
| | | equipmentDetails: {}, |
| | | buttonList: [ |
| | | { |
| | | label: '备件信息' |
| | | label: '备件信息', |
| | | pageName: '', |
| | | modalDataApiUrl: '' |
| | | }, |
| | | { |
| | | label: '保养计划' |
| | | label: '保养计划', |
| | | pageName: '', |
| | | modalDataApiUrl: '/eam/equipment/list' |
| | | }, |
| | | { |
| | | label: '报修', |
| | | pageName: 'eam-MalfunctionRepair' |
| | | pageName: 'eam-MalfunctionRepair', |
| | | modalDataApiUrl: '' |
| | | }, |
| | | { |
| | | label: '设备班次', |
| | | pageName: 'mdc-base-DeviceCalendar' |
| | | pageName: 'mdc-base-DeviceCalendar', |
| | | modalDataApiUrl: '' |
| | | } |
| | | ], |
| | | lineChart: '', |
| | |
| | | }, |
| | | hideLoadingDelayTime: 500, |
| | | isDisplayEquipmentDetails: false, |
| | | isBelongToMdc: true// 是否在mdc设备表中 |
| | | isBelongToMdc: true,// 是否在mdc设备表中 |
| | | modalVisible: false, |
| | | modalWidth: 1048, |
| | | modalTitle: '', |
| | | modalDataApiUrl: '', |
| | | modalTableColumns: [], |
| | | modalDataApiParams: {} |
| | | } |
| | | }, |
| | | created() { |
| | |
| | | if (newVal) this.lineChartWidth = '40%' |
| | | else this.lineChartWidth = '65%' |
| | | this.$nextTick(() => { |
| | | this.lineChart.resize() |
| | | if (this.lineChart) this.lineChart.resize() |
| | | }) |
| | | } |
| | | }, |
| | | immediate: true |
| | | } |
| | | }, |
| | | methods: { |
| | |
| | | name: record.pageName, |
| | | params: { equipmentId: this.equipmentId } |
| | | }) |
| | | } else { |
| | | this.$refs.modalRef.modalTableColumns = [ |
| | | { |
| | | title: '#', |
| | | dataIndex: '', |
| | | key: 'rowIndex', |
| | | width: 60, |
| | | align: 'center', |
| | | customRender: function(t, r, index) { |
| | | return parseInt(index) + 1 |
| | | } |
| | | }, |
| | | { |
| | | width: 150, |
| | | align: 'center', |
| | | title: '设备编号', |
| | | dataIndex: 'num', |
| | | key: 'num' |
| | | }, |
| | | { |
| | | width: 200, |
| | | align: 'center', |
| | | title: '设备名称', |
| | | dataIndex: 'name', |
| | | key: 'name' |
| | | }, |
| | | { |
| | | width: 200, |
| | | align: 'center', |
| | | title: '设备型号', |
| | | dataIndex: 'model', |
| | | key: 'model' |
| | | }, |
| | | { |
| | | width: 250, |
| | | align: 'center', |
| | | title: '规格', |
| | | key: 'specification', |
| | | dataIndex: 'specification' |
| | | }, |
| | | { |
| | | width: 170, |
| | | align: 'center', |
| | | title: '下次二保时间', |
| | | key: 'nextSecondMaintenanceTime', |
| | | dataIndex: 'nextSecondMaintenanceTime' |
| | | }, |
| | | { |
| | | width: 170, |
| | | align: 'center', |
| | | title: '下次三保时间', |
| | | key: 'nextThirdMaintenanceTime', |
| | | dataIndex: 'nextThirdMaintenanceTime' |
| | | } |
| | | ] |
| | | this.modalWidth = 1248 |
| | | this.modalTitle = record.label |
| | | this.modalDataApiParams = { num: this.equipmentId } |
| | | this.modalDataApiUrl = record.modalDataApiUrl |
| | | this.modalVisible = true |
| | | } |
| | | }, |
| | | |
| | |
| | | // 主标题文本样式 |
| | | fontSize: 18, |
| | | fontWeight: 'normal', |
| | | color: '#1AD8DE', |
| | | color: '#1AD8DE' |
| | | } |
| | | }, |
| | | tooltip: { |
| | |
| | | /* 绘制利用率仪表盘图表 */ |
| | | drawGaugeChart1(opt) { |
| | | const option = Object.assign({}, opt) |
| | | option.title.text = moment().subtract(1, 'days').format('M月D日') + '利用率' |
| | | option.series[0].name = '利用率' |
| | | option.series[0].data = [this.gaugeChartData.utilizationRate] |
| | | this.gaugeChart1.setOption(option, true) |
| | | setTimeout(() => this.gaugeChart1.hideLoading(), this.hideLoadingDelayTime) |
| | | |
| | | signageApi.getGaugeColorByTypeApi('lyl') |
| | | .then(res => { |
| | | if (res.success) { |
| | | const colorRange = res.result.map(item => item = [+item.maximumRange / 100, item.rateParameterColor]) |
| | | option.series[0].axisLine.lineStyle.color = colorRange |
| | | } |
| | | }) |
| | | .finally(() => { |
| | | option.title.text = moment().subtract(1, 'days').format('M月D日') + 'TEEP' |
| | | option.series[0].name = 'TEEP' |
| | | option.series[0].data = [this.gaugeChartData.utilizationRate] |
| | | this.gaugeChart1.setOption(option, true) |
| | | setTimeout(() => this.gaugeChart1.hideLoading(), this.hideLoadingDelayTime) |
| | | }) |
| | | |
| | | this.gaugeChart1.getZr().on('click', params => { |
| | | // 仅有点击表盘区域才会有以下属性,topTarget表示触发事件对象,shape表示触发事件对象的图像属性,clockwise表示表盘是否以顺时针排列,默认为true |
| | |
| | | /* 绘制开动率仪表盘图表 */ |
| | | drawGaugeChart2(opt) { |
| | | const option = Object.assign({}, opt) |
| | | option.title.text = moment().subtract(1, 'days').format('M月D日') + '开动率' |
| | | option.series[0].name = '开动率' |
| | | option.series[0].data = [this.gaugeChartData.startRate] |
| | | this.gaugeChart2.setOption(option, true) |
| | | setTimeout(() => this.gaugeChart2.hideLoading(), this.hideLoadingDelayTime) |
| | | |
| | | signageApi.getGaugeColorByTypeApi('kdl') |
| | | .then(res => { |
| | | if (res.success) { |
| | | const colorRange = res.result.map(item => item = [+item.maximumRange / 100, item.rateParameterColor]) |
| | | option.series[0].axisLine.lineStyle.color = colorRange |
| | | } |
| | | }) |
| | | .finally(() => { |
| | | option.title.text = moment().subtract(1, 'days').format('M月D日') + '开动率' |
| | | option.series[0].name = '开动率' |
| | | option.series[0].data = [this.gaugeChartData.startRate] |
| | | this.gaugeChart2.setOption(option, true) |
| | | setTimeout(() => this.gaugeChart2.hideLoading(), this.hideLoadingDelayTime) |
| | | }) |
| | | |
| | | this.gaugeChart2.getZr().on('click', params => { |
| | | // 仅有点击表盘区域才会有以下属性,topTarget表示触发事件对象,shape表示触发事件对象的图像属性,clockwise表示表盘是否以顺时针排列,默认为true |
| | |
| | | /* 绘制开机率仪表盘图表 */ |
| | | drawGaugeChart3(opt) { |
| | | const option = Object.assign({}, opt) |
| | | option.title.text = moment().subtract(1, 'days').format('M月D日') + '开机率' |
| | | option.series[0].name = '开机率' |
| | | option.series[0].data = [this.gaugeChartData.openRate] |
| | | this.gaugeChart3.setOption(option, true) |
| | | setTimeout(() => this.gaugeChart3.hideLoading(), this.hideLoadingDelayTime) |
| | | |
| | | signageApi.getGaugeColorByTypeApi('kdl') |
| | | .then(res => { |
| | | if (res.success) { |
| | | const colorRange = res.result.map(item => item = [+item.maximumRange / 100, item.rateParameterColor]) |
| | | option.series[0].axisLine.lineStyle.color = colorRange |
| | | } |
| | | }) |
| | | .finally(() => { |
| | | option.title.text = moment().subtract(1, 'days').format('M月D日') + '开机率' |
| | | option.series[0].name = '开机率' |
| | | option.series[0].data = [this.gaugeChartData.openRate] |
| | | this.gaugeChart3.setOption(option, true) |
| | | setTimeout(() => this.gaugeChart3.hideLoading(), this.hideLoadingDelayTime) |
| | | }) |
| | | |
| | | this.gaugeChart3.getZr().on('click', params => { |
| | | // 仅有点击表盘区域才会有以下属性,topTarget表示触发事件对象,shape表示触发事件对象的图像属性,clockwise表示表盘是否以顺时针排列,默认为true |
| | |
| | | /* 绘制OEE仪表盘图表 */ |
| | | drawGaugeChart4(opt) { |
| | | const option = Object.assign({}, opt) |
| | | option.title.text = moment().subtract(1, 'months').format('M月') + `OEE` |
| | | option.series[0].name = 'OEE' |
| | | option.series[0].data = [this.gaugeChartData.overallEquipmentEfficiency] |
| | | this.gaugeChart4.setOption(option, true) |
| | | setTimeout(() => this.gaugeChart4.hideLoading(), this.hideLoadingDelayTime) |
| | | |
| | | signageApi.getGaugeColorByTypeApi('lyl') |
| | | .then(res => { |
| | | if (res.success) { |
| | | const colorRange = res.result.map(item => item = [+item.maximumRange / 100, item.rateParameterColor]) |
| | | option.series[0].axisLine.lineStyle.color = colorRange |
| | | } |
| | | }) |
| | | .finally(() => { |
| | | option.title.text = moment().subtract(1, 'months').format('M月') + `OEE` |
| | | option.series[0].name = 'OEE' |
| | | option.series[0].data = [this.gaugeChartData.overallEquipmentEfficiency] |
| | | this.gaugeChart4.setOption(option, true) |
| | | setTimeout(() => this.gaugeChart4.hideLoading(), this.hideLoadingDelayTime) |
| | | }) |
| | | |
| | | this.gaugeChart4.getZr().on('click', params => { |
| | | // 仅有点击表盘区域才会有以下属性,topTarget表示触发事件对象,shape表示触发事件对象的图像属性,clockwise表示表盘是否以顺时针排列,默认为true |
| | |
| | | xAxis: this.lineChartData.dateList, |
| | | yAxis: [ |
| | | { |
| | | name: '利用率', |
| | | name: 'TEEP', |
| | | value: this.lineChartData.dataList.map(item => item.utilizationRate) |
| | | }, |
| | | { |
| | |
| | | value: this.lineChartData.dataList.map(item => item.overallEquipmentEfficiency) |
| | | } |
| | | ], |
| | | yAxisName: '整年度利用率(%)' |
| | | yAxisName: '整年度TEEP(%)' |
| | | } |
| | | let legendData = [] |
| | | let seriesData = [] |
| | |
| | | symbolSize: 8, |
| | | itemStyle: { |
| | | color: colorArr[index1] |
| | | }, |
| | | label: { |
| | | show: true, |
| | | position: 'top', |
| | | textStyle: { |
| | | color: 'inherit' |
| | | } |
| | | }, |
| | | lineStyle: { |
| | | width: 2 |
| | |
| | | axisLabel: { |
| | | interval: 0, |
| | | show: true, |
| | | fontSize: 12, |
| | | fontSize: 14, |
| | | color: '#fff' |
| | | // rotate: -30, |
| | | }, |
| | |
| | | nameTextStyle: { |
| | | color: '#1AD8DE', |
| | | fontSize: 18, |
| | | padding: [0, 0, 0, 110] |
| | | padding: [0, 0, 0, 120] |
| | | }, |
| | | nameGap: 25, |
| | | type: 'value', |
| | |
| | | }, |
| | | { |
| | | type: 'value', |
| | | position: 'right', |
| | | position: 'left', |
| | | splitNumber: 5, |
| | | max: 100, |
| | | axisLabel: { |
| | | show: true, |
| | | color: '#fff' |
| | | color: '#fff', |
| | | fontSize:14 |
| | | }, |
| | | axisLine: { |
| | | show: true, |
| | |
| | | padding-bottom: 25px; |
| | | white-space: nowrap; |
| | | overflow: hidden; |
| | | -ms-text-overflow: ellipsis; |
| | | text-overflow: ellipsis; |
| | | } |
| | | |
| | | /deep/ .ant-descriptions-item-label, /deep/ .ant-descriptions-item-content { |