From 627caeb5dbda7eb693ed9adab3ca0b2afa7c2971 Mon Sep 17 00:00:00 2001 From: SungChul Hong Date: Tue, 21 Jan 2025 14:20:02 +0900 Subject: [PATCH] feat: show session idle checker in session detail panel --- src/components/backend-ai-session-list.ts | 26 +++++++++++++++++++++-- 1 file changed, 24 insertions(+), 2 deletions(-) diff --git a/src/components/backend-ai-session-list.ts b/src/components/backend-ai-session-list.ts index 9b02e3f90..ca892c785 100644 --- a/src/components/backend-ai-session-list.ts +++ b/src/components/backend-ai-session-list.ts @@ -3061,6 +3061,22 @@ export default class BackendAISessionList extends BackendAIPage { } } + /** + * @param {Object} rowData - the object with the properties related with the rendered item + */ + triggerOpenSessionDetailDrawer(rowData) { + const queryParams = new URLSearchParams(window.location.search); + queryParams.set('sessionDetail', rowData.item.id); + document.dispatchEvent( + new CustomEvent('react-navigate', { + detail: { + pathname: '/job', + search: queryParams.toString(), + }, + }), + ); + } + /** * Render session information - category, color, description, etc. * @@ -3101,6 +3117,7 @@ export default class BackendAISessionList extends BackendAIPage { white-space: pre-wrap; white-space-collapse: collapse; word-break: break-all; + cursor: pointer; } #session-rename-field { display: none; @@ -3124,8 +3141,13 @@ export default class BackendAISessionList extends BackendAIPage {
-
-${rowData.item[this.sessionNameField]}
+ ${rowData.item[this.sessionNameField]} + ${this._isRunning && !this._isPreparing(rowData.item.status) &&