From d50523911eaf8fa309eb842522ee9e7a4782e505 Mon Sep 17 00:00:00 2001 From: zhuzhuanzhuan Date: 星期五, 23 二月 2024 17:06:07 +0800 Subject: [PATCH] 设备利用率、设备开动率以及班次利用率页面增加按照驱动类型查询数据功能 --- src/views/mdc/base/modules/OEEAnalysis/OEEAnalysisList.vue | 36 ++++++++++++++++++------------------ 1 files changed, 18 insertions(+), 18 deletions(-) diff --git a/src/views/mdc/base/modules/OEEAnalysis/OEEAnalysisList.vue b/src/views/mdc/base/modules/OEEAnalysis/OEEAnalysisList.vue index e9fec71..38aced3 100644 --- a/src/views/mdc/base/modules/OEEAnalysis/OEEAnalysisList.vue +++ b/src/views/mdc/base/modules/OEEAnalysis/OEEAnalysisList.vue @@ -23,6 +23,7 @@ :value="dates" :mode="['month', 'month']" @panelChange="dateParamChange" + @change="handleDateChange" /> </a-form-item> </a-col> @@ -40,7 +41,7 @@ </div> <div id="EfficiencyShift" style="flex:1;overflow: hidden"> - <a-table :columns="columns" rowKey="equipmentId" :dataSource="dataSource.records" :pagination="false" :scroll="{x:'max-content',y:scrollY}" bordered></a-table> + <a-table :columns="columns" rowKey="id" :dataSource="dataSource.records" :pagination="false" :scroll="{x:'max-content',y:scrollY}" bordered></a-table> </div> <!--<div class="pagination">--> <!--<a-pagination--> @@ -329,11 +330,19 @@ }, methods: { dateParamChange(value) { + console.log('dateParamChangeValue',value) this.dates = value this.queryParam.startTime = moment(this.dates[0]).format('YYYY-MM') this.queryParam.endTime = moment(this.dates[1]).format('YYYY-MM') }, - + handleDateChange(value){ + console.log('handleDateChangeValue',value) + if(!value.length) { + delete this.queryParam.startTime + delete this.queryParam.endTime + this.dates = [] + } + }, initShiftList() { getAction(this.url.initShiftList).then((res) => { if (res.success) { @@ -373,24 +382,15 @@ }, searchQuery() { - if (this.dates != '') { - if (this.queryParam.typeTree == '1') { - this.queryParam.parentId = this.queryParamEquip.parentId - this.queryParam.equipmentId = this.queryParamEquip.equipmentId - } else { - this.queryParam.parentId = this.queryParamPeople.parentId - this.queryParam.equipmentId = '' - } - this.queryParam.pageNo = 1 - this.loadData() + if (this.queryParam.typeTree == '1') { + this.queryParam.parentId = this.queryParamEquip.parentId + this.queryParam.equipmentId = this.queryParamEquip.equipmentId } else { - // this.$message.warning("璇烽�夋嫨鏃堕棿") - this.$notification.warning({ - message: '娑堟伅', - description: '璇烽�夋嫨鏃堕棿' - }) + this.queryParam.parentId = this.queryParamPeople.parentId + this.queryParam.equipmentId = '' } - // this.onClearSelected() + this.queryParam.pageNo = 1 + this.loadData() }, searchReset() { -- Gitblit v1.9.3