Skip to content

Commit

Permalink
feat: #5293 added permission for Employee Availability
Browse files Browse the repository at this point in the history
  • Loading branch information
rahul-rocket committed Jan 27, 2025
1 parent fdab334 commit d51f3f7
Showing 1 changed file with 3 additions and 3 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ import { PermissionGuard, TenantPermissionGuard } from '../shared/guards';
import { UseValidationPipe, UUIDValidationPipe } from '../shared/pipes';
import { EmployeeAvailabilityService } from './employee-availability.service';
import { EmployeeAvailability } from './employee-availability.entity';
import { EmployeeAvailabilityBulkCreateCommand, EMPLOYEE_AVAILABILITY_CREATECommand } from './commands';
import { EmployeeAvailabilityBulkCreateCommand, EmployeeAvailabilityCreateCommand } from './commands';
import { CreateEmployeeAvailabilityDTO } from './dto/create-employee-availability.dto';
import { UpdateEmployeeAvailabilityDTO } from './dto/update-employee-availability.dto';

Expand Down Expand Up @@ -63,7 +63,7 @@ export class EmployeeAvailabilityController extends CrudController<EmployeeAvail
status: HttpStatus.NOT_FOUND,
description: 'No availability records found.'
})
@Permissions(PermissionsEnum.EmployeeAvailabilityRead)
@Permissions(PermissionsEnum.EMPLOYEE_AVAILABILITY_READ)
@Get('/')
@UseValidationPipe()
async findAll(
Expand Down Expand Up @@ -92,7 +92,7 @@ export class EmployeeAvailabilityController extends CrudController<EmployeeAvail
@Post('/')
@UseValidationPipe()
async create(@Body() entity: CreateEmployeeAvailabilityDTO): Promise<IEmployeeAvailability> {
return this.commandBus.execute(new EMPLOYEE_AVAILABILITY_CREATECommand(entity));
return this.commandBus.execute(new EmployeeAvailabilityCreateCommand(entity));
}

/**
Expand Down

0 comments on commit d51f3f7

Please sign in to comment.