feat(falukant): enhance product pricing and nobility advancement features
All checks were successful
Deploy to production / deploy (push) Successful in 2m52s

- Updated the `getAllProductPricesInRegion` method in `FalukantService` to accept additional parameters for network worth and branch ID, improving pricing calculations based on user branches.
- Enhanced the nobility advancement logic in `NobilityView` to display unmet requirements clearly, providing users with better feedback on advancement conditions.
- Refactored the revenue calculation in `ProductionSection` to utilize a cached product prices object, optimizing performance and reducing redundant API calls.
- Updated localization files to include new translations for attack sources across multiple languages, enhancing the user experience for diverse audiences.
- Removed obsolete C++ worker references and streamlined the retention logic for production logs, ensuring efficient data management.
This commit is contained in:
Torsten Schulz (local)
2026-04-09 09:08:32 +02:00
parent 360bb59a4e
commit 1118a691b9
20 changed files with 216 additions and 85 deletions

View File

@@ -245,7 +245,9 @@ class FalukantController {
if (Number.isNaN(regionId)) {
throw new Error('regionId is required');
}
return this.service.getAllProductPricesInRegion(userId, regionId);
const networkWorth = req.query.networkWorth === '1' || req.query.networkWorth === 'true';
const branchId = req.query.branchId != null ? parseInt(req.query.branchId, 10) : null;
return this.service.getAllProductPricesInRegion(userId, regionId, { networkWorth, branchId });
});
this.getProductPricesInCities = this._wrapWithUser((userId, req) => {
const productId = parseInt(req.query.productId, 10);