Merge branch 'dev-2.0' of https://git.mesalab.cn/nezha/nezha-fronted into dev-2.0
This commit is contained in:
@@ -201,9 +201,9 @@ export default {
|
|||||||
endpoint: {
|
endpoint: {
|
||||||
endpointTabTitle: [
|
endpointTabTitle: [
|
||||||
{ prop: 'panelTab', name: this.$t('overall.detail') },
|
{ prop: 'panelTab', name: this.$t('overall.detail') },
|
||||||
|
{ prop: 'endpointAlertMessage', name: this.$t('overall.alert') },
|
||||||
{ prop: 'endpointQuery', name: 'Query' },
|
{ prop: 'endpointQuery', name: 'Query' },
|
||||||
{ prop: 'log', name: 'Log' },
|
{ prop: 'log', name: 'Log' },
|
||||||
{ prop: 'endpointAlertMessage', name: this.$t('overall.alert') }
|
|
||||||
]
|
]
|
||||||
},
|
},
|
||||||
chartTemp: {
|
chartTemp: {
|
||||||
@@ -250,8 +250,8 @@ export default {
|
|||||||
const hasLog = config && config.enable === 1
|
const hasLog = config && config.enable === 1
|
||||||
const tabs = [
|
const tabs = [
|
||||||
{ prop: 'panelTab', name: this.$t('overall.detail') },
|
{ prop: 'panelTab', name: this.$t('overall.detail') },
|
||||||
{ prop: 'endpointQuery', name: 'Query' },
|
{ prop: 'endpointAlertMessage', name: this.$t('overall.alert') },
|
||||||
{ prop: 'endpointAlertMessage', name: this.$t('overall.alert') }
|
{ prop: 'endpointQuery', name: 'Metrics' }
|
||||||
]
|
]
|
||||||
if (hasLog) {
|
if (hasLog) {
|
||||||
tabs.push({ prop: 'log', name: 'Log' })
|
tabs.push({ prop: 'log', name: 'Log' })
|
||||||
|
|||||||
@@ -102,7 +102,7 @@ export default {
|
|||||||
this.expressions.forEach((item, index) => {
|
this.expressions.forEach((item, index) => {
|
||||||
if (item != '') {
|
if (item != '') {
|
||||||
let expr = item
|
let expr = item
|
||||||
this.matchContent && (expr = `${item} ${this.matchSymbol} ${this.matchContent}`)
|
this.matchContent && (expr = `${item} ${this.matchSymbol} "${this.matchContent}"`)
|
||||||
requestArr.push(this.$get('/logs/loki/api/v1/query_range?format=1&query=' + expr + '&start=' + this.$stringTimeParseToUnix(this.filterTime[0]) + '&end=' + this.$stringTimeParseToUnix(this.filterTime[1]) + '&limit=' + limit))
|
requestArr.push(this.$get('/logs/loki/api/v1/query_range?format=1&query=' + expr + '&start=' + this.$stringTimeParseToUnix(this.filterTime[0]) + '&end=' + this.$stringTimeParseToUnix(this.filterTime[1]) + '&limit=' + limit))
|
||||||
}
|
}
|
||||||
})
|
})
|
||||||
|
|||||||
@@ -175,7 +175,7 @@
|
|||||||
<i class="nz-icon nz-icon-more3"></i>
|
<i class="nz-icon nz-icon-more3"></i>
|
||||||
</div>
|
</div>
|
||||||
<el-dropdown-menu slot="dropdown">
|
<el-dropdown-menu slot="dropdown">
|
||||||
<el-dropdown-item v-if="!endpointTab" :command="['endpointQuery', scope.row]"><i class="nz-icon nz-icon-search"></i><span class="operation-dropdown-text">{{$t('overall.query')}}</span></el-dropdown-item>
|
<!-- <el-dropdown-item v-if="!endpointTab" :command="['endpointQuery', scope.row]"><i class="nz-icon nz-icon-search"></i><span class="operation-dropdown-text">{{$t('overall.query')}}</span></el-dropdown-item>-->
|
||||||
<el-dropdown-item v-if="!endpointTab" v-has="'monitor_endpoint_edit'" :command="['edit', scope.row]"><i class="nz-icon nz-icon-edit"></i><span class="operation-dropdown-text">{{$t('overall.edit')}}</span></el-dropdown-item>
|
<el-dropdown-item v-if="!endpointTab" v-has="'monitor_endpoint_edit'" :command="['edit', scope.row]"><i class="nz-icon nz-icon-edit"></i><span class="operation-dropdown-text">{{$t('overall.edit')}}</span></el-dropdown-item>
|
||||||
<el-dropdown-item v-has="'monitor_endpoint_delete'" :command="['delete', scope.row, `sys/endpoint?ids=${scope.row.id}`]"><i class="nz-icon nz-icon-delete"></i><span class="operation-dropdown-text">{{$t('overall.delete')}}</span></el-dropdown-item>
|
<el-dropdown-item v-has="'monitor_endpoint_delete'" :command="['delete', scope.row, `sys/endpoint?ids=${scope.row.id}`]"><i class="nz-icon nz-icon-delete"></i><span class="operation-dropdown-text">{{$t('overall.delete')}}</span></el-dropdown-item>
|
||||||
<el-dropdown-item v-has="'alertSilence_add'" :command="['fastSilence', scope.row, 'endpoint']"><i class="nz-icon nz-icon-fast-silence"></i><span class="operation-dropdown-text">{{$t('overall.silenceAlert')}}</span></el-dropdown-item>
|
<el-dropdown-item v-has="'alertSilence_add'" :command="['fastSilence', scope.row, 'endpoint']"><i class="nz-icon nz-icon-fast-silence"></i><span class="operation-dropdown-text">{{$t('overall.silenceAlert')}}</span></el-dropdown-item>
|
||||||
|
|||||||
@@ -296,16 +296,16 @@ export default {
|
|||||||
width: 0,
|
width: 0,
|
||||||
index: -1
|
index: -1
|
||||||
},
|
},
|
||||||
type: {
|
// type: {
|
||||||
label: 'Type',
|
// label: 'Type',
|
||||||
key: 'type',
|
// key: 'type',
|
||||||
type: 'checkBox',
|
// type: 'checkBox',
|
||||||
children: [],
|
// children: [],
|
||||||
show: false,
|
// show: false,
|
||||||
showMore: false,
|
// showMore: false,
|
||||||
width: 0,
|
// width: 0,
|
||||||
index: -1
|
// index: -1
|
||||||
}
|
// }
|
||||||
},
|
},
|
||||||
selectValue: {
|
selectValue: {
|
||||||
projectIds: [],
|
projectIds: [],
|
||||||
@@ -482,12 +482,12 @@ export default {
|
|||||||
{ key: 'Up', value: 1, name: 'Up' },
|
{ key: 'Up', value: 1, name: 'Up' },
|
||||||
{ key: 'Suspended', value: 2, name: 'Suspended' }
|
{ key: 'Suspended', value: 2, name: 'Suspended' }
|
||||||
]
|
]
|
||||||
this.titleSearchList.type.children = [
|
// this.titleSearchList.type.children = [
|
||||||
{ key: 'Metrics', value: 'metrics', name: 'Metrics' },
|
// { key: 'Metrics', value: 'metrics', name: 'Metrics' },
|
||||||
{ key: 'Logs', value: 'logs', name: 'Logs' }
|
// { key: 'Logs', value: 'logs', name: 'Logs' }
|
||||||
]
|
// ]
|
||||||
this.titleSearchList.state.show = true
|
this.titleSearchList.state.show = true
|
||||||
this.titleSearchList.type.show = true
|
// this.titleSearchList.type.show = true
|
||||||
},
|
},
|
||||||
batchModify () {
|
batchModify () {
|
||||||
if (!this.batchDeleteObjs.length) {
|
if (!this.batchDeleteObjs.length) {
|
||||||
|
|||||||
Reference in New Issue
Block a user