mirror of
https://github.com/bigcapitalhq/bigcapital.git
synced 2026-02-16 12:50:38 +00:00
feat(nestjs): migrate to NestJS
This commit is contained in:
@@ -0,0 +1,24 @@
|
||||
import { TransactionsLockingGroup } from '../types/TransactionsLocking.types';
|
||||
import { Injectable } from '@nestjs/common';
|
||||
import { TransactionsLockingGuard } from './TransactionsLockingGuard';
|
||||
import { MomentInput } from 'moment';
|
||||
|
||||
@Injectable()
|
||||
export class SalesTransactionLockingGuard {
|
||||
constructor(
|
||||
private readonly transactionLockingGuardService: TransactionsLockingGuard,
|
||||
) {}
|
||||
|
||||
/**
|
||||
* Validates the transaction locking of sales services commands.
|
||||
* @param {Date} transactionDate - The transaction date.
|
||||
*/
|
||||
public transactionLockingGuard = async (
|
||||
transactionDate: MomentInput
|
||||
) => {
|
||||
await this.transactionLockingGuardService.transactionsLockingGuard(
|
||||
transactionDate,
|
||||
TransactionsLockingGroup.Sales
|
||||
);
|
||||
};
|
||||
}
|
||||
Reference in New Issue
Block a user