Merge branch 'dev-3.4' of git.mesalab.cn:nezha/nezha-fronted into dev-3.4

This commit is contained in:
zyh
2022-06-30 15:55:07 +08:00
6 changed files with 66 additions and 25 deletions

View File

@@ -567,3 +567,7 @@
}
}
}
.el-table__body-wrapper {
overflow: auto;
background-color: $--table-body-background-color;
}

View File

@@ -149,3 +149,14 @@
vertical-align: bottom;
color: $--color-text-primary;
}
.panel{
.right-box-chart{
.ͼ2 .cm-content{
caret-color:$--color-text-regular;
}
.ͼ1.cm-editor.cm-focused{
outline: 0px;
padding-left: 5px;
}
}
}

View File

@@ -195,7 +195,7 @@
<div v-if="editAsset.showSSH">
<el-form-item :label="$t('asset.authType')" prop="authType">
<el-select v-model="editAsset.authType" class="right-box__select" :placeholder="$t('el.select.placeholder')" popper-class="right-box-select-top prevent-clickoutside" size="small" value-key="value" clearable>
<el-option v-for="type in assetConstants.authTypeOptions" :key="type.value" :label="type.label" :value="type.value"/>
<el-option v-for="type in assetConstants.authTypeOptions" :key="type.value" :label="$t(type.label)" :value="type.value"/>
</el-select>
</el-form-item>
<el-form-item :label="$t('profile.username')" prop="authUsername">

View File

@@ -194,6 +194,7 @@
:format="timeFormatStrToDatePickFormat(dateFormatStr)"
popper-class="panel-time-picker-popper right-box-select-top"
prefix-icon=" "
@change="changeData(true)"
size="mini"
type="datetime">
</my-date-picker>
@@ -208,6 +209,7 @@
:format="timeFormatStrToDatePickFormat(dateFormatStr)"
popper-class="panel-time-picker-popper right-box-select-top"
prefix-icon=" "
@change="changeData(false)"
size="mini"
type="datetime">
</my-date-picker>
@@ -577,6 +579,23 @@ export default {
}).catch(() => {
this.prevent_opt.save = false
})
},
changeData (flag) {
if (flag) {
if (this.editPanel.param.report.schedule.etime) {
if (this.editPanel.param.report.schedule.stime > this.editPanel.param.report.schedule.etime) {
this.editPanel.param.report.schedule.stime = ''
this.$message.error(this.$t('alert.silence.timeError'))
}
}
} else {
if (this.editPanel.param.report.schedule.stime) {
if (this.editPanel.param.report.schedule.stime > this.editPanel.param.report.schedule.etime) {
this.editPanel.param.report.schedule.etime = ''
this.$message.error(this.$t('alert.silence.timeError'))
}
}
}
}
},
watch: {

View File

@@ -37,7 +37,7 @@
<el-option v-for="item in langList" :key="item.value" :label="item.name" :value="item.value"></el-option>
</el-select>
</el-form-item>
<el-form-item label="Theme" prop="theme">
<el-form-item :label="$t('config.user.Theme')" prop="theme">
<el-select id="account-input-language"
class="right-box__select"
v-model="editProfile.theme"

View File

@@ -92,6 +92,7 @@
<div id="tableList" class="table-list" style='overflow-y: unset'>
<div class="table-list-box">
<div id="dashboardScrollbar" class="box-content" v-my-loading="chartListLoading" ref="dashboardScrollbar" style='overflow-y: auto'>
<!-- <panel-variables :arr="this.showPanel.variables"></panel-variables>-->
<chart-list
ref="chartList"
name="panel"
@@ -778,6 +779,12 @@ export default {
this.$message.error(response)
}
}
this.showPanel.param = {
report:
{ enable: true, range: { type: 'previous', interval: 1, unit: 'day' }, schedule: { type: 2, repeat: 1, nums: [], stime: '2022-06-07 15:00:00', etime: '2022-06-19 15:00:00' }, receivers: [1] },
chartShare: 'none',
variables: [{ show: true, type: 'custom', multi: true, allOption: true, name: 'a', customOptions: 'z:1', expression: '', regex: '' }]
}
}).catch((error) => {
// console.log('error................'+JSON.stringify(error));
if (error) {