fix: 修改 tooltip type 无法选择的问题
This commit is contained in:
@@ -953,7 +953,10 @@
|
|||||||
{{$t('overall.type')}}
|
{{$t('overall.type')}}
|
||||||
</div>
|
</div>
|
||||||
<div class="form-row-value">
|
<div class="form-row-value">
|
||||||
<el-input v-model="pen.data.tooltip.chartType" />
|
<!-- <el-input v-model="pen.data.tooltip.chartType" />-->
|
||||||
|
<el-select v-model="pen.data.tooltip.chartType" size="small" style="width: 100%">
|
||||||
|
<el-option v-for="item in chartType" :key="item.id" :value="item.id" :label='item.name'></el-option>
|
||||||
|
</el-select>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
<div class="form-row-item form-row-item-full">
|
<div class="form-row-item form-row-item-full">
|
||||||
@@ -1035,6 +1038,11 @@ export default {
|
|||||||
return {
|
return {
|
||||||
theme: theme,
|
theme: theme,
|
||||||
pen: {},
|
pen: {},
|
||||||
|
chartType: [
|
||||||
|
{ id: 'line', name: 'Line' },
|
||||||
|
{ id: 'area', name: 'Area' },
|
||||||
|
{ id: 'text', name: 'Text' }
|
||||||
|
],
|
||||||
penDash: [
|
penDash: [
|
||||||
{ d: 'M5 14 l85 0', 'stroke-dasharray': '', strokeColor: theme == 'light' ? 'black' : '#BEBEBE' },
|
{ d: 'M5 14 l85 0', 'stroke-dasharray': '', strokeColor: theme == 'light' ? 'black' : '#BEBEBE' },
|
||||||
{ d: 'M5 14 l85 0', 'stroke-dasharray': '5,5', strokeColor: theme == 'light' ? 'black' : '#BEBEBE' },
|
{ d: 'M5 14 l85 0', 'stroke-dasharray': '5,5', strokeColor: theme == 'light' ? 'black' : '#BEBEBE' },
|
||||||
|
|||||||
@@ -47,6 +47,9 @@ export default {
|
|||||||
params: {
|
params: {
|
||||||
immediate: true,
|
immediate: true,
|
||||||
handler (n) {
|
handler (n) {
|
||||||
|
if (this.params.chartType == 'text') {
|
||||||
|
return
|
||||||
|
}
|
||||||
this.chartInfo.type = this.params.chartType || 'line'
|
this.chartInfo.type = this.params.chartType || 'line'
|
||||||
const chartData = []
|
const chartData = []
|
||||||
const elements = []
|
const elements = []
|
||||||
|
|||||||
Reference in New Issue
Block a user