Add dashboard widget functionality: Implement getDashboardWidget method in FalukantService to retrieve compact user data for the dashboard. Update FalukantController and router to expose the new endpoint, and enhance DashboardWidget component to display user-specific information including character name, gender, age, money, unread notifications, and children count.

This commit is contained in:
Torsten Schulz (local)
2026-01-29 17:03:32 +01:00
parent c09159d6ce
commit 62d8cd7b05
5 changed files with 105 additions and 2 deletions

View File

@@ -231,6 +231,7 @@ class FalukantController {
this.getNotifications = this._wrapWithUser((userId) => this.service.getNotifications(userId));
this.getAllNotifications = this._wrapWithUser((userId, req) => this.service.getAllNotifications(userId, req.query.page, req.query.size));
this.markNotificationsShown = this._wrapWithUser((userId) => this.service.markNotificationsShown(userId), { successStatus: 202 });
this.getDashboardWidget = this._wrapWithUser((userId) => this.service.getDashboardWidget(userId));
this.getUndergroundTargets = this._wrapWithUser((userId) => this.service.getPoliticalOfficeHolders(userId));
this.searchUsers = this._wrapWithUser((userId, req) => {