From 7985a283fbdee6c9200b4246fbdb654908e1ef68 Mon Sep 17 00:00:00 2001 From: Matthias Date: Mon, 17 Aug 2020 07:05:51 +0200 Subject: [PATCH] Fix daily payload --- src/store/modules/ftbot.ts | 4 ++-- src/store/types.ts | 4 ++-- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/src/store/modules/ftbot.ts b/src/store/modules/ftbot.ts index 36fd51fc..8426d4d0 100644 --- a/src/store/modules/ftbot.ts +++ b/src/store/modules/ftbot.ts @@ -1,5 +1,5 @@ import { api } from '@/shared/apiService'; -import { BotState, BlacklistPayload, ForcebuyPayload, Logs } from '@/store/types'; +import { BotState, BlacklistPayload, ForcebuyPayload, Logs, DailyPayload } from '@/store/types'; export default { namespaced: true, @@ -123,7 +123,7 @@ export default { .then((result) => commit('updateBalance', result.data)) .catch(console.error); }, - getDaily({ commit }, payload = {}) { + getDaily({ commit }, payload: DailyPayload) { const { timescale = 20 } = payload; return api .get('/daily', { params: { timescale } }) diff --git a/src/store/types.ts b/src/store/types.ts index 7c6ada60..3b19cbc6 100644 --- a/src/store/types.ts +++ b/src/store/types.ts @@ -8,8 +8,8 @@ export interface BlacklistPayload { blacklist: Array; } -export interface DailyInterface { - timescale: number; +export interface DailyPayload { + timescale?: number; } export interface ForcebuyPayload {