refactor: wip to nestjs

This commit is contained in:
Ahmed Bouhuolia
2024-12-25 00:43:55 +02:00
parent 336171081e
commit a6932d76f3
249 changed files with 21314 additions and 1616 deletions

View File

@@ -0,0 +1,32 @@
// import Container, { Service } from 'typedi';
// import { SendInvoiceMailReminder } from './SendSaleInvoiceMailReminder';
// @Service()
// export class SendSaleInvoiceReminderMailJob {
// /**
// * Constructor method.
// */
// constructor(agenda) {
// agenda.define(
// 'sale-invoice-reminder-mail-send',
// { priority: 'high', concurrency: 1 },
// this.handler
// );
// }
// /**
// * Triggers sending invoice mail.
// */
// private handler = async (job, done: Function) => {
// const { tenantId, saleInvoiceId, messageOptions } = job.attrs.data;
// const sendInvoiceMail = Container.get(SendInvoiceMailReminder);
// try {
// await sendInvoiceMail.sendMail(tenantId, saleInvoiceId, messageOptions);
// done();
// } catch (error) {
// console.log(error);
// done(error);
// }
// };
// }