Merge remote-tracking branch 'origin/dev-3.1' into dev-3.1.1_theme
# Conflicts: # nezha-fronted/src/components/common/i18n.js # nezha-fronted/src/components/common/pagination.vue # nezha-fronted/src/components/common/searchInput.vue # nezha-fronted/src/components/common/table/settings/endpointTable.vue # nezha-fronted/src/components/page/dashboard/overview/overview2.vue
This commit is contained in:
@@ -121,7 +121,7 @@
|
||||
</el-form-item>-->
|
||||
<!--lock-->
|
||||
<el-form-item v-if="editChart.type ==='diagram'" :label="$t('dashboard.panel.chartForm.lock')" class="form-item--half-width" prop="lock">
|
||||
<el-select id="chart-box-statistics" v-model="editChart.param.lock" placeholder="" popper-class="right-box-select-top prevent-clickoutside" size="small" @change="$forceUpdate">
|
||||
<el-select id="chart-box-statistics" v-model="editChart.param.lock" placeholder="" popper-class="right-box-select-top prevent-clickoutside" size="small" @change="$forceUpdate()">
|
||||
<el-option v-for="item in lockList" :key="item.value" :label="$t(item.label)" :value="item.value">
|
||||
<span class="panel-dropdown-label-txt" >{{$t(item.label)}}</span>
|
||||
</el-option>
|
||||
@@ -149,7 +149,7 @@
|
||||
</el-form-item>
|
||||
|
||||
<el-form-item v-if="editChart.type == 'singleStat' || editChart.type == 'pie'|| editChart.type=='table' || editChart.type == 'bar'" :label="$t('dashboard.panel.chartForm.statistics')" class="form-item--half-width" prop="param.statistics">
|
||||
<el-select id="chart-box-statistics" v-model="editChart.param.statistics" placeholder="" popper-class="right-box-select-top prevent-clickoutside" size="small" @change="$forceUpdate">
|
||||
<el-select id="chart-box-statistics" v-model="editChart.param.statistics" placeholder="" popper-class="right-box-select-top prevent-clickoutside" size="small" @change="$forceUpdate()">
|
||||
<el-option v-for="item in statisticsList" :key="item.value" :label="$t(item.label)" :value="item.value">
|
||||
<span class="panel-dropdown-label-txt" >{{$t(item.label)}}</span>
|
||||
</el-option>
|
||||
@@ -274,11 +274,11 @@
|
||||
</el-radio-group>
|
||||
</el-form-item>
|
||||
<template v-if="(editChart.type == 'singleStat'||editChart.type == 'table')&&editChart.param.valueMapping.type == 'value'" id="chart-box-valueMapping-type1">
|
||||
<template v-for="(mapping, index) in editChart.param.valueMapping.mapping">
|
||||
<el-form-item :key="index" :label="$t('dashboard.panel.chartForm.valMapping.value')" class="form-item--half-width-other" prop="span" >
|
||||
<div v-for="(mapping, index) in editChart.param.valueMapping.mapping" :key="index">
|
||||
<el-form-item :label="$t('dashboard.panel.chartForm.valMapping.value')" class="form-item--half-width-other" prop="span" >
|
||||
<el-input v-model="mapping.value" size="small" style="display: inline-block;;" type="input"></el-input>
|
||||
</el-form-item>
|
||||
<el-form-item :key="index" :label="$t('dashboard.panel.chartForm.valMapping.text')" class="form-item--half-width-other form-item--half-width-other-two" prop="span">
|
||||
<el-form-item :label="$t('dashboard.panel.chartForm.valMapping.text')" class="form-item--half-width-other form-item--half-width-other-two" prop="span">
|
||||
<el-input v-model="mapping.text" size="small" style="display: inline-block;width:calc(100% - 80px);" type="input"></el-input>
|
||||
<!--颜色选择器 start-->
|
||||
<div class="color-show">
|
||||
@@ -287,11 +287,11 @@
|
||||
<!--颜色选择器 end-->
|
||||
<span class="nz-icon-minus-medium" style="margin-left: 7px;padding: 6px" @click="delMapping(index)"><i class="nz-icon nz-icon-minus" style="color: #EC7F66"></i></span>
|
||||
</el-form-item>
|
||||
</template>
|
||||
</div>
|
||||
</template>
|
||||
<template v-if="(editChart.type == 'singleStat'||editChart.type == 'table')&&editChart.param.valueMapping.type == 'range'" id="chart-box-valueMapping-type2">
|
||||
<template v-for="(mapping, index) in editChart.param.valueMapping.mapping">
|
||||
<div :key="index" class="form-item--half-width-other" style="display: inline-block;margin-left: 15px">
|
||||
<div v-for="(mapping, index) in editChart.param.valueMapping.mapping" :key="index">
|
||||
<div class="form-item--half-width-other" style="display: inline-block;margin-left: 15px">
|
||||
<el-form-item :label="$t('dashboard.panel.chartForm.valMapping.from')" class="one-third-form-item-left" prop="span" >
|
||||
<el-input v-model="mapping.from" size="small" type="input"></el-input>
|
||||
</el-form-item>
|
||||
@@ -299,17 +299,16 @@
|
||||
<el-input v-model="mapping.to" size="small" type="input"></el-input>
|
||||
</el-form-item>
|
||||
</div>
|
||||
<el-form-item :key="index" :label="$t('dashboard.panel.chartForm.valMapping.text')" class="form-item--half-width-other-two range" prop="span">
|
||||
<el-form-item :label="$t('dashboard.panel.chartForm.valMapping.text')" class="form-item--half-width-other-two range" prop="span">
|
||||
<el-input v-model="mapping.text" size="small" style="display: inline-block;width:calc(100% - 80px);" type="input" ></el-input>
|
||||
<!--颜色选择器 start-->
|
||||
<div class="color-show">
|
||||
<nezhaColor :color-val="mapping.color" :single="false" :value-arr="[{name:'bac',value:showPicker[index].bac,key:'bac'},{name:'text',value:showPicker[index].text,key:'text'}]" @colorChange="(val,key)=>{colorChange(mapping,key,val)}"/>
|
||||
</div>
|
||||
|
||||
<!--颜色选择器 end-->
|
||||
<span class="nz-icon-minus-medium" style="margin-left: 7px;padding: 6px" @click="delMapping(index)"><i class="nz-icon nz-icon-minus" style="color: #EC7F66"></i></span>
|
||||
</el-form-item>
|
||||
</template>
|
||||
</div>
|
||||
</template>
|
||||
|
||||
<!--value mapping end-->
|
||||
@@ -1545,6 +1544,7 @@ export default {
|
||||
})
|
||||
},
|
||||
valueMappingChange: function (value) {
|
||||
console.log(this.editChart.param.valueMapping.type)
|
||||
if (this.editChart.param.valueMapping.type == 'value') {
|
||||
this.editChart.param.valueMapping.mapping = [{ text: '', value: '', color: { bac: '#fff', text: '#000' } }]
|
||||
this.showPicker = [{ bac: false, text: false }]
|
||||
|
||||
Reference in New Issue
Block a user