Skip to content

Commit

Permalink
remove pagination options at school.uc.ts file
Browse files Browse the repository at this point in the history
  • Loading branch information
muratmerdoglu-dp committed Jan 10, 2025
1 parent a74fa2a commit 59dff24
Showing 1 changed file with 4 additions and 8 deletions.
12 changes: 4 additions & 8 deletions apps/server/src/modules/school/api/school.uc.ts
Original file line number Diff line number Diff line change
Expand Up @@ -133,11 +133,7 @@ export class SchoolUc {
return dto;
}

public async getSchoolTeachers(
schoolId: EntityId,
userId: EntityId,
pagination?: PaginationParams
): Promise<SchoolUserListResponse> {
public async getSchoolTeachers(schoolId: EntityId, userId: EntityId): Promise<SchoolUserListResponse> {
const [school, user] = await Promise.all([
this.schoolService.getSchoolById(schoolId),
this.authorizationService.getUserWithPermissions(userId),
Expand All @@ -149,12 +145,12 @@ export class SchoolUc {

let result: Page<UserDO>;
if (isUserOfSchool) {
result = await this.userService.findBySchoolRole(schoolId, RoleName.TEACHER, { pagination });
result = await this.userService.findBySchoolRole(schoolId, RoleName.TEACHER);
} else {
result = await this.userService.findPublicTeachersBySchool(schoolId, { pagination });
result = await this.userService.findPublicTeachersBySchool(schoolId);
}

const responseDto = SchoolUserResponseMapper.mapToListResponse(result, pagination);
const responseDto = SchoolUserResponseMapper.mapToListResponse(result);
return responseDto;
}

Expand Down

0 comments on commit 59dff24

Please sign in to comment.