- Add buyPrice and buyDate to positions for PnL tracking
- Implement backend analytics service for real-time portfolio performance
- Add server-side security screener with filtering, sorting, and pagination
- Update frontend UI with analytics summaries and sortable screener table
- Optimize MOEX API calls with batch fetching and portfolio-specific caching
- Add unit tests for analytics and screener services
Three optimizations:
1. Merge getBondData + getBondMarketData into single batch call
(same endpoint, parse both tables)
2. Remove redundant getSecurityDescription for shortName
(shortName already in market data responses)
3. Batch by market: 1 call for all shares, 1 call for all bonds
(instead of N individual calls)
Before: 298 API calls for 104 positions -> ~29.8s
After: 2 API calls for 104 positions -> ~0.3s
Backend:
- AuthModule with register, login, logout, refresh, profile endpoints
- JwtAuthGuard (global, opt-out via @Public) + RolesGuard (@Roles)
- PrismaModule with SQLite via @prisma/adapter-libsql (Prisma 7)
- Auth configuration in configuration.ts
Frontend:
- Auth context with session restoration via refresh cookie
- Login, Register, Profile pages with ProtectedRoute
- Auto-refresh on 401 with token rotation
- API client refactored for auth headers
Russian text: auth flows translated to Russian
All text translated: auth pages, profile, layout, loading states