mirror of
https://github.com/freqtrade/frequi.git
synced 2024-11-14 12:13:52 +00:00
Move Timerange to btStore
This commit is contained in:
parent
888ba6faf8
commit
06f64c9ab9
|
@ -6,6 +6,7 @@ export const useBtStore = defineStore('btStore', {
|
||||||
strategy: '',
|
strategy: '',
|
||||||
selectedTimeframe: '',
|
selectedTimeframe: '',
|
||||||
selectedDetailTimeframe: '',
|
selectedDetailTimeframe: '',
|
||||||
|
timerange: '',
|
||||||
freqAI: {
|
freqAI: {
|
||||||
enabled: false,
|
enabled: false,
|
||||||
model: '',
|
model: '',
|
||||||
|
|
|
@ -253,7 +253,7 @@
|
||||||
></b-form-input>
|
></b-form-input>
|
||||||
</b-form-group> -->
|
</b-form-group> -->
|
||||||
<hr />
|
<hr />
|
||||||
<TimeRangeSelect v-model="timerange" class="mt-2"></TimeRangeSelect>
|
<TimeRangeSelect v-model="btStore.timerange" class="mt-2"></TimeRangeSelect>
|
||||||
</b-form-group>
|
</b-form-group>
|
||||||
</b-card>
|
</b-card>
|
||||||
|
|
||||||
|
@ -313,7 +313,7 @@
|
||||||
<BacktestResultChart
|
<BacktestResultChart
|
||||||
:timeframe="timeframe"
|
:timeframe="timeframe"
|
||||||
:strategy="btStore.strategy"
|
:strategy="btStore.strategy"
|
||||||
:timerange="timerange"
|
:timerange="btStore.timerange"
|
||||||
:pairlist="botStore.activeBot.selectedBacktestResult.pairlist"
|
:pairlist="botStore.activeBot.selectedBacktestResult.pairlist"
|
||||||
:trades="botStore.activeBot.selectedBacktestResult.trades"
|
:trades="botStore.activeBot.selectedBacktestResult.trades"
|
||||||
:freqai-model="freqAI.enabled ? freqAI.model : undefined"
|
:freqai-model="freqAI.enabled ? freqAI.model : undefined"
|
||||||
|
@ -357,7 +357,6 @@ const timeframe = computed((): string => {
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
|
|
||||||
const timerange = ref('');
|
|
||||||
const showLeftBar = ref(false);
|
const showLeftBar = ref(false);
|
||||||
const freqAI = ref({
|
const freqAI = ref({
|
||||||
enabled: false,
|
enabled: false,
|
||||||
|
@ -381,7 +380,7 @@ const selectBacktestResult = () => {
|
||||||
btStore.selectedDetailTimeframe =
|
btStore.selectedDetailTimeframe =
|
||||||
botStore.activeBot.selectedBacktestResult.timeframe_detail || '';
|
botStore.activeBot.selectedBacktestResult.timeframe_detail || '';
|
||||||
// TODO: maybe this should not use timerange, but the actual backtest start/end results instead?
|
// TODO: maybe this should not use timerange, but the actual backtest start/end results instead?
|
||||||
timerange.value = botStore.activeBot.selectedBacktestResult.timerange;
|
btStore.timerange = botStore.activeBot.selectedBacktestResult.timerange;
|
||||||
};
|
};
|
||||||
|
|
||||||
watch(
|
watch(
|
||||||
|
@ -394,7 +393,7 @@ watch(
|
||||||
const clickBacktest = () => {
|
const clickBacktest = () => {
|
||||||
const btPayload: BacktestPayload = {
|
const btPayload: BacktestPayload = {
|
||||||
strategy: btStore.strategy,
|
strategy: btStore.strategy,
|
||||||
timerange: timerange.value,
|
timerange: btStore.timerange,
|
||||||
enable_protections: enableProtections.value,
|
enable_protections: enableProtections.value,
|
||||||
};
|
};
|
||||||
const openTradesInt = parseInt(maxOpenTrades.value, 10);
|
const openTradesInt = parseInt(maxOpenTrades.value, 10);
|
||||||
|
|
Loading…
Reference in New Issue
Block a user