mirror of
https://gitee.com/anji-plus/report.git
synced 2026-05-20 08:47:18 +08:00
feat--增加柱状图柱体间距调整
This commit is contained in:
@@ -33,7 +33,7 @@ export const widgetBarDoubleYaxis = {
|
||||
name: 'maxWidth',
|
||||
required: false,
|
||||
placeholder: '',
|
||||
value: 10,
|
||||
value: 15,
|
||||
},
|
||||
{
|
||||
type: 'el-slider',
|
||||
@@ -43,6 +43,14 @@ export const widgetBarDoubleYaxis = {
|
||||
placeholder: '',
|
||||
value: 5,
|
||||
},
|
||||
{
|
||||
type: 'el-slider',
|
||||
label: '间距',
|
||||
name: 'barGap',
|
||||
required: false,
|
||||
placeholder: '',
|
||||
value: 10,
|
||||
},
|
||||
{
|
||||
type: 'el-slider',
|
||||
label: '最小高度',
|
||||
|
||||
@@ -34,7 +34,7 @@ export const widgetBarStackMoreShow = {
|
||||
name: 'maxWidth',
|
||||
required: false,
|
||||
placeholder: '',
|
||||
value: 25,
|
||||
value: 15,
|
||||
},
|
||||
{
|
||||
type: 'el-slider',
|
||||
@@ -44,6 +44,14 @@ export const widgetBarStackMoreShow = {
|
||||
placeholder: '',
|
||||
value: 5,
|
||||
},
|
||||
{
|
||||
type: 'el-slider',
|
||||
label: '间距',
|
||||
name: 'barGap',
|
||||
required: false,
|
||||
placeholder: '',
|
||||
value: 10,
|
||||
},
|
||||
{
|
||||
type: 'el-switch',
|
||||
label: '背景显示',
|
||||
|
||||
@@ -61,7 +61,7 @@ export const widgetBarStack = {
|
||||
name: 'maxWidth',
|
||||
required: false,
|
||||
placeholder: '',
|
||||
value: 20,
|
||||
value: 15,
|
||||
},
|
||||
{
|
||||
type: 'el-slider',
|
||||
@@ -77,7 +77,7 @@ export const widgetBarStack = {
|
||||
name: 'barGap',
|
||||
required: false,
|
||||
placeholder: '',
|
||||
value: 0,
|
||||
value: 10,
|
||||
},
|
||||
{
|
||||
type: 'el-switch',
|
||||
|
||||
@@ -49,7 +49,7 @@ export const widgetBarchart = {
|
||||
name: 'maxWidth',
|
||||
required: false,
|
||||
placeholder: '',
|
||||
value: 10,
|
||||
value: 15,
|
||||
},
|
||||
{
|
||||
type: 'el-slider',
|
||||
@@ -59,6 +59,14 @@ export const widgetBarchart = {
|
||||
placeholder: '',
|
||||
value: 5,
|
||||
},
|
||||
{
|
||||
type: 'el-slider',
|
||||
label: '间距',
|
||||
name: 'barGap',
|
||||
required: false,
|
||||
placeholder: '',
|
||||
value: 10,
|
||||
},
|
||||
{
|
||||
type: 'el-slider',
|
||||
label: '最小高度',
|
||||
|
||||
@@ -49,7 +49,7 @@ export const widgetGradientBarchart = {
|
||||
name: 'maxWidth',
|
||||
required: false,
|
||||
placeholder: '',
|
||||
value: 10,
|
||||
value: 15,
|
||||
},
|
||||
{
|
||||
type: 'el-slider',
|
||||
@@ -59,6 +59,14 @@ export const widgetGradientBarchart = {
|
||||
placeholder: '',
|
||||
value: 5,
|
||||
},
|
||||
{
|
||||
type: 'el-slider',
|
||||
label: '间距',
|
||||
name: 'barGap',
|
||||
required: false,
|
||||
placeholder: '',
|
||||
value: 10,
|
||||
},
|
||||
{
|
||||
type: 'el-switch',
|
||||
label: '背景显示',
|
||||
|
||||
@@ -312,6 +312,7 @@ export default {
|
||||
const series = this.options.series;
|
||||
for (const key in series) {
|
||||
if (series[key].type == "bar") {
|
||||
series[key].barGap = optionsSetup.barGap + "%";
|
||||
series[key].label = {
|
||||
show: optionsSetup.isShow,
|
||||
position: optionsSetup.fontPosition,
|
||||
|
||||
@@ -348,7 +348,7 @@ export default {
|
||||
name: item.name,
|
||||
type: "bar",
|
||||
data: item.list.map((item) => item.data),
|
||||
barGap: "0%",
|
||||
barGap: optionsSetup.barGap + "%",
|
||||
barWidth: optionsSetup.maxWidth,
|
||||
label: {
|
||||
show: optionsSetup.isShow,
|
||||
@@ -449,7 +449,7 @@ export default {
|
||||
name: item.name,
|
||||
type: "bar",
|
||||
data: item.list.map((item) => item.data),
|
||||
barGap: "0%",
|
||||
barGap: optionsSetup.barGap + "%",
|
||||
barWidth: optionsSetup.maxWidth,
|
||||
label: {
|
||||
show: optionsSetup.isShow,
|
||||
|
||||
@@ -348,7 +348,7 @@ export default {
|
||||
for (const i in series) {
|
||||
if (series[i].type == "bar") {
|
||||
series[i].type = "bar";
|
||||
series[i].barGap = "0%";
|
||||
series[i].barGap = optionsSetup.barGap + "%";
|
||||
series[i].barWidth = optionsSetup.maxWidth;
|
||||
series[i].barMinHeight = optionsSetup.minHeight;
|
||||
series[i].label = {
|
||||
@@ -468,7 +468,7 @@ export default {
|
||||
const obj = {};
|
||||
if (val.series[i].type == "bar") {
|
||||
obj.type = "bar";
|
||||
obj.barGap = "0%";
|
||||
obj.barGap = optionsSetup.barGap + "%";
|
||||
obj.stack = this.getStackStyle();
|
||||
obj.barWidth = optionsSetup.maxWidth;
|
||||
obj.barMinHeight = optionsSetup.minHeight;
|
||||
|
||||
@@ -306,6 +306,7 @@ export default {
|
||||
const optionsSetup = this.optionsSetup;
|
||||
const series = this.options.series;
|
||||
if (series[0].type == "bar") {
|
||||
series[0].barGap = optionsSetup.barGap + "%";
|
||||
series[0].label = {
|
||||
show: optionsSetup.isShow,
|
||||
position: optionsSetup.fontPosition,
|
||||
|
||||
Reference in New Issue
Block a user