fix(lint): resolve 327 ESLint errors blocking CI pipeline

Auto-fix 326 `@typescript-eslint/consistent-type-imports` violations
across 182 files with `pnpm lint --fix`. Suppress 1 `no-empty-pattern`
in Playwright e2e fixture where empty destructuring is idiomatic.

All 1454 unit tests pass. Typecheck clean.

Co-Authored-By: Paperclip <noreply@paperclip.ing>
This commit is contained in:
Ho Ngoc Hai
2026-04-12 21:07:40 +07:00
parent c658e540f0
commit 97a9541fde
182 changed files with 331 additions and 330 deletions

View File

@@ -1,7 +1,7 @@
import { Inject, InternalServerErrorException } from '@nestjs/common';
import { CommandHandler, EventBus, type ICommandHandler } from '@nestjs/cqrs';
import { CommandHandler, type EventBus, type ICommandHandler } from '@nestjs/cqrs';
import { createId } from '@paralleldrive/cuid2';
import { ConflictException, DomainException, ValidationException, LoggerService } from '@modules/shared';
import { ConflictException, DomainException, ValidationException, type LoggerService } from '@modules/shared';
import { PaymentEntity } from '../../../domain/entities/payment.entity';
import {
PAYMENT_REPOSITORY,

View File

@@ -1,7 +1,7 @@
import { Inject, InternalServerErrorException } from '@nestjs/common';
import { CommandHandler, EventBus, type ICommandHandler } from '@nestjs/cqrs';
import { CommandHandler, type EventBus, type ICommandHandler } from '@nestjs/cqrs';
import { type PaymentStatus } from '@prisma/client';
import { DomainException, NotFoundException, ValidationException, LoggerService } from '@modules/shared';
import { DomainException, NotFoundException, ValidationException, type LoggerService } from '@modules/shared';
import {
PAYMENT_REPOSITORY,
type IPaymentRepository,

View File

@@ -1,6 +1,6 @@
import { Inject, InternalServerErrorException } from '@nestjs/common';
import { CommandHandler, type ICommandHandler } from '@nestjs/cqrs';
import { DomainException, NotFoundException, ValidationException, LoggerService } from '@modules/shared';
import { DomainException, NotFoundException, ValidationException, type LoggerService } from '@modules/shared';
import {
PAYMENT_REPOSITORY,
type IPaymentRepository,

View File

@@ -1,6 +1,6 @@
import { Inject, InternalServerErrorException } from '@nestjs/common';
import { type IQueryHandler, QueryHandler } from '@nestjs/cqrs';
import { DomainException, ForbiddenException, LoggerService, NotFoundException } from '@modules/shared';
import { DomainException, ForbiddenException, type LoggerService, NotFoundException } from '@modules/shared';
import {
PAYMENT_REPOSITORY,
type IPaymentRepository,

View File

@@ -1,6 +1,6 @@
import { Inject, InternalServerErrorException } from '@nestjs/common';
import { type IQueryHandler, QueryHandler } from '@nestjs/cqrs';
import { DomainException, LoggerService } from '@modules/shared';
import { DomainException, type LoggerService } from '@modules/shared';
import {
PAYMENT_REPOSITORY,
type IPaymentRepository,

View File

@@ -1,6 +1,6 @@
import { Injectable } from '@nestjs/common';
import { Prisma, type Payment as PrismaPayment, type PaymentStatus } from '@prisma/client';
import { PrismaService } from '@modules/shared';
import { type PrismaService } from '@modules/shared';
import { PaymentEntity, type PaymentProps } from '../../domain/entities/payment.entity';
import { type IPaymentRepository } from '../../domain/repositories/payment.repository';
import { Money } from '../../domain/value-objects/money.vo';

View File

@@ -1,8 +1,8 @@
import * as crypto from 'crypto';
import { Injectable } from '@nestjs/common';
import { ConfigService } from '@nestjs/config';
import { type ConfigService } from '@nestjs/config';
import { type PaymentProvider } from '@prisma/client';
import { LoggerService } from '@modules/shared';
import { type LoggerService } from '@modules/shared';
import {
type IPaymentGateway,
type CreatePaymentUrlParams,

View File

@@ -1,12 +1,12 @@
import { Injectable, BadRequestException } from '@nestjs/common';
import { type PaymentProvider } from '@prisma/client';
import { MomoService } from './momo.service';
import { type MomoService } from './momo.service';
import {
type IPaymentGateway,
type IPaymentGatewayFactory,
} from './payment-gateway.interface';
import { VnpayService } from './vnpay.service';
import { ZalopayService } from './zalopay.service';
import { type VnpayService } from './vnpay.service';
import { type ZalopayService } from './zalopay.service';
@Injectable()
export class PaymentGatewayFactory implements IPaymentGatewayFactory {

View File

@@ -1,8 +1,8 @@
import * as crypto from 'crypto';
import { Injectable } from '@nestjs/common';
import { ConfigService } from '@nestjs/config';
import { type ConfigService } from '@nestjs/config';
import { type PaymentProvider } from '@prisma/client';
import { LoggerService } from '@modules/shared';
import { type LoggerService } from '@modules/shared';
import {
type IPaymentGateway,
type CreatePaymentUrlParams,

View File

@@ -1,8 +1,8 @@
import * as crypto from 'crypto';
import { Injectable } from '@nestjs/common';
import { ConfigService } from '@nestjs/config';
import { type ConfigService } from '@nestjs/config';
import { type PaymentProvider } from '@prisma/client';
import { LoggerService } from '@modules/shared';
import { type LoggerService } from '@modules/shared';
import {
type IPaymentGateway,
type CreatePaymentUrlParams,

View File

@@ -8,7 +8,7 @@ import {
Query,
UseGuards,
} from '@nestjs/common';
import { CommandBus, QueryBus } from '@nestjs/cqrs';
import { type CommandBus, type QueryBus } from '@nestjs/cqrs';
import {
ApiTags,
ApiOperation,
@@ -26,13 +26,13 @@ import { HandleCallbackCommand } from '../../application/commands/handle-callbac
import { type HandleCallbackResult } from '../../application/commands/handle-callback/handle-callback.handler';
import { RefundPaymentCommand } from '../../application/commands/refund-payment/refund-payment.command';
import { type RefundPaymentResult } from '../../application/commands/refund-payment/refund-payment.handler';
import { PaymentStatusDto } from '../../application/queries/get-payment-status/get-payment-status.handler';
import { type PaymentStatusDto } from '../../application/queries/get-payment-status/get-payment-status.handler';
import { GetPaymentStatusQuery } from '../../application/queries/get-payment-status/get-payment-status.query';
import { TransactionListDto } from '../../application/queries/list-transactions/list-transactions.handler';
import { type TransactionListDto } from '../../application/queries/list-transactions/list-transactions.handler';
import { ListTransactionsQuery } from '../../application/queries/list-transactions/list-transactions.query';
import { CreatePaymentDto } from '../dto/create-payment.dto';
import { ListTransactionsDto } from '../dto/list-transactions.dto';
import { RefundPaymentDto } from '../dto/refund-payment.dto';
import { type CreatePaymentDto } from '../dto/create-payment.dto';
import { type ListTransactionsDto } from '../dto/list-transactions.dto';
import { type RefundPaymentDto } from '../dto/refund-payment.dto';
@ApiTags('payments')
@Controller('payments')