mirror of
https://github.com/freqtrade/frequi.git
synced 2024-11-11 02:33:51 +00:00
Support plot-config changes again
This commit is contained in:
parent
c90b3b11ce
commit
654a7eef3b
|
@ -45,26 +45,22 @@ export default class CandleChart extends Vue {
|
||||||
|
|
||||||
@Prop({ required: true }) plotConfig!: PlotConfig;
|
@Prop({ required: true }) plotConfig!: PlotConfig;
|
||||||
|
|
||||||
// Only recalculate buy / sell data if necessary
|
|
||||||
signalsCalculated = false;
|
|
||||||
|
|
||||||
buyData = [] as Array<number>[];
|
buyData = [] as Array<number>[];
|
||||||
|
|
||||||
sellData = [] as Array<number>[];
|
sellData = [] as Array<number>[];
|
||||||
|
|
||||||
chartOptions: echarts.EChartOption = {};
|
chartOptions: echarts.EChartOption = {};
|
||||||
|
|
||||||
@Watch('timeframe')
|
|
||||||
timeframeChanged() {
|
|
||||||
this.signalsCalculated = false;
|
|
||||||
}
|
|
||||||
|
|
||||||
@Watch('dataset')
|
@Watch('dataset')
|
||||||
datasetChanged() {
|
datasetChanged() {
|
||||||
this.signalsCalculated = false;
|
|
||||||
this.updateChart();
|
this.updateChart();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@Watch('plotConfig')
|
||||||
|
plotConfigChanged() {
|
||||||
|
this.initializeChartOptions();
|
||||||
|
}
|
||||||
|
|
||||||
get strategy() {
|
get strategy() {
|
||||||
return this.dataset ? this.dataset.strategy : '';
|
return this.dataset ? this.dataset.strategy : '';
|
||||||
}
|
}
|
||||||
|
@ -107,6 +103,7 @@ export default class CandleChart extends Vue {
|
||||||
useUTC: this.useUTC,
|
useUTC: this.useUTC,
|
||||||
animation: false,
|
animation: false,
|
||||||
legend: {
|
legend: {
|
||||||
|
// Initial legend, further entries are pushed to the below list
|
||||||
data: ['Candles', 'Volume', 'Buy', 'Sell'],
|
data: ['Candles', 'Volume', 'Buy', 'Sell'],
|
||||||
right: '1%',
|
right: '1%',
|
||||||
},
|
},
|
||||||
|
|
Loading…
Reference in New Issue
Block a user