feat:调整endponit的样式
This commit is contained in:
@@ -1201,7 +1201,10 @@ const cn = {
|
|||||||
password: '密码',
|
password: '密码',
|
||||||
authTypeNull: 'none',
|
authTypeNull: 'none',
|
||||||
authTypeWord: 'basic auth',
|
authTypeWord: 'basic auth',
|
||||||
authTypeToken: 'bearer token'
|
authTypeToken: 'bearer token',
|
||||||
|
name: '名称',
|
||||||
|
configs: 'Configs',
|
||||||
|
state: '状态'
|
||||||
},
|
},
|
||||||
metrics: {
|
metrics: {
|
||||||
metrics: '指标',
|
metrics: '指标',
|
||||||
|
|||||||
@@ -1207,7 +1207,10 @@ const en = {
|
|||||||
password: 'Password',
|
password: 'Password',
|
||||||
authTypeNull: 'None',
|
authTypeNull: 'None',
|
||||||
authTypeWord: 'basic auth',
|
authTypeWord: 'basic auth',
|
||||||
authTypeToken: 'bearer token'
|
authTypeToken: 'bearer token',
|
||||||
|
name: 'Name',
|
||||||
|
configs: 'Configs',
|
||||||
|
state: 'State'
|
||||||
},
|
},
|
||||||
metrics: {
|
metrics: {
|
||||||
metrics: 'Metrics', // "指标"
|
metrics: 'Metrics', // "指标"
|
||||||
|
|||||||
@@ -37,15 +37,26 @@
|
|||||||
{{scope.row[item.prop]}}
|
{{scope.row[item.prop]}}
|
||||||
</template>
|
</template>
|
||||||
<template v-else-if="item.prop === 'type'">
|
<template v-else-if="item.prop === 'type'">
|
||||||
{{scope.row[item.prop]}}
|
{{scope.row.module.type}}
|
||||||
</template>
|
</template>
|
||||||
<template v-else-if="item.prop === 'project'">
|
<template v-else-if="item.prop === 'project'">
|
||||||
{{scope.row[item.prop].name}}
|
{{scope.row[item.prop].name}}
|
||||||
</template>
|
</template>
|
||||||
<template v-else-if="item.prop === 'endpointNum'">
|
<template v-else-if="item.prop === 'module'">
|
||||||
{{scope.row[item.prop]}}
|
{{scope.row[item.prop].name}}
|
||||||
</template>
|
</template>
|
||||||
<template v-else-if="item.prop === 'alertNum'">
|
<template v-else-if="item.prop === 'alerts'">
|
||||||
|
<span class="endpoint-num" :class="scope.row.alertNum>0?'bagEF7458':'bag23BF9A'">
|
||||||
|
{{scope.row.alertNum}} active
|
||||||
|
</span>
|
||||||
|
</template>
|
||||||
|
<template v-else-if="item.prop === 'configs'">
|
||||||
|
<el-tooltip placement="right" effect="light">
|
||||||
|
<span class="configs-endpoint">{}</span>
|
||||||
|
<div slot="content">{{scope.row[item.prop]}}</div>
|
||||||
|
</el-tooltip>
|
||||||
|
</template>
|
||||||
|
<template v-else-if="item.prop === 'state'">
|
||||||
{{scope.row[item.prop]}}
|
{{scope.row[item.prop]}}
|
||||||
</template>
|
</template>
|
||||||
<span v-else>{{scope.row[item.prop] ? scope.row[item.prop] : ''}}</span>
|
<span v-else>{{scope.row[item.prop] ? scope.row[item.prop] : ''}}</span>
|
||||||
@@ -86,37 +97,36 @@ export default {
|
|||||||
show: true,
|
show: true,
|
||||||
width: 80
|
width: 80
|
||||||
}, {
|
}, {
|
||||||
label: this.$t('project.module.moduleName'),
|
label: this.$t('project.endpoint.name'),
|
||||||
prop: 'name',
|
prop: 'name',
|
||||||
show: true,
|
show: true
|
||||||
width: 150
|
|
||||||
}, {
|
}, {
|
||||||
label: this.$t('project.module.type'),
|
label: this.$t('project.module.type'),
|
||||||
prop: 'type',
|
prop: 'type',
|
||||||
show: true,
|
show: true
|
||||||
width: 150
|
|
||||||
}, {
|
}, {
|
||||||
label: this.$t('project.project.project'),
|
label: this.$t('project.project.project'),
|
||||||
prop: 'project',
|
prop: 'project',
|
||||||
show: true,
|
show: true
|
||||||
width: 150
|
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
label: this.$t('project.endpoint.endpoint'),
|
label: this.$t('project.module.module'),
|
||||||
prop: 'endpointNum',
|
prop: 'module',
|
||||||
show: true,
|
show: true
|
||||||
width: 150
|
|
||||||
}, {
|
}, {
|
||||||
label: this.$t('project.module.alerts'),
|
label: this.$t('project.endpoint.alerts'),
|
||||||
prop: 'alertNum',
|
prop: 'alerts',
|
||||||
show: true,
|
show: true
|
||||||
width: 150
|
|
||||||
},
|
},
|
||||||
{
|
{
|
||||||
label: this.$t('overall.remark'),
|
label: this.$t('project.endpoint.configs'),
|
||||||
prop: 'remark',
|
prop: 'configs',
|
||||||
show: true,
|
show: true
|
||||||
minWidth: 150
|
},
|
||||||
|
{
|
||||||
|
label: this.$t('project.endpoint.state'),
|
||||||
|
prop: 'state',
|
||||||
|
show: true
|
||||||
}
|
}
|
||||||
]
|
]
|
||||||
}
|
}
|
||||||
@@ -129,3 +139,24 @@ export default {
|
|||||||
computed: {}
|
computed: {}
|
||||||
}
|
}
|
||||||
</script>
|
</script>
|
||||||
|
<style scoped>
|
||||||
|
.endpoint-num{
|
||||||
|
padding: 0 3px;
|
||||||
|
cursor: pointer;
|
||||||
|
border-radius: 2px;
|
||||||
|
}
|
||||||
|
.bagEF7458{
|
||||||
|
background: #EF7458;
|
||||||
|
color: #fff;
|
||||||
|
}
|
||||||
|
.bag23BF9A{
|
||||||
|
background: #23BF9A;
|
||||||
|
color: #fff;
|
||||||
|
}
|
||||||
|
.configs-endpoint{
|
||||||
|
background: #FA901C;
|
||||||
|
border-radius: 4px;
|
||||||
|
padding: 2px 7px;
|
||||||
|
color: #fff;
|
||||||
|
}
|
||||||
|
</style>
|
||||||
|
|||||||
Reference in New Issue
Block a user