mirror of
https://github.com/HamzaSha1/zod-backend.git
synced 2025-11-26 08:34:55 +00:00
feat: show embossing information for child cards
This commit is contained in:
@ -114,6 +114,14 @@ export class CardService {
|
||||
return this.neoleapService.getEmbossingInformation(card);
|
||||
}
|
||||
|
||||
async getChildCardEmbossingInformation(cardId: string, guardianId: string) {
|
||||
const card = await this.getCardById(cardId);
|
||||
if (card.parentId !== guardianId) {
|
||||
throw new BadRequestException('CARD.DOES_NOT_BELONG_TO_GUARDIAN');
|
||||
}
|
||||
return this.neoleapService.getEmbossingInformation(card);
|
||||
}
|
||||
|
||||
async updateCardLimit(cardId: string, newLimit: number) {
|
||||
const { affected } = await this.cardRepository.updateCardLimit(cardId, newLimit);
|
||||
|
||||
|
||||
Reference in New Issue
Block a user