diff --git a/nezha-fronted/src/assets/css/components/common/detailView/detailViewTopSearch.scss b/nezha-fronted/src/assets/css/components/common/detailView/detailViewTopSearch.scss index c107f0310..58c07b674 100644 --- a/nezha-fronted/src/assets/css/components/common/detailView/detailViewTopSearch.scss +++ b/nezha-fronted/src/assets/css/components/common/detailView/detailViewTopSearch.scss @@ -47,6 +47,7 @@ min-width: 200px; } } + .detail-top-search-dropdown{ max-height: 300px; overflow-y: auto; @@ -80,6 +81,7 @@ } .children-title-name{ min-width: 180px; + flex-shrink: 0; height: 36px; padding-right: 20px; @@ -96,6 +98,26 @@ background: $--background-color-base !important; } } +.detail-top-search-dropdown-special.detail-top-search-dropdown { + width: 680px; + max-width: unset !important; + .nz-dropdown-menu__item{ + width: 100% !important; + .children-title-name { + width: 33%; + box-sizing: border-box; + } + .nz-dropdown-menu__item-box { + width: 66%; + display: flex; + flex-wrap: wrap; + .nz-dropdown-menu__item-hover { + width: calc(50% - 2px); + box-sizing: border-box; + } + } + } +} .clear-all-select{ padding: 0 20px; padding-left: 42px; diff --git a/nezha-fronted/src/assets/css/components/common/project/L5/popData/common.scss b/nezha-fronted/src/assets/css/components/common/project/L5/popData/common.scss index 92260b40b..f5e2d6e05 100644 --- a/nezha-fronted/src/assets/css/components/common/project/L5/popData/common.scss +++ b/nezha-fronted/src/assets/css/components/common/project/L5/popData/common.scss @@ -143,6 +143,7 @@ width: 120px; display: inline-block; padding: 3px 0; + vertical-align: middle; } .content-text { width: 175px; @@ -150,6 +151,10 @@ font-size: 12px; display: inline-block; padding: 3px 5px; + vertical-align: middle; + overflow:hidden; + text-overflow:ellipsis; + white-space:nowrap } .module-type { border: 1px solid #DCDCDC; diff --git a/nezha-fronted/src/assets/css/components/page/tool/ping.scss b/nezha-fronted/src/assets/css/components/page/tool/ping.scss index d22e7db59..85ff2c26d 100644 --- a/nezha-fronted/src/assets/css/components/page/tool/ping.scss +++ b/nezha-fronted/src/assets/css/components/page/tool/ping.scss @@ -161,8 +161,10 @@ font-size: 14px; color: $--color-text-regular; letter-spacing: 0; - font-weight: 400; - margin: 30px 0 11px 0; + line-height: 20px; + font-weight: 600; + font-style: oblique; + padding: 30px 0 10px 0; } .data-top{ width: 100%; diff --git a/nezha-fronted/src/assets/css/components/page/tool/trace.scss b/nezha-fronted/src/assets/css/components/page/tool/trace.scss index d21cb1963..d411c66bc 100644 --- a/nezha-fronted/src/assets/css/components/page/tool/trace.scss +++ b/nezha-fronted/src/assets/css/components/page/tool/trace.scss @@ -169,8 +169,10 @@ font-size: 14px; color: $--color-text-regular; letter-spacing: 0; - font-weight: 400; - margin: 30px 0 11px 0; + line-height: 20px; + font-weight: 600; + font-style: oblique; + padding: 30px 0 10px 0; } .data-top{ width: 100%; diff --git a/nezha-fronted/src/components/common/alert/alertRuleInfo.vue b/nezha-fronted/src/components/common/alert/alertRuleInfo.vue index 3faec45be..038f3384d 100644 --- a/nezha-fronted/src/components/common/alert/alertRuleInfo.vue +++ b/nezha-fronted/src/components/common/alert/alertRuleInfo.vue @@ -100,6 +100,15 @@ export default { that: {}, severityData: Array }, + watch: { + id: { + immediate: true, + deep: true, + handler (n) { + this.init() + } + }, + }, data () { return { loading: true, @@ -181,52 +190,58 @@ export default { }, tipHoverRule (tipLoading) { this.$emit('tipHoverRule', tipLoading) + }, + init () { + if (!this.id) { + return + } + this.$get('/alert/rule/' + this.id).then((res) => { + if (res.msg === 'success') { + this.loading = false + this.alertRuleData = res.data + this.severityDataColor() + this.alertColor = this.returnColor(res.data.alert) + const weekDays = this.getWeeksTime() + if (this.trendTimer) { + clearTimeout(this.trendTimer) + this.trendTimer = null + } + this.trendTimer = setTimeout(() => { + this.trendLoading = true + const params = { + type: 'total', + dimension: 'priority', + step: 'd' + } + params['rule' + 'Id'] = this.id + this.$get('/stat/alertMessage/trend', params).then((res) => { + if (!res.data) { + return + } + const alertDaysData = res.data.result ? res.data.result[0].values : [] + const newWeekDays = JSON.parse(JSON.stringify(weekDays)) + alertDaysData.forEach(item => { + item.values.forEach(time => { + const findItem = newWeekDays.find(days => days.time == time[0]) + if (findItem) { + findItem[item.metric.priority] = time[1] + } + }) + }) + setTimeout(() => { + this.alertDaysData = newWeekDays + this.trendLoading = false + }) + }) + }) + } else { + this.$message.error(res.msg) + } + }) } }, mounted () { - this.$get('/alert/rule/' + this.id).then((res) => { - if (res.msg === 'success') { - this.loading = false - this.alertRuleData = res.data - this.severityDataColor() - this.alertColor = this.returnColor(res.data.alert) - const weekDays = this.getWeeksTime() - if (this.trendTimer) { - clearTimeout(this.trendTimer) - this.trendTimer = null - } - this.trendTimer = setTimeout(() => { - this.trendLoading = true - const params = { - type: 'total', - dimension: 'priority', - step: 'd' - } - params['rule' + 'Id'] = this.id - this.$get('/stat/alertMessage/trend', params).then((res) => { - if (!res.data) { - return - } - const alertDaysData = res.data.result ? res.data.result[0].values : [] - const newWeekDays = JSON.parse(JSON.stringify(weekDays)) - alertDaysData.forEach(item => { - item.values.forEach(time => { - const findItem = newWeekDays.find(days => days.time == time[0]) - if (findItem) { - findItem[item.metric.priority] = time[1] - } - }) - }) - setTimeout(() => { - this.alertDaysData = newWeekDays - this.trendLoading = false - }) - }) - }) - } else { - this.$message.error(res.msg) - } - }) + } } diff --git a/nezha-fronted/src/components/common/bottomBox/tabs/alertMessageTabNew.vue b/nezha-fronted/src/components/common/bottomBox/tabs/alertMessageTabNew.vue index 506b8af90..decc4a019 100644 --- a/nezha-fronted/src/components/common/bottomBox/tabs/alertMessageTabNew.vue +++ b/nezha-fronted/src/components/common/bottomBox/tabs/alertMessageTabNew.vue @@ -19,7 +19,7 @@ - +