Add heir management functionality in Falukant module
- Implemented setHeir method in FalukantService to designate a child as heir, including validation checks for user and child relationships. - Updated FalukantController to expose the setHeir endpoint, allowing users to set heirs via the API. - Enhanced FalukantRouter with a new route for setting heirs. - Modified FamilyView component to include UI elements for setting heirs, with success and error feedback. - Updated localization files in both German and English to include new translations related to heir management, improving user experience.
This commit is contained in:
@@ -92,6 +92,7 @@ class FalukantController {
|
||||
if (!result) throw { status: 404, message: 'No family data found' };
|
||||
return result;
|
||||
});
|
||||
this.setHeir = this._wrapWithUser((userId, req) => this.service.setHeir(userId, req.body.childCharacterId));
|
||||
this.acceptMarriageProposal = this._wrapWithUser((userId, req) => this.service.acceptMarriageProposal(userId, req.body.proposalId));
|
||||
this.getGifts = this._wrapWithUser((userId) => {
|
||||
console.log('🔍 getGifts called with userId:', userId);
|
||||
|
||||
Reference in New Issue
Block a user