Further simplify stuff

This commit is contained in:
Matthias 2024-07-20 14:20:15 +02:00
parent 6ac1831ec5
commit 1469086623
3 changed files with 1 additions and 15 deletions

View File

@ -123,7 +123,6 @@ import { useBotStore } from '@/stores/ftbotwrapper';
import { ForceEnterPayload, OrderSides } from '@/types'; import { ForceEnterPayload, OrderSides } from '@/types';
const props = defineProps({ const props = defineProps({
modelValue: { required: true, default: false, type: Boolean },
pair: { type: String, default: '' }, pair: { type: String, default: '' },
positionIncrease: { type: Boolean, default: false }, positionIncrease: { type: Boolean, default: false },
}); });

View File

@ -59,7 +59,6 @@ const props = defineProps({
type: Object as () => Trade, type: Object as () => Trade,
required: true, required: true,
}, },
modelValue: { required: true, default: false, type: Boolean },
}); });
const model = defineModel<boolean>(); const model = defineModel<boolean>();

View File

@ -19,21 +19,9 @@
<script setup lang="ts"> <script setup lang="ts">
import { useBotStore } from '@/stores/ftbotwrapper'; import { useBotStore } from '@/stores/ftbotwrapper';
const props = defineProps({ const locFreqaiModel = defineModel<string>();
modelValue: { type: String, required: true },
});
const emit = defineEmits<{ 'update:modelValue': [value: string] }>();
const botStore = useBotStore(); const botStore = useBotStore();
const locFreqaiModel = computed({
get() {
return props.modelValue;
},
set(freqaiModel: string) {
emit('update:modelValue', freqaiModel);
},
});
onMounted(() => { onMounted(() => {
if (botStore.activeBot.freqaiModelList.length === 0) { if (botStore.activeBot.freqaiModelList.length === 0) {
botStore.activeBot.getFreqAIModelList(); botStore.activeBot.getFreqAIModelList();