mirror of
https://github.com/freqtrade/frequi.git
synced 2024-11-10 10:21:55 +00:00
Fix a few type problems
This commit is contained in:
parent
617bdfbe2b
commit
71fd236674
|
@ -49,7 +49,7 @@
|
|||
<b-popover
|
||||
title="Add to blacklist"
|
||||
target="blacklist-add-btn"
|
||||
triggers="click blur"
|
||||
triggers="click"
|
||||
:show.sync="blackListShow"
|
||||
>
|
||||
<form ref="form" @submit.prevent>
|
||||
|
|
|
@ -176,8 +176,8 @@ export default defineComponent({
|
|||
const resetForm = () => {
|
||||
console.log('resetForm');
|
||||
selectedPair.value = props.pair;
|
||||
price.value = null;
|
||||
stakeAmount.value = null;
|
||||
price.value = undefined;
|
||||
stakeAmount.value = undefined;
|
||||
if (botStore.activeBot.botApiVersion > 1.1) {
|
||||
ordertype.value =
|
||||
botStore.activeBot.botState?.order_types?.forcebuy ||
|
||||
|
|
|
@ -27,7 +27,7 @@ import { defineComponent, computed, onMounted } from 'vue';
|
|||
export default defineComponent({
|
||||
name: 'StrategySelect',
|
||||
props: {
|
||||
value: { type: String, required: true },
|
||||
modelValue: { type: String, required: true },
|
||||
showDetails: { default: false, required: false, type: Boolean },
|
||||
},
|
||||
emits: ['input'],
|
||||
|
@ -37,7 +37,7 @@ export default defineComponent({
|
|||
const strategyCode = computed((): string => botStore.activeBot.strategy?.code);
|
||||
const locStrategy = computed({
|
||||
get() {
|
||||
return props.value;
|
||||
return props.modelValue;
|
||||
},
|
||||
set(strategy: string) {
|
||||
botStore.activeBot.getStrategy(strategy);
|
||||
|
|
|
@ -45,7 +45,7 @@ const now = new Date();
|
|||
export default defineComponent({
|
||||
name: 'TimeRangeSelect',
|
||||
props: {
|
||||
value: { required: true, type: String },
|
||||
modelValue: { required: true, type: String },
|
||||
},
|
||||
setup(props, { emit }) {
|
||||
const dateFrom = ref<string>('');
|
||||
|
@ -63,7 +63,7 @@ export default defineComponent({
|
|||
};
|
||||
|
||||
const updateInput = () => {
|
||||
const tr = props.value.split('-');
|
||||
const tr = props.modelValue.split('-');
|
||||
if (tr[0]) {
|
||||
dateFrom.value = timestampToDateString(dateFromString(tr[0], 'yyyyMMdd'));
|
||||
}
|
||||
|
@ -79,7 +79,7 @@ export default defineComponent({
|
|||
);
|
||||
|
||||
onMounted(() => {
|
||||
if (!props.value) {
|
||||
if (!props.modelValue) {
|
||||
dateFrom.value = timestampToDateString(new Date(now.getFullYear(), now.getMonth() - 1, 1));
|
||||
} else {
|
||||
updateInput();
|
||||
|
|
|
@ -4,7 +4,7 @@
|
|||
:class="isProfitable ? 'profit-pill-profit' : ''"
|
||||
:title="profitDesc"
|
||||
>
|
||||
<profit-symbol :profit="profitRatio || profitAbs" />
|
||||
<profit-symbol :profit="(profitRatio || profitAbs) ?? 0" />
|
||||
|
||||
<div class="d-flex justify-content-center align-items-center flex-grow-1">
|
||||
{{ profitRatio !== undefined ? formatPercent(profitRatio, 2) : '' }}
|
||||
|
|
|
@ -75,8 +75,7 @@ const routes: Array<RouteRecordRaw> = [
|
|||
];
|
||||
|
||||
const router = createRouter({
|
||||
history: createWebHistory(),
|
||||
base: import.meta.env.BASE_URL,
|
||||
history: createWebHistory(import.meta.env.BASE_URL),
|
||||
routes,
|
||||
});
|
||||
|
||||
|
|
Loading…
Reference in New Issue
Block a user