Web: add "Follow Task Log" button
The "Follow Task Log" button should make it easier to discover the task log viewer in the footer pop-over.
This commit is contained in:
parent
726129446d
commit
a97913bebb
@ -13,6 +13,13 @@ const tabs = { NotificationList, TaskLog }
|
|||||||
watch(currentTab, async (newTab) => {
|
watch(currentTab, async (newTab) => {
|
||||||
localStorage.setItem("footer-popover-active-tab", newTab);
|
localStorage.setItem("footer-popover-active-tab", newTab);
|
||||||
});
|
});
|
||||||
|
|
||||||
|
function showTaskLogTail() {
|
||||||
|
currentTab.value = 'TaskLog';
|
||||||
|
}
|
||||||
|
defineExpose({
|
||||||
|
showTaskLogTail,
|
||||||
|
});
|
||||||
</script>
|
</script>
|
||||||
|
|
||||||
<template>
|
<template>
|
||||||
|
@ -56,6 +56,8 @@
|
|||||||
</dl>
|
</dl>
|
||||||
|
|
||||||
<h3 class="sub-title">Task Log</h3>
|
<h3 class="sub-title">Task Log</h3>
|
||||||
|
<button @click="$emit('showTaskLogTail')" title="Open the task log tail in the footer.">
|
||||||
|
Follow Task Log</button>
|
||||||
<button @click="openFullLog" title="Opens the task log in a new window.">Open Full Log</button>
|
<button @click="openFullLog" title="Opens the task log in a new window.">Open Full Log</button>
|
||||||
</template>
|
</template>
|
||||||
|
|
||||||
@ -76,6 +78,9 @@ export default {
|
|||||||
props: [
|
props: [
|
||||||
"taskData", // Task data to show.
|
"taskData", // Task data to show.
|
||||||
],
|
],
|
||||||
|
emits: [
|
||||||
|
"showTaskLogTail", // Emitted when the user presses the "follow task log" button.
|
||||||
|
],
|
||||||
components: { WorkerLink },
|
components: { WorkerLink },
|
||||||
data() {
|
data() {
|
||||||
return {
|
return {
|
||||||
|
@ -7,7 +7,7 @@
|
|||||||
<tasks-table v-if="hasJobData" ref="tasksTable" :jobID="jobID" :taskID="taskID" @tableRowClicked="onTableTaskClicked" />
|
<tasks-table v-if="hasJobData" ref="tasksTable" :jobID="jobID" :taskID="taskID" @tableRowClicked="onTableTaskClicked" />
|
||||||
</div>
|
</div>
|
||||||
<div class="col col-3">
|
<div class="col col-3">
|
||||||
<task-details :taskData="tasks.activeTask" />
|
<task-details :taskData="tasks.activeTask" @showTaskLogTail="showTaskLogTail" />
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<footer class="app-footer" v-if="!showFooterPopup" @click="showFooterPopup = true">
|
<footer class="app-footer" v-if="!showFooterPopup" @click="showFooterPopup = true">
|
||||||
@ -121,6 +121,13 @@ export default {
|
|||||||
});
|
});
|
||||||
},
|
},
|
||||||
|
|
||||||
|
showTaskLogTail() {
|
||||||
|
this.showFooterPopup = true;
|
||||||
|
this.$nextTick(() => {
|
||||||
|
this.$refs.footerPopup.showTaskLogTail();
|
||||||
|
})
|
||||||
|
},
|
||||||
|
|
||||||
// SocketIO data event handlers:
|
// SocketIO data event handlers:
|
||||||
onSioJobUpdate(jobUpdate) {
|
onSioJobUpdate(jobUpdate) {
|
||||||
this.notifs.addJobUpdate(jobUpdate);
|
this.notifs.addJobUpdate(jobUpdate);
|
||||||
|
Loading…
x
Reference in New Issue
Block a user