fix:解决冲突
This commit is contained in:
@@ -177,18 +177,11 @@ export default {
|
|||||||
this.legends = []
|
this.legends = []
|
||||||
this.series = chartOption.series = this.handleTimeSeries(this.chartInfo, chartOption.series[0], this.chartData) // 生成series和legends
|
this.series = chartOption.series = this.handleTimeSeries(this.chartInfo, chartOption.series[0], this.chartData) // 生成series和legends
|
||||||
|
|
||||||
const styleOption = this.$lodash.get(this.chartInfo, 'param.option', {})
|
|
||||||
chartOption.series.forEach(item => {
|
chartOption.series.forEach(item => {
|
||||||
if (item.lineStyle && styleOption.lineWidth != undefined) {
|
if (item.lineStyle) {
|
||||||
item.lineStyle.width = styleOption.lineWidth
|
|
||||||
} else if (item.lineStyle) {
|
|
||||||
item.lineStyle.width = this.lineOption.lineWidth
|
item.lineStyle.width = this.lineOption.lineWidth
|
||||||
}
|
}
|
||||||
if (styleOption.pointSize != undefined) {
|
item.symbolSize = this.lineOption.pointSize
|
||||||
item.symbolSize = styleOption.pointSize
|
|
||||||
} else {
|
|
||||||
item.symbolSize = this.lineOption.pointSize
|
|
||||||
}
|
|
||||||
})
|
})
|
||||||
|
|
||||||
this.isGrey = this.legends.map(() => false)
|
this.isGrey = this.legends.map(() => false)
|
||||||
|
|||||||
@@ -251,7 +251,6 @@ export default {
|
|||||||
max: undefined
|
max: undefined
|
||||||
},
|
},
|
||||||
dataLink: [],
|
dataLink: [],
|
||||||
option: undefined
|
|
||||||
},
|
},
|
||||||
elements: [{ expression: '', legend: '', type: 'expert', id: '', name: 'A', state: 1, orderNum: 0 }],
|
elements: [{ expression: '', legend: '', type: 'expert', id: '', name: 'A', state: 1, orderNum: 0 }],
|
||||||
panel: '',
|
panel: '',
|
||||||
|
|||||||
@@ -454,44 +454,6 @@
|
|||||||
</el-form-item>
|
</el-form-item>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<!-- option -->
|
|
||||||
<div v-if="isTimeSeries(chartConfig.type)">
|
|
||||||
<div class="form__sub-title">
|
|
||||||
<span>{{$t('dashboard.dashboard.chartForm.option')}}</span>
|
|
||||||
</div>
|
|
||||||
<div
|
|
||||||
class="form-items--half-width-group"
|
|
||||||
>
|
|
||||||
<!--lineWidth-->
|
|
||||||
<el-form-item
|
|
||||||
v-if="chartConfig.type!=='point'"
|
|
||||||
:label="$t('dashboard.dashboard.chartForm.lineWidth')"
|
|
||||||
class="form-item--half-width"
|
|
||||||
prop="param.option.lineWidth"
|
|
||||||
>
|
|
||||||
<el-input-number
|
|
||||||
size="small"
|
|
||||||
:controls="false"
|
|
||||||
@change="change"
|
|
||||||
show-word-limit
|
|
||||||
v-model="chartConfig.param.option.lineWidth"/>
|
|
||||||
</el-form-item>
|
|
||||||
<!--pointSize-->
|
|
||||||
<el-form-item
|
|
||||||
:label="$t('dashboard.dashboard.chartForm.pointSize')"
|
|
||||||
class="form-item--half-width"
|
|
||||||
prop="param.option.pointSize"
|
|
||||||
>
|
|
||||||
<el-input-number
|
|
||||||
size="small"
|
|
||||||
:controls="false"
|
|
||||||
@change="change"
|
|
||||||
show-word-limit
|
|
||||||
v-model="chartConfig.param.option.pointSize"/>
|
|
||||||
</el-form-item>
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
|
|
||||||
<!-- Right Y Axis -->
|
<!-- Right Y Axis -->
|
||||||
<div v-if="isTimeSeries(chartConfig.type)">
|
<div v-if="isTimeSeries(chartConfig.type)">
|
||||||
<div class="form__sub-title">
|
<div class="form__sub-title">
|
||||||
@@ -1352,9 +1314,6 @@ export default {
|
|||||||
minStep () {
|
minStep () {
|
||||||
return this.nzDefaultConfig.minStep
|
return this.nzDefaultConfig.minStep
|
||||||
},
|
},
|
||||||
lineOption () {
|
|
||||||
return this.nzDefaultConfig.option
|
|
||||||
}
|
|
||||||
},
|
},
|
||||||
data () {
|
data () {
|
||||||
return {
|
return {
|
||||||
@@ -1449,8 +1408,7 @@ export default {
|
|||||||
min: undefined,
|
min: undefined,
|
||||||
max: undefined
|
max: undefined
|
||||||
},
|
},
|
||||||
dataLink: this.chartConfig.param.dataLink,
|
dataLink: this.chartConfig.param.dataLink
|
||||||
option: this.lineOption
|
|
||||||
}
|
}
|
||||||
this.$nextTick(() => {
|
this.$nextTick(() => {
|
||||||
this.chartConfig.param.thresholds.push({ value: undefined, color: randomcolor() })
|
this.chartConfig.param.thresholds.push({ value: undefined, color: randomcolor() })
|
||||||
|
|||||||
@@ -173,9 +173,6 @@ export default {
|
|||||||
panelChart
|
panelChart
|
||||||
},
|
},
|
||||||
computed: {
|
computed: {
|
||||||
lineOption () {
|
|
||||||
return this.nzDefaultConfig.option
|
|
||||||
},
|
|
||||||
chartLastPosition () {
|
chartLastPosition () {
|
||||||
return this.$store.getters.getChartLastPosition
|
return this.$store.getters.getChartLastPosition
|
||||||
},
|
},
|
||||||
@@ -412,7 +409,6 @@ export default {
|
|||||||
max: undefined
|
max: undefined
|
||||||
},
|
},
|
||||||
dataLink: [],
|
dataLink: [],
|
||||||
option: this.lineOption
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@@ -645,9 +641,6 @@ export default {
|
|||||||
max: undefined
|
max: undefined
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
if (!obj.param.option) {
|
|
||||||
obj.param.option = this.lineOption
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
this.editChart = this.$lodash.cloneDeep(obj)
|
this.editChart = this.$lodash.cloneDeep(obj)
|
||||||
this.oldData = this.$lodash.cloneDeep(obj)
|
this.oldData = this.$lodash.cloneDeep(obj)
|
||||||
|
|||||||
@@ -266,8 +266,7 @@ export default {
|
|||||||
min: undefined,
|
min: undefined,
|
||||||
max: undefined
|
max: undefined
|
||||||
},
|
},
|
||||||
dataLink: [],
|
dataLink: []
|
||||||
option: undefined
|
|
||||||
},
|
},
|
||||||
elements: [{ expression: '', legend: '', type: 'expert', id: '', name: 'A', state: 1, orderNum: 0, step: undefined }],
|
elements: [{ expression: '', legend: '', type: 'expert', id: '', name: 'A', state: 1, orderNum: 0, step: undefined }],
|
||||||
panel: '',
|
panel: '',
|
||||||
|
|||||||
Reference in New Issue
Block a user