fix: 修复overview-alertmessage数量显示不对等

1.修复overview-alertmessage数量显示不对的问题
2.operationlog state颜色、顶部菜单状态
This commit is contained in:
陈劲松
2020-04-26 11:26:22 +08:00
parent d672ba9cb1
commit cc92b77472
3 changed files with 13 additions and 22 deletions

View File

@@ -52,6 +52,7 @@
:height="$tableHeight.normal"
v-loading="loading"
v-scrollBar:el-table="'large'"
:cell-class-name="messageStyle"
style="width: 100%;">
<el-table-column
:resizable="false"
@@ -62,11 +63,6 @@
:label="item.label"
>
<template slot-scope="scope" :column="item">
<span v-if="item.prop == 'lang'">
{{scope.row[item.prop] == 'en' ? 'English' : ''}}
{{scope.row[item.prop] == 'zh' ? '中文' : ''}}
{{scope.row[item.prop] == 'ru' ? 'русский' : ''}}
</span>
<span v-if="item.prop == 'time'">
{{scope.row[item.prop]}} ms
</span>
@@ -256,6 +252,16 @@
this.$store.commit('setHeaderTable', data);
this.tablelable = data;
},
messageStyle(e) {
if (e.column.label == this.$t('config.operationlog.state')) {
if (e.row.state == 'success') {
return 'success';
} else {
return 'danger';
}
}
return '';
},
getTableData: function () {
this.$set(this.searchLabel, "pageNo", this.pageObj.pageNo);
this.$set(this.searchLabel, "pageSize", this.pageObj.pageSize);