fix(module): small fixes to module customers

This commit is contained in:
Matthieu Haineault 2025-07-22 08:11:08 -04:00
parent 814b25742b
commit affed3ce56
4 changed files with 7 additions and 7 deletions

View File

@ -1,8 +1,8 @@
import { Body, Controller, Delete, Get, Param, ParseIntPipe, Patch, Post } from '@nestjs/common';
import { CustomersService } from '../services/customers.service';
import { Customers, Employees } from '@prisma/client';
import { CreateCustomerDto } from '../dtos/create-customer';
import { UpdateCustomerDto } from '../dtos/update-customer';
import { Customers } from '@prisma/client';
import { CreateCustomerDto } from '../dtos/create-customer.dto';
import { UpdateCustomerDto } from '../dtos/update-customer.dto';
import { RolesAllowed } from "src/common/decorators/roles.decorators";
import { Roles as RoleEnum } from '.prisma/client';

View File

@ -20,7 +20,7 @@ export class CreateCustomerDto {
@IsEmail()
@IsOptional()
email?: string;
email: string;
@Type(() => Number)
@IsInt()

View File

@ -1,4 +1,4 @@
import { PartialType } from "@nestjs/swagger";
import { CreateCustomerDto } from "./create-customer";
import { CreateCustomerDto } from "./create-customer.dto";
export class UpdateCustomerDto extends PartialType(CreateCustomerDto) {}

View File

@ -1,8 +1,8 @@
import { Injectable, NotFoundException } from '@nestjs/common';
import { PrismaService } from 'src/prisma/prisma.service';
import { CreateCustomerDto } from '../dtos/create-customer';
import { CreateCustomerDto } from '../dtos/create-customer.dto';
import { Customers, Users } from '@prisma/client';
import { UpdateCustomerDto } from '../dtos/update-customer';
import { UpdateCustomerDto } from '../dtos/update-customer.dto';
@Injectable()
export class CustomersService {