mirror of
https://github.com/HamzaSha1/zod-backend.git
synced 2025-08-25 21:59:40 +00:00
feat: add cron job for allowance and implement cron lock
This commit is contained in:
@ -89,6 +89,13 @@ export class AllowancesService {
|
||||
return allowance;
|
||||
}
|
||||
|
||||
async findAllowancesChunks(chunkSize: number) {
|
||||
this.logger.log(`Finding allowances chunks`);
|
||||
const allowances = await this.allowancesRepository.findAllowancesChunks(chunkSize);
|
||||
this.logger.log(`Returning allowances chunks`);
|
||||
return allowances;
|
||||
}
|
||||
|
||||
private async prepareAllowanceDocuments(allowance: Allowance[]) {
|
||||
this.logger.log(`Preparing document for allowances`);
|
||||
await Promise.all(
|
||||
|
Reference in New Issue
Block a user