feat(视图): 添加平滑折线

This commit is contained in:
junjie 2021-03-19 17:57:26 +08:00
parent 69ae877b0a
commit 811840da86
4 changed files with 7 additions and 1 deletions

View File

@ -637,7 +637,8 @@ export default {
line_symbol_none: '无',
pie_inner_radius: '内径',
pie_outer_radius: '外径',
funnel_width: '宽度'
funnel_width: '宽度',
line_smooth: '平滑折线'
},
dataset: {
datalist: '数据集',

View File

@ -11,6 +11,7 @@ export const DEFAULT_SIZE = {
lineType: 'solid',
lineSymbol: 'emptyCircle',
lineSymbolSize: 4,
lineSmooth: false,
pieInnerRadius: 0,
pieOuterRadius: 60,
funnelWidth: 80

View File

@ -27,6 +27,7 @@ export function baseLineOption(chart_option, chart) {
width: customAttr.size.lineWidth,
type: customAttr.size.lineType
}
y.smooth = customAttr.size.lineSmooth
}
y.type = 'line'
chart_option.legend.data.push(y.name)

View File

@ -42,6 +42,9 @@
<el-form-item :label="$t('chart.line_symbol_size')" class="form-item form-item-slider">
<el-slider v-model="sizeForm.lineSymbolSize" show-input :show-input-controls="false" input-size="mini" :min="0" :max="20" @change="changeBarSizeCase" />
</el-form-item>
<el-form-item :label="$t('chart.line_smooth')" class="form-item">
<el-checkbox v-model="sizeForm.lineSmooth" @change="changeBarSizeCase">{{ $t('chart.line_smooth') }}</el-checkbox>
</el-form-item>
</el-form>
<el-form v-if="chart.type && chart.type.includes('pie')" ref="sizeFormPie" :model="sizeForm" label-width="80px" size="mini">