added timezone for all create date

This commit is contained in:
SlimusMinus
2026-10-11 23:26:11 +03:00
parent 68d53fadf3
commit 4119b767c3
15 changed files with 156 additions and 20 deletions

View File

@@ -82,6 +82,12 @@ public class WsStompInterceptor implements ChannelInterceptor {
accessor.getSessionAttributes().put(USER_ID_ATTR, userId);
accessor.getSessionAttributes().put(ROLE_ATTR, role);
// Таймзону присылает клиент на CONNECT; применяется при сохранении Message
String timezone = accessor.getFirstNativeHeader(TimeZoneContext.WS_HEADER);
if (timezone != null) {
accessor.getSessionAttributes().put(TimeZoneContext.SESSION_ATTRIBUTE, timezone);
}
log.info("WS connected: userId={} role={}", userId, role);
}