Merge branch 'dev-3.3' of git.mesalab.cn:nezha/nezha-fronted into dev-3.3
This commit is contained in:
@@ -59,7 +59,7 @@
|
||||
}
|
||||
.search-item-value-box{
|
||||
line-height: 47px;
|
||||
height: 13px;
|
||||
height: 100%;
|
||||
width: calc(100% - 120px);
|
||||
display: flex;
|
||||
align-items: center;
|
||||
|
||||
@@ -22,4 +22,13 @@
|
||||
font-size: 14px;
|
||||
line-height: 14px;
|
||||
}
|
||||
.user-name-td{
|
||||
display: flex;
|
||||
align-items: center;
|
||||
.user-online{
|
||||
margin-right: 5px;
|
||||
margin-left: -10px;
|
||||
color: #38cc20;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -45,7 +45,7 @@
|
||||
<li @click="editChart" class="el-dropdown-menu__item">
|
||||
<i class="nz-icon nz-icon-edit" style="font-size: 16px;"></i><span>{{$t('dashboard.edit')}}</span></li>
|
||||
<li v-has="'main_delete'" class="el-dropdown-menu__item" @click="removeChart">
|
||||
<i class="nz-icon nz-icon-delete" style="font-size: 16px;"></i>{{$t('dashboard.delete')}}</li>
|
||||
<i class="nz-icon nz-icon-delete" style="font-size: 16px;"></i>{{$t('overall.delete')}}</li>
|
||||
<li v-has="'main_add'" class="el-dropdown-menu__item" @click="duplicate">
|
||||
<i class="el-icon-copy-document" style="font-size: 16px;"></i>{{$t('dashboard.duplicate')}}</li>
|
||||
<li v-has="'main_edit'" v-if="from !== 'chartTemp'&&chartData.pid" class="el-dropdown-menu__item" @click="$emit('sync')">
|
||||
@@ -79,7 +79,7 @@
|
||||
ref="Pagination" :append-to-body="false" pop-class="out-popper-fix"></Pagination>
|
||||
</div>
|
||||
<!--全屏-->
|
||||
<el-dialog class="nz-dialog table-chart-dialog" :title="$t('dashboard.panel.view')" :visible.sync="screenModal"
|
||||
<el-dialog class="nz-dialog table-chart-dialog" :title="$t('overall.view')" :visible.sync="screenModal"
|
||||
width="96%" @close="screenModal = false" :modal-append-to-body="false">
|
||||
<div slot="title">
|
||||
<span class="nz-dialog-title">{{data.name}}</span>
|
||||
|
||||
@@ -58,7 +58,7 @@
|
||||
<li @click="editChart" class="el-dropdown-menu__item">
|
||||
<i class="nz-icon nz-icon-edit" style="font-size: 16px;"></i><span>{{$t('dashboard.edit')}}</span></li>
|
||||
<li v-has="'main_delete'" class="el-dropdown-menu__item" @click="removeChart">
|
||||
<i class="nz-icon nz-icon-delete" style="font-size: 16px;"></i>{{$t('dashboard.delete')}}</li>
|
||||
<i class="nz-icon nz-icon-delete" style="font-size: 16px;"></i>{{$t('overall.delete')}}</li>
|
||||
<li v-has="'main_add'" class="el-dropdown-menu__item" @click="duplicate">
|
||||
<i class="el-icon-copy-document" style="font-size: 16px;"></i>{{$t('dashboard.duplicate')}}</li>
|
||||
<li v-has="'main_edit'" v-if="from !== 'chartTemp'&&chartData.pid" class="el-dropdown-menu__item" @click="$emit('sync')">
|
||||
@@ -110,7 +110,7 @@
|
||||
<!--
|
||||
<Modal title="查看" v-model="screenModal" width="96%" class="line-chart-block-modal">-->
|
||||
<el-dialog class="line-chart-block-modal nz-dialog"
|
||||
:title="$t('dashboard.panel.view')"
|
||||
:title="$t('overall.view')"
|
||||
:visible.sync="screenModal"
|
||||
width="90%"
|
||||
@close="screenModal = false;screenLegendListMore=[]"
|
||||
|
||||
@@ -68,7 +68,7 @@
|
||||
</li>
|
||||
<li v-has="'main_delete'" class="el-dropdown-menu__item" @click="removeChart">
|
||||
<i class="nz-icon nz-icon-delete" style="font-size: 16px;"></i>
|
||||
<span>{{$t('dashboard.delete')}}</span>
|
||||
<span>{{$t('overall.delete')}}</span>
|
||||
</li>
|
||||
<li v-has="'main_add'" class="el-dropdown-menu__item" @click="duplicate">
|
||||
<i class="el-icon-copy-document" style="font-size: 16px;"></i>
|
||||
|
||||
@@ -348,6 +348,10 @@ export default {
|
||||
this.chartInfo.loaded && this.getChartData()
|
||||
this.showAllData = !this.showMultiple(this.chartInfo.type)
|
||||
this.getAlertMessageInfo()
|
||||
window.addEventListener('resize', this.resize)
|
||||
},
|
||||
destroyed() {
|
||||
window.removeEventListener('resize', this.resize)
|
||||
}
|
||||
}
|
||||
</script>
|
||||
|
||||
@@ -169,6 +169,7 @@ export default {
|
||||
deep: true,
|
||||
handler (n, o) {
|
||||
if (n) {
|
||||
this.searchLabel = {}
|
||||
this.getTableData()
|
||||
}
|
||||
}
|
||||
|
||||
@@ -696,6 +696,7 @@ export default {
|
||||
immediate: true,
|
||||
deep: true,
|
||||
handler (n) {
|
||||
this.searchLabel = {}
|
||||
if (this.from === fromRoute.module) {
|
||||
this.searchLabel.moduleIds = n.id
|
||||
} else {
|
||||
|
||||
@@ -158,9 +158,11 @@ export default {
|
||||
immediate: true,
|
||||
handler (n) {
|
||||
if (n) {
|
||||
this.searchLabel = {}
|
||||
if (this.from === fromRoute.alertSilence) {
|
||||
this.state = '2'
|
||||
}
|
||||
this.searchLabel = {}
|
||||
this.getTableData()
|
||||
}
|
||||
}
|
||||
|
||||
@@ -280,6 +280,7 @@ export default {
|
||||
immediate: true,
|
||||
deep: true,
|
||||
handler (n, o) {
|
||||
this.searchLabel = {}
|
||||
this.searchLabel.dcIds = n.id
|
||||
if (this.from === fromRoute.model) {
|
||||
delete this.searchLabel.dcIds
|
||||
|
||||
@@ -284,6 +284,7 @@ export default {
|
||||
immediate: true,
|
||||
deep: true,
|
||||
handler (n, o) {
|
||||
this.searchLabel = {}
|
||||
this.searchLabel.dcIds = n.id
|
||||
if (this.from === fromRoute.model) {
|
||||
delete this.searchLabel.dcIds
|
||||
|
||||
@@ -93,6 +93,7 @@ export default {
|
||||
obj: {
|
||||
immediate: true,
|
||||
handler (n) {
|
||||
this.searchLabel = {}
|
||||
this.formatTime = bus.timeFormate(new Date(bus.computeTimezoneTime(new Date())))
|
||||
}
|
||||
}
|
||||
|
||||
@@ -705,6 +705,7 @@ export default {
|
||||
deep: true,
|
||||
handler (n) {
|
||||
if (n) {
|
||||
this.searchLabel = {}
|
||||
this.currentEndpoint = JSON.parse(JSON.stringify(n))
|
||||
this.queryEndpoint()
|
||||
}
|
||||
|
||||
@@ -515,6 +515,7 @@ export default {
|
||||
deep: true,
|
||||
handler (n) {
|
||||
if (n) {
|
||||
this.searchLabel = {}
|
||||
if (this.from === fromRoute.asset) {
|
||||
this.asset = JSON.parse(JSON.stringify(n))
|
||||
this.$nextTick(() => {
|
||||
|
||||
@@ -75,6 +75,7 @@ export default {
|
||||
immediate: true,
|
||||
handler (n) {
|
||||
if (n) {
|
||||
this.searchLabel = {}
|
||||
this.getTableData()
|
||||
}
|
||||
}
|
||||
|
||||
@@ -808,6 +808,7 @@ export default {
|
||||
handler (n, o) {
|
||||
setTimeout(() => {
|
||||
if (n && n.id) {
|
||||
this.searchLabel = {}
|
||||
this.getTableData(n.id)
|
||||
if (this.from === fromRoute.asset) {
|
||||
this.searchLabel.assetIds = n.id
|
||||
|
||||
@@ -88,6 +88,7 @@ export default {
|
||||
deep: true,
|
||||
handler (n, o) {
|
||||
if (n) {
|
||||
this.searchLabel = {}
|
||||
this.inputDateSearch = ''
|
||||
this.getTableData()
|
||||
}
|
||||
|
||||
@@ -12,7 +12,7 @@
|
||||
<el-skeleton-item class="search-item-name" search-item-path variant="h3" style="width: 30%" />
|
||||
<div v-for="item in skeletonArr" :key="item" class="search-item-info">
|
||||
<el-skeleton-item class="search-item-key"/>
|
||||
<el-skeleton-item class="search-item-value-box" style="margin-left: 20px"/>
|
||||
<el-skeleton-item class="search-item-value-box" style="margin-left: 20px;height: 13px"/>
|
||||
</div>
|
||||
</div>
|
||||
</template>
|
||||
|
||||
@@ -8,7 +8,7 @@
|
||||
</div>
|
||||
<div class="line"></div>
|
||||
<div>
|
||||
<a :class="{disabled:!props.node && !props.nodes && !props.line}" @click="onDel()">{{$t('project.topology.delete')}}</a>
|
||||
<a :class="{disabled:!props.node && !props.nodes && !props.line}" @click="onDel()">{{$t('overall.delete')}}</a>
|
||||
</div>
|
||||
<div class="line"></div>
|
||||
<div>
|
||||
|
||||
@@ -29,7 +29,7 @@
|
||||
</el-switch>
|
||||
</el-form-item>
|
||||
<!--monitor-->
|
||||
<el-form-item :label="$t('config.assetState.monitor')">
|
||||
<el-form-item :label="$t('config.system.monitor.monitor')">
|
||||
<el-switch :active-value="1" :inactive-value="0" id="asset-state-monitor-status"
|
||||
v-model="editAssetState.monitor">
|
||||
</el-switch>
|
||||
|
||||
@@ -654,7 +654,8 @@ export default {
|
||||
rules: {
|
||||
name: [
|
||||
{ required: true, message: this.$t('validate.required'), trigger: 'change' },
|
||||
{ validator: this.optionType === 'batch' ? '' : noSpecialChar, trigger: 'change' }
|
||||
{ validator: this.optionType === 'batch' ? '' : noSpecialChar, trigger: 'change' },
|
||||
{ max: 64, message: this.$t('config.system.link.nameMaxLength'), trigger: 'blur' }
|
||||
],
|
||||
assetId: [
|
||||
{ required: !(this.optionType === 'batch'), message: this.$t('validate.required'), trigger: 'change' }
|
||||
|
||||
@@ -153,7 +153,7 @@
|
||||
:command="['delete', scope.row]"
|
||||
><i class="nz-icon nz-icon-delete"></i
|
||||
><span class="operation-dropdown-text">{{
|
||||
$t("buttons.delete")
|
||||
$t("overall.delete")
|
||||
}}</span></el-dropdown-item
|
||||
>
|
||||
</el-dropdown-menu>
|
||||
|
||||
@@ -147,7 +147,7 @@ export default {
|
||||
},
|
||||
changeDate (item) {
|
||||
const time = this.utcTimeToTimezoneStr(item)
|
||||
const time1 = this.timeFormate(Date.parse(time))
|
||||
const time1 = this.timeFormate(time)
|
||||
return time1
|
||||
},
|
||||
getNum (item) {
|
||||
|
||||
@@ -32,18 +32,21 @@
|
||||
:width="`${item.width}`"
|
||||
>
|
||||
<template slot="header">
|
||||
<span class="data-column__span">{{item.label}}</span>
|
||||
<span class="data-column__span" :class="{'margin-l-10': item.prop === 'name'}">{{item.label}}</span>
|
||||
<div class="col-resize-area"></div>
|
||||
</template>
|
||||
<template slot-scope="scope" :column="item">
|
||||
<template v-if="item.prop === 'name'">
|
||||
<div>
|
||||
<div class="flex-align-center">
|
||||
<span class="user-name-top">{{scope.row[item.prop]}}</span>
|
||||
<el-tag size="mini" v-if="mfaEnable == '1' || scope.row.mfaLevel > 0" style="margin-left: 5px">2FA</el-tag>
|
||||
</div>
|
||||
<div class="user-name-bottom">
|
||||
@{{scope.row.username}}
|
||||
<div class="user-name-td" :class="{'margin-l-10': !scope.row.online}">
|
||||
<i class="nz-icon nz-icon-user1 user-online" v-if="scope.row.online" :title="$t('overall.online')"/>
|
||||
<div>
|
||||
<div class="flex-align-center">
|
||||
<span class="user-name-top">{{scope.row[item.prop]}}</span>
|
||||
<el-tag size="mini" v-if="mfaEnable == '1' || scope.row.mfaLevel > 0" style="margin-left: 5px">2FA</el-tag>
|
||||
</div>
|
||||
<div class="user-name-bottom">
|
||||
@{{scope.row.username}}
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</template>
|
||||
|
||||
@@ -24,7 +24,7 @@
|
||||
</template>
|
||||
<template v-slot:tail>
|
||||
<div class="panel-select-tail">
|
||||
<span id="panel-list-toadd" v-has="'asset_label_add'" :title='$t("dashboard.panel.createPanelTitleSec")' class="panel-select-add" @click="addGroup"><i class="nz-icon nz-icon-create-square"></i> {{ $t('overall.addProject') }}</span>
|
||||
<span id="panel-list-toadd" v-has="'asset_label_add'" :title='$t("dashboard.panel.createPanelTitleSec")' class="panel-select-add" @click="addGroup"><i class="nz-icon nz-icon-create-square"></i> {{ $t('buttons.add') }}</span>
|
||||
</div>
|
||||
</template>
|
||||
</select-group>
|
||||
|
||||
@@ -151,7 +151,7 @@ export default {
|
||||
prop: 'ping',
|
||||
show: true
|
||||
}, {
|
||||
label: this.$t('config.assetState.monitor'),
|
||||
label: this.$t('config.system.monitor.monitor'),
|
||||
prop: 'monitor',
|
||||
show: true
|
||||
}, {
|
||||
|
||||
@@ -1,2 +1 @@
|
||||
{"baseUrl":"/", "version": "22.05"}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user