import { Injectable } from '@nestjs/common';
import { AuditLogRepository } from '../../infrastructure/repositories/audit-log.repository';

@Injectable()
export class QueryAuditTrailUseCase {
  constructor(private readonly auditRepo: AuditLogRepository) {}

  async execute(filters: {
    from?: string;
    to?: string;
    actionType?: string;
    actorType?: string;
    resourceType?: string;
    limit?: number;
    offset?: number;
  }) {
    return this.auditRepo.queryLogs(filters);
  }
}
