mirror of
https://gitee.com/anji-plus/report.git
synced 2026-02-02 09:27:47 +08:00
feat--折线图数据设定增加是否显示百分比符号
This commit is contained in:
@@ -568,6 +568,14 @@ export const widgetLineStack = {
|
||||
placeholder: '',
|
||||
value: false
|
||||
},
|
||||
{
|
||||
type: 'el-switch',
|
||||
label: '百分比符号显示',
|
||||
name: 'percentSign',
|
||||
required: false,
|
||||
placeholder: '',
|
||||
value: false
|
||||
},
|
||||
{
|
||||
type: 'el-input-number',
|
||||
label: '字体字号',
|
||||
|
||||
@@ -560,6 +560,14 @@ export const widgetLinechart = {
|
||||
placeholder: '',
|
||||
value: false
|
||||
},
|
||||
{
|
||||
type: 'el-switch',
|
||||
label: '百分比符号显示',
|
||||
name: 'percentSign',
|
||||
required: false,
|
||||
placeholder: '',
|
||||
value: false
|
||||
},
|
||||
{
|
||||
type: 'el-input-number',
|
||||
label: '字体字号',
|
||||
|
||||
@@ -400,6 +400,7 @@ export default {
|
||||
fontSize: optionsSetup.fontSize,
|
||||
color: optionsSetup.dataColor,
|
||||
fontWeight: optionsSetup.fontWeight,
|
||||
formatter: !!optionsSetup.percentSign ? '{c}%' : '{c}'
|
||||
},
|
||||
});
|
||||
legendName.push(yAxisList[i]);
|
||||
@@ -488,6 +489,7 @@ export default {
|
||||
fontSize: optionsSetup.fontSize,
|
||||
color: optionsSetup.dataColor,
|
||||
fontWeight: optionsSetup.fontWeight,
|
||||
formatter: !!optionsSetup.percentSign ? '{c}%' : '{c}'
|
||||
},
|
||||
});
|
||||
}
|
||||
|
||||
@@ -364,6 +364,7 @@ export default {
|
||||
fontSize: optionsSetup.fontSize,
|
||||
color: optionsSetup.dataColor,
|
||||
fontWeight: optionsSetup.fontWeight,
|
||||
formatter: !!optionsSetup.percentSign ? '{c}%' : '{c}'
|
||||
};
|
||||
series[i].data = data;
|
||||
this.options.legend["data"] = legendName;
|
||||
@@ -434,6 +435,7 @@ export default {
|
||||
fontSize: optionsSetup.fontSize,
|
||||
color: optionsSetup.dataColor,
|
||||
fontWeight: optionsSetup.fontWeight,
|
||||
formatter: !!optionsSetup.percentSign ? '{c}%' : '{c}'
|
||||
};
|
||||
obj.data = val.series[i].data;
|
||||
series.push(obj);
|
||||
|
||||
Reference in New Issue
Block a user