diff --git a/src/components/ChatPanel.tsx b/src/components/ChatPanel.tsx index cf97c58..f4cb4ef 100644 --- a/src/components/ChatPanel.tsx +++ b/src/components/ChatPanel.tsx @@ -125,7 +125,7 @@ export default function ChatPanel({ chatId }: Props) {
{AUTHOR_ICON[msg.author_type] || "👤"} - {msg.author_slug} + {msg.author?.name || msg.author?.slug || "Unknown"} · {new Date(msg.created_at).toLocaleString("ru-RU", { hour: "2-digit", minute: "2-digit" })}
diff --git a/src/components/KanbanBoard.tsx b/src/components/KanbanBoard.tsx index 9f8eae5..bfe151c 100644 --- a/src/components/KanbanBoard.tsx +++ b/src/components/KanbanBoard.tsx @@ -63,7 +63,7 @@ export default function KanbanBoard({ projectId, projectSlug }: Props) { const unsubscribeAssigned = wsClient.on("task.assigned", (data: any) => { if (data.project_id === projectId) { - setTasks((prev) => prev.map((t) => t.id === data.id ? { ...t, assignee_slug: data.assignee_slug, assigned_at: data.assigned_at } : t)); + setTasks((prev) => prev.map((t) => t.id === data.id ? { ...t, assignee_id: data.assignee_id, assignee: data.assignee, assigned_at: data.assigned_at } : t)); } }); @@ -106,8 +106,8 @@ export default function KanbanBoard({ projectId, projectSlug }: Props) { style={{ background: PRIORITY_COLORS[task.priority] || "#737373" }} title={task.priority} /> {prefix}-{task.number} - {task.assignee_slug && ( - → {task.assignee_slug} + {task.assignee && ( + → {task.assignee.slug} )}
{task.title}
diff --git a/src/components/TaskModal.tsx b/src/components/TaskModal.tsx index d97dcf3..c815389 100644 --- a/src/components/TaskModal.tsx +++ b/src/components/TaskModal.tsx @@ -42,7 +42,7 @@ export default function TaskModal({ task, projectId: _projectId, projectSlug: _p const [description, setDescription] = useState(task.description || ""); const [status, setStatus] = useState(task.status); const [priority, setPriority] = useState(task.priority); - const [assigneeSlug, setAssigneeSlug] = useState(task.assignee_slug || ""); + const [assigneeId, setAssigneeId] = useState(task.assignee_id || ""); const [members, setMembers] = useState([]); const [steps, setSteps] = useState(task.steps || []); const [comments, setComments] = useState([]); @@ -307,16 +307,16 @@ export default function TaskModal({ task, projectId: _projectId, projectSlug: _p
Исполнитель