mirror of
https://github.com/freqtrade/frequi.git
synced 2024-11-26 13:05:15 +00:00
Fix timerangeselect crashing when it get's a epoch timerange
This commit is contained in:
parent
2bfa234362
commit
f42dc9de07
|
@ -64,12 +64,16 @@ const timeRange = computed(() => {
|
|||
function updateInput() {
|
||||
const tr = props.modelValue.split('-');
|
||||
if (tr[0]) {
|
||||
dateFrom.value = timestampToDateString(dateFromString(tr[0], 'yyyyMMdd'));
|
||||
dateFrom.value = timestampToDateString(
|
||||
tr[0].length === 8 ? dateFromString(tr[0], 'yyyyMMdd') : parseInt(tr[0]) * 1000,
|
||||
);
|
||||
} else {
|
||||
dateFrom.value = '';
|
||||
}
|
||||
if (tr.length > 1 && tr[1]) {
|
||||
dateTo.value = timestampToDateString(dateFromString(tr[1], 'yyyyMMdd'));
|
||||
dateTo.value = timestampToDateString(
|
||||
tr[1].length === 8 ? dateFromString(tr[1], 'yyyyMMdd') : parseInt(tr[1]) * 1000,
|
||||
);
|
||||
} else {
|
||||
dateTo.value = '';
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue
Block a user