NEZ-1077 fix: panel 输入搜索条件 ,没有符合条件chart nodata样式
This commit is contained in:
@@ -263,7 +263,7 @@
|
||||
</div>
|
||||
</draggable>
|
||||
<!-- <el-row v-if="dataList.length === 0" class="noData"></el-row>-->
|
||||
<div v-if="panelLoading" class="no-data">
|
||||
<div v-if="chartListNoData" class="no-data">
|
||||
<svg class="icon" aria-hidden="true">
|
||||
<use xlink:href="#nz-icon-no-data-panel"></use>
|
||||
</svg>
|
||||
@@ -304,7 +304,7 @@ export default {
|
||||
obj: Object,
|
||||
panelLock: { type: Boolean, default: false },
|
||||
hasGroup: { type: Boolean, default: true },
|
||||
panelDataList: Array,
|
||||
panelDataList: Array
|
||||
},
|
||||
|
||||
components: {
|
||||
@@ -333,7 +333,7 @@ export default {
|
||||
start: '',
|
||||
end: ''
|
||||
},
|
||||
panelLoading: false,
|
||||
chartListNoData: false,
|
||||
extraMarginBottom: 0, // dom额外的margin
|
||||
panelId: '',
|
||||
timer: null,
|
||||
@@ -548,13 +548,20 @@ export default {
|
||||
this.dataTotalListBak.forEach((item) => {
|
||||
item.isLoaded = false
|
||||
item.isHide = false
|
||||
this.chartListNoData = false
|
||||
chartListTmp.push(item)
|
||||
})
|
||||
}
|
||||
|
||||
this.dataTotalList = [...chartListTmp]
|
||||
this.dataList = [...this.dataTotalList]
|
||||
|
||||
let isAllHide = true
|
||||
this.dataList.map(item => {
|
||||
if (!item.isHide) {
|
||||
isAllHide = false
|
||||
}
|
||||
})
|
||||
this.chartListNoData = isAllHide
|
||||
this.$nextTick(() => {
|
||||
if (this.dataList.length > 0) {
|
||||
this.dataList.forEach((item, index) => {
|
||||
@@ -719,10 +726,10 @@ export default {
|
||||
// chart数据存在dataTotalListBak中
|
||||
if (response.data.list.length > 0) {
|
||||
this.dataTotalListBak = response.data.list
|
||||
this.panelLoading = false
|
||||
this.chartListNoData = false
|
||||
} else {
|
||||
this.dataTotalListBak = response.data
|
||||
this.panelLoading = true
|
||||
this.chartListNoData = true
|
||||
}
|
||||
let chartListTmp = []
|
||||
// 查询条件带name
|
||||
|
||||
@@ -23,8 +23,8 @@
|
||||
</pick-time>
|
||||
</template>
|
||||
<template v-slot>
|
||||
<log-tab ref="logDetail" v-loading="loading" :log-data="logData" :tab-index="9" @exportLog="exportLog" @limitChange="queryLogData"></log-tab>
|
||||
<div v-loading="loading" v-if="!logData" style="height: 300px; width: 100%; display: flex; justify-content: center; align-items: center; color: #999;">No Data</div>
|
||||
<log-tab ref="logDetail" v-loading="loading" :loading="loading" :log-data="logData" :tab-index="9" @exportLog="exportLog" @limitChange="queryLogData"></log-tab>
|
||||
<!-- <div v-loading="loading" v-if="!logData" style="height: 300px; width: 100%; display: flex; justify-content: center; align-items: center; color: #999;">No Data</div>-->
|
||||
</template>
|
||||
</nz-bottom-data-list>
|
||||
</template>
|
||||
|
||||
@@ -32,6 +32,7 @@
|
||||
:height="mainTableHeight"
|
||||
:now-time="nowTime"
|
||||
:table-data="tableData"
|
||||
:loading="tools.loading"
|
||||
@del="del"
|
||||
@edit="edit"
|
||||
@showText="showText"
|
||||
|
||||
@@ -111,6 +111,7 @@
|
||||
<alert-rule-table
|
||||
ref="dataTable"
|
||||
v-loading="tools.loading"
|
||||
:loading="tools.loading"
|
||||
:api="url"
|
||||
:custom-table-title="tools.customTableTitle"
|
||||
:height="mainTableHeight"
|
||||
|
||||
@@ -20,6 +20,7 @@
|
||||
<alert-silence-table
|
||||
ref="dataTable"
|
||||
v-loading="tools.loading"
|
||||
:loading="tools.loading"
|
||||
:api="url"
|
||||
:custom-table-title="tools.customTableTitle"
|
||||
:height="mainTableHeight"
|
||||
|
||||
@@ -44,6 +44,7 @@
|
||||
ref="dataDetail"
|
||||
:orderByFa="orderBy"
|
||||
v-loading="tools.loading"
|
||||
:loading="tools.loading"
|
||||
:detailViewRightObj="detailViewRightObj"
|
||||
:api="url"
|
||||
:table-data="tableData"
|
||||
|
||||
@@ -98,13 +98,14 @@
|
||||
</template>
|
||||
</div>
|
||||
</el-table-column>
|
||||
<template v-if="!loading" slot="empty">
|
||||
<div class="right-no-data">
|
||||
<template slot="empty">
|
||||
<div v-if="!loading" class="right-no-data">
|
||||
<svg class="icon" aria-hidden="true">
|
||||
<use xlink:href="#nz-icon-no-data-list"></use>
|
||||
</svg>
|
||||
<div style="font-size: 16px;color: #333333;font-weight: 400;">No results found</div>
|
||||
</div>
|
||||
<div v-else> </div>
|
||||
</template>
|
||||
</el-table>
|
||||
</template>
|
||||
|
||||
@@ -77,13 +77,14 @@
|
||||
</template>
|
||||
</div>
|
||||
</el-table-column>
|
||||
<template v-if="!loading" slot="empty">
|
||||
<div class="right-no-data">
|
||||
<template slot="empty">
|
||||
<div v-if="!loading" class="right-no-data">
|
||||
<svg class="icon" aria-hidden="true">
|
||||
<use xlink:href="#nz-icon-no-data-list"></use>
|
||||
</svg>
|
||||
<div style="font-size: 16px;color: #333333;font-weight: 400;">No results found</div>
|
||||
</div>
|
||||
<div v-else> </div>
|
||||
</template>
|
||||
</el-table>
|
||||
</template>
|
||||
|
||||
@@ -87,13 +87,14 @@
|
||||
</template>
|
||||
</div>
|
||||
</el-table-column>
|
||||
<template v-if="!loading" slot="empty">
|
||||
<div class="right-no-data">
|
||||
<template slot="empty">
|
||||
<div v-if="!loading" class="right-no-data">
|
||||
<svg class="icon" aria-hidden="true">
|
||||
<use xlink:href="#nz-icon-no-data-list"></use>
|
||||
</svg>
|
||||
<div style="font-size: 16px;color: #333333;font-weight: 400;">No results found</div>
|
||||
</div>
|
||||
<div v-else> </div>
|
||||
</template>
|
||||
</el-table>
|
||||
</template>
|
||||
|
||||
@@ -68,6 +68,7 @@
|
||||
<chartTmplTable
|
||||
ref="dataTable"
|
||||
v-loading="tools.loading"
|
||||
:loading="tools.loading"
|
||||
:api="url"
|
||||
:custom-table-title="tools.customTableTitle"
|
||||
:height="mainTableHeight"
|
||||
|
||||
@@ -46,6 +46,7 @@
|
||||
<expr-tmpl-table
|
||||
ref="dataTable"
|
||||
v-loading="tools.loading"
|
||||
:loading="tools.loading"
|
||||
:api="url"
|
||||
:custom-table-title="tools.customTableTitle"
|
||||
:height="mainTableHeight"
|
||||
|
||||
@@ -110,6 +110,15 @@
|
||||
min-width="110px"
|
||||
show-overflow-tooltip
|
||||
></el-table-column>
|
||||
<template slot="empty">
|
||||
<div v-if="!tools.loading" class="right-no-data">
|
||||
<svg class="icon" aria-hidden="true">
|
||||
<use xlink:href="#nz-icon-no-data-list"></use>
|
||||
</svg>
|
||||
<div style="font-size: 16px;color: #333333;font-weight: 400;">No results found</div>
|
||||
</div>
|
||||
<div v-else> </div>
|
||||
</template>
|
||||
</el-table>
|
||||
</div>
|
||||
<pagination ref="Pagination" :append-to-body="false" :page-obj="pageObj" @pageNo='pageNo'
|
||||
|
||||
@@ -82,7 +82,15 @@
|
||||
</template>
|
||||
</el-table-column>
|
||||
</el-table>
|
||||
<div v-else class="chart-no-data">No Data</div>
|
||||
<template>
|
||||
<div v-if="!loading" class="right-no-data">
|
||||
<svg class="icon" aria-hidden="true">
|
||||
<use xlink:href="#nz-icon-no-data-list"></use>
|
||||
</svg>
|
||||
<div style="font-size: 16px;color: #333333;font-weight: 400;">No results found</div>
|
||||
</div>
|
||||
<div v-else> </div>
|
||||
</template>
|
||||
</div>
|
||||
</div>
|
||||
</template>
|
||||
@@ -98,7 +106,8 @@ export default {
|
||||
showSwitch: {
|
||||
type: Boolean,
|
||||
default: true
|
||||
}
|
||||
},
|
||||
loading: Boolean
|
||||
},
|
||||
computed: {
|
||||
tableTimeFormat () {
|
||||
@@ -559,6 +568,14 @@ export default {
|
||||
.log-table{
|
||||
position: relative;
|
||||
min-height: 200px;
|
||||
.right-no-data {
|
||||
position: absolute;
|
||||
top: 50%;
|
||||
left: 50%;
|
||||
margin-top: -35px;
|
||||
margin-left: -50px;
|
||||
text-align: center;
|
||||
}
|
||||
}
|
||||
.log-table .nz-table2 {
|
||||
padding: 10px 0 0 0;
|
||||
|
||||
Reference in New Issue
Block a user