Add news feature with CRUD operations and real-time notifications
- Implemented news management functionality, allowing admins to create, read, update, and delete news posts. - Introduced a new SignalR event for broadcasting news updates to all connected clients. - Updated API documentation to include new endpoints for news management. - Enhanced frontend with a dedicated news page and admin interface for managing news posts. - Added necessary localization for news-related terms in both Russian and English.
This commit is contained in:
@@ -189,7 +189,9 @@ POST /api/configs
|
||||
(события нод/системы/активации) — пользователь при подключении добавляется в свою `user:{userId}`
|
||||
и, если он админ, дополнительно в `admins`.
|
||||
- **События сервер→клиент**: `configTrafficUpdated`, `configStatusChanged`, `nodeStatusChanged`,
|
||||
`activationRequested`, `userActivated` — точные payload'ы см. [api-design.md](api-design.md#signalr--hub-hubspanel).
|
||||
`activationRequested`, `userActivated`, `newsPublished` — точные payload'ы см.
|
||||
[api-design.md](api-design.md#signalr--hub-hubspanel). `newsPublished` — единственное
|
||||
широковещательное событие (`Clients.All`), а не по группе — новости видны всем без исключения.
|
||||
- Пуш выполняет `SignalRRealtimeNotifier` (порт `IRealtimeNotifier`, реализация в `Api/Hubs/`),
|
||||
вызываемый из хендлеров и фоновых сервисов — Application-слой не зависит от SignalR напрямую.
|
||||
|
||||
|
||||
Reference in New Issue
Block a user