diff --git a/tailbone/templates/luigi/index.mako b/tailbone/templates/luigi/index.mako index c4407ff1..44ad30d3 100644 --- a/tailbone/templates/luigi/index.mako +++ b/tailbone/templates/luigi/index.mako @@ -60,8 +60,8 @@ {{ props.row.description }} - {{ props.row.script }} + label="Command"> + {{ props.row.script || props.row.class_name }} - {{ overnightTaskLaunching == props.row.key ? "Working, please wait..." : "Launch" }} + @click="overnightTaskLaunchInit(props.row)"> + Launch + + + + + Launch Overnight Task + + + + + + {{ overnightTask.description }} + + + + + {{ overnightTask.last_date || "n/a" }} + + + + + Launching this task will schedule it to begin + within one minute. See the Luigi Task + Visualizer after that, for current status. + + + + + + + @@ -206,6 +248,8 @@ % if master.has_perm('launch_overnight'): ThisPageData.overnightTasks = ${json.dumps(overnight_tasks)|n} + ThisPageData.overnightTask = null + ThisPageData.overnightTaskShowLaunchDialog = false ThisPageData.overnightTaskLaunching = false ThisPage.methods.overnightTextClass = function(task) { @@ -221,11 +265,16 @@ } } - ThisPage.methods.overnightTaskLaunch = function(task) { - this.overnightTaskLaunching = task.key + ThisPage.methods.overnightTaskLaunchInit = function(task) { + this.overnightTask = task + this.overnightTaskShowLaunchDialog = true + } + + ThisPage.methods.overnightTaskLaunchSubmit = function() { + this.overnightTaskLaunching = true let url = '${url('{}.launch_overnight'.format(route_prefix))}' - let params = {key: task.key} + let params = {key: this.overnightTask.key} this.submitForm(url, params, response => { this.$buefy.toast.open({ @@ -234,6 +283,7 @@ duration: 5000, // 5 seconds }) this.overnightTaskLaunching = false + this.overnightTaskShowLaunchDialog = false }) }
Launch Overnight Task
+ Launching this task will schedule it to begin + within one minute. See the Luigi Task + Visualizer after that, for current status. +