From 658f71ffe9ed15d2fc7b83e472604bf09336f089 Mon Sep 17 00:00:00 2001 From: Ruben Fiszel Date: Fri, 29 Nov 2024 17:01:20 +0100 Subject: [PATCH] schedule nits --- .../apps/editor/AppReportsDrawerInner.svelte | 21 +++++++++++-------- 1 file changed, 12 insertions(+), 9 deletions(-) diff --git a/frontend/src/lib/components/apps/editor/AppReportsDrawerInner.svelte b/frontend/src/lib/components/apps/editor/AppReportsDrawerInner.svelte index cedf5255d3..b05e0ef9b4 100644 --- a/frontend/src/lib/components/apps/editor/AppReportsDrawerInner.svelte +++ b/frontend/src/lib/components/apps/editor/AppReportsDrawerInner.svelte @@ -96,14 +96,6 @@ (schedule.args?.startup_duration as number) ?? appReportingStartupDuration screenshotKind = (schedule.args?.kind as 'png' | 'pdf') ?? screenshotKind - args = schedule.args - ? Object.fromEntries( - Object.entries(schedule.args).filter( - ([key, _]) => key !== 'app_path' && key !== 'startup_duration' && key !== 'kind' - ) - ) - : {} - selectedTab = flow.value.modules[1]?.value.type === 'script' ? flow.value.modules[1].value.path === notificationScripts.email.path @@ -115,6 +107,17 @@ : 'custom' : 'custom' + const nargs = schedule.args + ? Object.fromEntries( + Object.entries(schedule.args).filter( + ([key, _]) => key !== 'app_path' && key !== 'startup_duration' && key !== 'kind' + ) + ) + : {} + setTimeout(() => { + args = structuredClone(nargs) + }) + customPath = selectedTab === 'custom' && flow.value.modules[1]?.value.type === 'script' && @@ -511,7 +514,7 @@ export async function main(app_path: string, startup_duration = 5, kind: 'pdf' | tooltip="Send a PDF or PNG preview of any app at a given schedule" documentationLink="https://www.windmill.dev/docs/apps/schedule_reports" > -
+