From 8717d1329cf59a737de3e47607fb732b38a3f530 Mon Sep 17 00:00:00 2001 From: mindesbunister Date: Thu, 24 Jul 2025 11:57:39 +0200 Subject: [PATCH] fix: Use dynamic analysis interval based on actual timeframe - Replace hardcoded 300 seconds (5 min) with calculated interval from timeframe - analysisInterval now correctly shows 3600 seconds (60 min) for 1h timeframe - Timer will properly display correct intervals for all timeframes (5m = 300s, 1h = 3600s, etc.) --- lib/automation-service-simple.ts | 2 +- prisma/prisma/dev.db | Bin 1003520 -> 1003520 bytes 2 files changed, 1 insertion(+), 1 deletion(-) diff --git a/lib/automation-service-simple.ts b/lib/automation-service-simple.ts index cc4146b..f754fce 100644 --- a/lib/automation-service-simple.ts +++ b/lib/automation-service-simple.ts @@ -1157,7 +1157,7 @@ ${validResults.map(r => `• ${r.timeframe}: ${r.analysis?.recommendation} (${r. } // Calculate next analysis timing - const analysisInterval = 300 // 5 minutes in seconds + const analysisInterval = Math.floor(this.getIntervalFromTimeframe(session.timeframe) / 1000) // Convert to seconds let nextAnalysisIn = 0 if (this.isRunning && session.nextScheduled) { diff --git a/prisma/prisma/dev.db b/prisma/prisma/dev.db index 6f5c64cf94824eab94b82ed8352d9cea24ed9e96..23c6e5365d6cf38366f524c1658f23c22c0f715e 100644 GIT binary patch delta 217 zcmZozVB4_3c7imc#zYxsMvcaVtqF`9<5?TH1-S(`3mOEoZqH0*WaW?)wO5rCl@#QF z0!GHhMoSK9dsW%#owrumr$Rb>W7iROt_NhzsmiKRIux~0XbMV@}s z4`wnZiQX~#&p5+ISh1dQhV>nzKS1)X*xBtid5ji=&sT8)08!OPjsO4v delta 218 zcmZozVB4_3c7imc+(a2?M!Cj>tqF`9<5`=y1-S(`3mOEoZqH0*WaW?$w^x-El@#QF z0!GG0e}+bL4(aKQnT#UxtQ-uitPIJyDH-OamIamu1_lNBnFdu!`8mny*_oEp7p5}G zO~0PY7$ACEeG%gf8zC_z#u?VP)#rf8#oKN27%c=vuxV}YsAmLXCLm@8Viq7~1!6WJ bW(Q&pAm#*OE+FOxVjdvo-QH2pS8)LV<7Gsd