ogrechkoandClaude Sonnet 5 69467239ed Header redesign, sound/toast notifications, and agent scoping
Four requested improvements:

1. Logo + wordmark now link to /dashboard.

2. Header reordered: nav links (Заявки/Статистика) centered, right side
   now reads notifications -> theme -> settings -> account name -> logout,
   matching the requested order.

3. New TicketToasts component: in-page toast + a short Web Audio chime for
   new tickets and customer messages, shown regardless of tab focus.
   Complements the existing DesktopNotifications, which only fires the
   native OS notification while the tab is backgrounded. Also added a 30s
   polling refresh on the dashboard as a plain safety net under the
   existing SSE push, in case an event is dropped by whatever's in front
   of this app on the network.

4. Agents now see only tickets assigned to them plus unassigned ones (not
   the whole board) — listTickets() takes an optional visibility filter,
   applied in both the dashboard page and the /api/tickets search route,
   and mirrored client-side so a live SSE update can't leak a
   just-reassigned-away ticket onto their board. Settings gear and the
   Статистика nav link are now hidden entirely for agents rather than
   just showing fewer items inside. Also closed a real gap this surfaced:
   /stats had no server-side role check at all (only the nav link was
   hidden), so any agent could load it directly — added the same
   session.user.role !== "admin" guard the other admin-only settings
   pages already have.

Verified end-to-end with a temporary Playwright pass (installed and fully
removed afterward): logo click navigation, header icon order, agent view
missing the gear/Статистика, direct-URL access to /stats and
/settings/accounts still redirecting non-admins, and ticket visibility
correctly disappearing from an agent's board the moment it's reassigned
to someone else.

Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_012o9j9RezxbZVKQMrB7oRLY
2026-08-05 12:50:54 +00:00

top-tickets

Хелпдеск-система: тикеты, дашборд по статусам, канал Telegram, realtime-обновления без перезагрузки страницы, отдельный клиентский портал. MVP-1 — см. /root/.claude/plans/refactored-discovering-corbato.md за архитектурой и тем, что отложено на MVP-2 (email, встраиваемый виджет).

Запуск в Docker

cp .env.example .env
npm run generate-key   # вставить результат в CREDENTIALS_ENCRYPTION_KEY
# заполнить ADMIN_BOOTSTRAP_EMAIL / ADMIN_BOOTSTRAP_PASSWORD / TELEGRAM_BOT_TOKEN в .env

docker compose up --build -d

Приложение слушает :8081 (уже проброшено внешним nginx на help.top-sysops.ru). При первом старте контейнер сам применяет миграции и создаёт админ-аккаунт из .env.

Локальная разработка

npm install
cp .env.example .env   # + generate-key, как выше
npm run db:migrate
npm run bootstrap-admin
npm run dev

Telegram

Подключается через Настройки → Telegram в интерфейсе (или через TELEGRAM_BOT_TOKEN в .env — сработает только при первом старте, если бот ещё не настроен). Чтобы бот видел все сообщения в группе, а не только с упоминанием — @BotFather → /setprivacy → Disable.

Токен, который прислали в чат Claude Code, стоит перевыпустить (@BotFather → /revoke) — он засветился в истории сессии.

S
Description
No description provided
Readme
1.1 MiB
0 Stars 1 Watchers 0 Forks
Languages
TypeScript 95.9%
CSS 2.3%
JavaScript 1.2%
Dockerfile 0.6%