Merge remote-tracking branch 'origin/dev' into dev

Raod 3 years ago
commit c4fe52a4d3

@ -5717,6 +5717,18 @@ const widgetTools = [
placeholder: '',
value: ''
},
{
type: 'el-select',
label: '堆叠样式',
name: 'stackStyle',
required: false,
placeholder: '',
selectOptions: [
{code: 'leftRight', name: '左右堆叠'},
{code: 'upDown', name: '上下堆叠'},
],
value: 'leftRight'
},
[
{
name: '柱体设置',
@ -6090,7 +6102,7 @@ const widgetTools = [
},
],
},
/*{
{
name: '坐标轴边距设置',
list: [
{
@ -6123,13 +6135,13 @@ const widgetTools = [
value: 10,
},
],
},*/
/*{
},
{
name: '图例操作',
list: [
{
type: 'el-switch',
label: '图例',
label: '显示',
name: 'isShowLegend',
required: false,
placeholder: '',
@ -6197,7 +6209,7 @@ const widgetTools = [
value: 'horizontal'
},
],
},*/
},
/*{
name: '自定义配色',
list: [

@ -98,8 +98,8 @@ export default {
this.setOptionsY();
this.setOptionsTop();
this.setOptionsTooltip();
//this.setOptionsMargin();
//this.setOptionsLegend();
this.setOptionsMargin();
this.setOptionsLegend();
//this.setOptionsColor();
this.setOptionsData();
},
@ -121,7 +121,6 @@ export default {
fontWeight: optionsCollapse.subTextFontWeight,
fontSize: optionsCollapse.subTextFontSize
};
this.options.title = title;
},
// X
@ -216,18 +215,18 @@ export default {
this.options.series = series;
},
// tooltip
setOptionsTooltip() {
const optionsCollapse = this.optionsSetup;
const tooltip = {
trigger: "item",
show: true,
textStyle: {
color: optionsCollapse.lineColor,
fontSize: optionsCollapse.tipsFontSize
}
};
this.options.tooltip = tooltip;
},
setOptionsTooltip() {
const optionsCollapse = this.optionsSetup;
const tooltip = {
trigger: "item",
show: true,
textStyle: {
color: optionsCollapse.lineColor,
fontSize: optionsCollapse.tipsFontSize
}
};
this.options.tooltip = tooltip;
},
//
setOptionsMargin() {
const optionsCollapse = this.optionsSetup;
@ -245,15 +244,14 @@ export default {
const optionsCollapse = this.optionsSetup;
const legend = this.options.legend;
legend.show = optionsCollapse.isShowLegend;
legend.left = optionsCollapse.lateralPosition == "left" ? 0 : "auto";
legend.right = optionsCollapse.lateralPosition == "right" ? 0 : "auto";
legend.left = optionsCollapse.lateralPosition;
legend.top = optionsCollapse.longitudinalPosition == "top" ? 0 : "auto";
legend.bottom =
optionsCollapse.longitudinalPosition == "bottom" ? 0 : "auto";
legend.orient = optionsCollapse.layoutFront;
legend.textStyle = {
color: optionsCollapse.lengedColor,
fontSize: optionsCollapse.fontSize
fontSize: optionsCollapse.lengedFontSize
};
legend.itemWidth = optionsCollapse.lengedWidth;
},
@ -301,6 +299,15 @@ export default {
});
return newArr;
},
//
getStackStyle() {
const optionsSetup = this.optionsSetup;
let style = ""
if (optionsSetup.stackStyle == "upDown") {
style = "total"
}
return style
},
//
staticDataFn(val) {
const optionsSetup = this.optionsSetup;
@ -329,8 +336,9 @@ export default {
type: "bar",
data: data,
barGap: "0%",
barWidth : optionsSetup.maxWidth,
label : {
stack: this.getStackStyle(),
barWidth: optionsSetup.maxWidth,
label: {
show: optionsSetup.isShow,
position: "top",
distance: 10,

Loading…
Cancel
Save