gui: hide bypass banner when switching away from the requesting agent
This commit is contained in:
parent
a269a6f790
commit
f9e6785add
|
|
@ -584,9 +584,19 @@ Connections {
|
|||
target: ollie
|
||||
function onActiveSessionIdChanged() {
|
||||
if (!ollie.activeAgentId) chatPane.loadChat()
|
||||
// Hide bypass banner if it's not for the now-active session
|
||||
if (chatPane.pendingBypass && chatPane.pendingBypass.sessionId !== ollie.activeSessionId) {
|
||||
chatPane.hasPendingBypass = false
|
||||
}
|
||||
}
|
||||
function onActiveAgentIdChanged() {
|
||||
if (ollie.activeAgentId) chatPane.loadChat()
|
||||
// Hide bypass banner if it's not for the now-active agent
|
||||
if (chatPane.pendingBypass &&
|
||||
(chatPane.pendingBypass.sessionId !== ollie.activeSessionId ||
|
||||
chatPane.pendingBypass.agentId !== ollie.activeAgentId)) {
|
||||
chatPane.hasPendingBypass = false
|
||||
}
|
||||
}
|
||||
function onBypassRequested(sessionId, agentId, id, cmd, cwd) {
|
||||
// Show bypass request only for the currently active agent
|
||||
|
|
|
|||
Loading…
Reference in New Issue