diff --git a/nezha-fronted/src/assets/stylus/main.scss b/nezha-fronted/src/assets/stylus/main.scss
index 7667551d4..4f2bb8418 100644
--- a/nezha-fronted/src/assets/stylus/main.scss
+++ b/nezha-fronted/src/assets/stylus/main.scss
@@ -147,7 +147,7 @@ li{
position: relative;
}
.to-top {
- position: fixed;
+ position: absolute;
bottom: 10px;
right: 5px;
border-radius: 5px;
@@ -721,9 +721,13 @@ li{
/*box-shadow: inset -1px -2px 1px 0 rgba(0,0,0,0.11), inset 2px 2px 1px 0 rgba(255,255,255,0.50);*/
}
.nz-table.el-table td .cell{
- height: 38px;
+ min-height: 38px;
line-height: 38px;
}
+.nz-table.el-table td.alert-message-list-labels .cell{
+ line-height: unset;
+ padding: 3px;
+}
/*.nz-table .el-table__row td:first-of-type {
padding-left: 38px;
}*/
@@ -742,7 +746,9 @@ li{
position: absolute;
left: -3px;
}
-
+.alert-message-tag {
+ margin: 3px;
+}
/* end--内容*/
/* begin--右弹框滑入滑出动画*/
@@ -1486,3 +1492,9 @@ li{
margin: 0 -7px;
padding: 3px 0;
}
+
+.metric-tip-icon{
+ vertical-align: middle;
+ transform: scale(0.6);
+ display:inline-block;
+}
diff --git a/nezha-fronted/src/components/common/bottomBox/bottomBox.vue b/nezha-fronted/src/components/common/bottomBox/bottomBox.vue
index 1fd169422..7b0d116c1 100644
--- a/nezha-fronted/src/components/common/bottomBox/bottomBox.vue
+++ b/nezha-fronted/src/components/common/bottomBox/bottomBox.vue
@@ -28,10 +28,23 @@
+ @changeTab="changeTab">
+
+
+
+
+
+
@@ -58,8 +71,10 @@
subResizeShow: Boolean, //resize时,用v-show="subResizeShow"控制页面内容是否显示
obj: Object, //关联的实体对象
from: String, //来自哪个页面
+ tabList: Array, //动态页签列表
targetTab: String, //展示哪个页签
detail: Array, //对象详情内容
+ detailList: Array, //多个对象详情内容
assetDetail: Array, //endpoint页的asset详情
},
diff --git a/nezha-fronted/src/components/common/bottomBox/tabs/commonDetailTab.vue b/nezha-fronted/src/components/common/bottomBox/tabs/commonDetailTab.vue
index 4c5a71bcd..258d35f07 100644
--- a/nezha-fronted/src/components/common/bottomBox/tabs/commonDetailTab.vue
+++ b/nezha-fronted/src/components/common/bottomBox/tabs/commonDetailTab.vue
@@ -9,8 +9,9 @@
{{$t("alert.alertName")}}:{{obj.alertName}}
{{$t("project.endpoint.asset")}}:{{obj.host}}
{{$t("project.endpoint.endpointId")}}: {{obj.id}}
+
-
{{$t("overall.detail")}}
+ {{$t("overall.detail")}}
{{$t("config.dc.cabinets")}}
{{$t("asset.tableTitle.alerts")}}
@@ -19,6 +20,12 @@
{{$t("overall.query")}}
{{$t("project.endpoint.asset")}}
+
+ {{$t("project.endpoint.asset")}}
{{$t("project.project.project")}}
{{$t("project.module.module")}}
{{$t("project.endpoint.endpoint")}}
{{$t("config.dc.dc")}}
diff --git a/nezha-fronted/src/components/common/header.vue b/nezha-fronted/src/components/common/header.vue
index e4d0cd295..378021b19 100644
--- a/nezha-fronted/src/components/common/header.vue
+++ b/nezha-fronted/src/components/common/header.vue
@@ -93,7 +93,7 @@
- {{$t('overall.config')}}
+ {{$t('overall.config')}}
{{$t('config.account.account')}}
@@ -325,11 +325,6 @@
let index = this.indOf(this.activeItemIndexes, id);
this.activeItemIndexes=[];//2020-02-25 修改为单选
this.activeItemIndexes.push(id);
- // if (index > -1) {
- // this.activeItemIndexes.splice(index, 1);
- // } else {
- // this.activeItemIndexes.push(id);
- // }
this.$store.state.assetData = {selectedData: this.activeItemIndexes, step: this.$store.state.assetData.step+1, type: 1};
this.jumpTo('asset');
},
@@ -449,11 +444,6 @@
c.push(a[i]);
}
return c.indexOf(b);
- /*if (c.indexOf(b) > -1) {
- return true;
- } else {
- return false;
- }*/
},
panelListReload(){
if(this.$route.path==='/panel'){
@@ -474,6 +464,9 @@
refreshLang() {
this.language = localStorage.getItem("nz-language");
this.$i18n.locale = this.language;
+ this.$nextTick(() => {
+ window.location.reload();
+ });
},
showPwdDialog:function(){
this.showChangePwd=true;
@@ -498,7 +491,6 @@
this.getUserData();
this.getAssetData();
this.getProjectList();
- this.refreshLang();
// 刷新后有高亮
let activePath = this.$route.path.slice(1);
this.activeIndex = activePath;
@@ -508,10 +500,7 @@
bus.$on('login', () => {
this.username = sessionStorage.getItem("nz-username");
this.refreshLang();
- this.activeIndex = 'panel';
- /*this.$nextTick(function(){
- window.location.reload();
- });*/
+ this.activeIndex = 'overview';
});
if (window.history && window.history.pushState) {
diff --git a/nezha-fronted/src/components/common/language/en.js b/nezha-fronted/src/components/common/language/en.js
index f488f4c6e..583713ba7 100644
--- a/nezha-fronted/src/components/common/language/en.js
+++ b/nezha-fronted/src/components/common/language/en.js
@@ -654,7 +654,8 @@ const en = {
moduleAlert: 'Module alert',//"组件告警"
deviceAlert: 'Device alert',//"设备告警"
pending: 'Pending',//"待处理"
- expired: 'Expired'//"已过期"
+ expired: 'Expired',//"已过期"
+ labels: 'Labels'
},
config: {
name: 'Name',//"名称"
diff --git a/nezha-fronted/src/components/common/popBox/selectWalk.vue b/nezha-fronted/src/components/common/popBox/selectWalk.vue
index 3f32423dc..bba69ba8e 100644
--- a/nezha-fronted/src/components/common/popBox/selectWalk.vue
+++ b/nezha-fronted/src/components/common/popBox/selectWalk.vue
@@ -24,17 +24,17 @@
+
+
+
+ - Name : {{data.name}}
+ - OID : {{data.objectID}}
+ - MIB : {{mibName(node)}}
+
+
+
+
-
-
-
- - Name : {{data.name}}
- - OID : {{data.objectID}}
- - MIB : {{mibName(node)}}
-
-
-
-
{{data.name}}
@@ -59,7 +59,7 @@
},
data() {
return {
- popBox: {show: false}
+ popBox: {show: false},
}
},
computed: {
diff --git a/nezha-fronted/src/components/common/rightBox/alertConfigBox.vue b/nezha-fronted/src/components/common/rightBox/alertConfigBox.vue
index d96b0ee39..1e56bc40d 100644
--- a/nezha-fronted/src/components/common/rightBox/alertConfigBox.vue
+++ b/nezha-fronted/src/components/common/rightBox/alertConfigBox.vue
@@ -28,19 +28,19 @@
{{alertRule.alertName}}
-
+
-
+
diff --git a/nezha-fronted/src/components/common/rightBox/moduleBox.vue b/nezha-fronted/src/components/common/rightBox/moduleBox.vue
index c17a175e0..56f3e40c3 100644
--- a/nezha-fronted/src/components/common/rightBox/moduleBox.vue
+++ b/nezha-fronted/src/components/common/rightBox/moduleBox.vue
@@ -62,8 +62,8 @@
-
-
+
+
@@ -432,10 +432,21 @@
let obj = JSON.parse(response.data);
this.walkData = [];
for (let item in obj) {
- this.walkData.push({name: item, subTree: obj[item]});
+ setAttr(obj[item], "detailShow", false);
+ this.walkData.push({name: item, detailShow: false, subTree: obj[item]});
}
}
});
+ function setAttr(tree, name, value) {
+ if (tree && tree.length > 0) {
+ for (let i = 0; i < tree.length; i++) {
+ tree[i][name] = value;
+ if (tree[i].subTree && tree[i].subTree.length > 0) {
+ setAttr(tree[i].subTree, name, value);
+ }
+ }
+ }
+ }
},
show(show, isEdit) {
@@ -747,4 +758,11 @@
.module-box-type {
margin: 25px 0 10px -15px;
}
+ .walk-close-box {
+ margin-left: 6px;
+ width: 14px;
+ }
+ .walk-close {
+ margin-left: -6px;
+ }
diff --git a/nezha-fronted/src/components/page/alert/config.vue b/nezha-fronted/src/components/page/alert/config.vue
index 9b46cfb74..eaa3c9050 100644
--- a/nezha-fronted/src/components/page/alert/config.vue
+++ b/nezha-fronted/src/components/page/alert/config.vue
@@ -61,17 +61,16 @@
{{severityData[0].value}}
{{severityData[2].value}}
-
+
{{scope.row[item.prop].name}}
{{scope.row[item.prop].host}}
-
-
+ -->
{{scope.row.alertNum + ' ' + $t('overall.active')}}
@@ -114,6 +113,7 @@