Add buy/sell signa count to interface

This commit is contained in:
Matthias 2020-09-27 09:24:12 +02:00
parent 58160f35c5
commit 218212e301
2 changed files with 9 additions and 1 deletions

View File

@ -17,6 +17,10 @@
<div class="col-mb-2 ml-2 mr-2">
<b-button :disabled="!!!pair" size="sm" @click="refresh">&#x21bb;</b-button>
</div>
<div class="col-mb-2 ml-2 mr-2">
<small>Buysignals: {{ dataset.buy_signals }}</small>
<small class="ml-2">SellSignals: {{ dataset.sell_signals }}</small>
</div>
<div class="col-mb-2 ml-auto mr-2">
<b-select
v-model="plotConfigName"
@ -103,7 +107,7 @@ export default class CandleChartContainer extends Vue {
// eslint-disable-next-line @typescript-eslint/no-unused-vars
@ftbot.Action public getPairHistory!: (payload: PairHistoryPayload) => void;
get dataset() {
get dataset(): PairHistory {
if (this.historicView) {
return this.history[`${this.pair}__${this.timeframe}`];
}

View File

@ -186,6 +186,10 @@ export interface PairHistory {
columns: string[];
data: number[];
length: number;
/** Number of buy signals in this response */
buy_signals: number;
/** Number of sell signals in this response */
sell_signals: number;
last_analyzed: number;
/** Data start date in as millisecond timestamp */
data_start_ts: number;