feat(tickets): Play e Chat atribuem responsavel automaticamente

- Botao Play habilitado mesmo sem responsavel
- Ao clicar Play sem responsavel, atribui usuario logado automaticamente
- Ao iniciar chat ao vivo sem responsavel, atribui usuario logado
- Adiciona mutation fixLegacySessions para corrigir sessoes antigas

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
This commit is contained in:
rever-tecnologia 2025-12-15 16:10:13 -03:00
parent 3bfc5793f1
commit 98b23af4b2
3 changed files with 105 additions and 15 deletions

View file

@ -118,11 +118,13 @@ export function ChatHubWidget() {
}
const handleExpand = async () => {
setIsMinimized(false)
try {
await invoke("set_hub_minimized", { minimized: false })
// Aguarda a janela redimensionar antes de atualizar o estado
setTimeout(() => setIsMinimized(false), 100)
} catch (err) {
console.error("Erro ao expandir hub:", err)
setIsMinimized(false) // Fallback
}
}
@ -201,7 +203,7 @@ export function ChatHubWidget() {
// Expandido - mostrar lista
return (
<div className="flex h-screen flex-col overflow-hidden rounded-2xl bg-white shadow-xl">
<div className="flex h-full flex-col overflow-hidden rounded-2xl bg-white shadow-xl">
<ChatSessionList
sessions={sessions}
onSelectSession={handleSelectSession}