From c6d9618268c41898742e25be8c003a0a69c85f89 Mon Sep 17 00:00:00 2001 From: Dasha Date: Mon, 9 Feb 2026 10:36:13 +0100 Subject: [PATCH 1/3] Feat: Add appointment types --- server/src/types/appointment/appointment.types.ts | 12 ++++++++++++ 1 file changed, 12 insertions(+) create mode 100644 server/src/types/appointment/appointment.types.ts diff --git a/server/src/types/appointment/appointment.types.ts b/server/src/types/appointment/appointment.types.ts new file mode 100644 index 0000000..34cdfda --- /dev/null +++ b/server/src/types/appointment/appointment.types.ts @@ -0,0 +1,12 @@ +export interface CreateAppointmentType { + studentId: string; + teacherId: string; + lesson: string; + price: string; + date: string; + time: string; +} + +export interface UpdateAppointmentStatusType { + status: "approved" | "rejected"; +} From f4012ac38925e0fe8fd9c89f602d0feea48ea0e9 Mon Sep 17 00:00:00 2001 From: Dasha Date: Mon, 9 Feb 2026 10:44:39 +0100 Subject: [PATCH 2/3] feat: composition types --- server/src/composition/composition.types.ts | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/server/src/composition/composition.types.ts b/server/src/composition/composition.types.ts index 54ab603..4a0acf7 100644 --- a/server/src/composition/composition.types.ts +++ b/server/src/composition/composition.types.ts @@ -10,6 +10,12 @@ export const TYPES = { TeacherService: Symbol.for("TeacherService"), TeacherQuery: Symbol.for("TeacherQuery"), TeacherController: Symbol.for("TeacherController"), + + //appointment + AppointmentRepository: Symbol.for("AppointmentRepository"), + AppointmentService: Symbol.for("AppointmentService"), + AppointmentController: Symbol.for("AppointmentController"), + //jwt JwtService: Symbol.for("JwtService"), //middlewares From 56aafb6e801a9c957d17d0de330ddb262c36031d Mon Sep 17 00:00:00 2001 From: Dasha Date: Mon, 9 Feb 2026 10:47:34 +0100 Subject: [PATCH 3/3] feat: composition root --- server/src/composition/compositionRoot.ts | 14 ++++++++++++++ 1 file changed, 14 insertions(+) diff --git a/server/src/composition/compositionRoot.ts b/server/src/composition/compositionRoot.ts index 25347c7..e547925 100644 --- a/server/src/composition/compositionRoot.ts +++ b/server/src/composition/compositionRoot.ts @@ -15,6 +15,9 @@ import { AuthMiddleware } from "../middlewares/authMiddlewareWithBearer.js"; import { AuthService } from "../services/auth/auth.service.js"; import { RefreshSessionRepository } from "../repositories/commandRepositories/refreshSession.repository.js"; import { RefreshTokenMiddleware } from "../middlewares/refreshToken.middleware.js"; +import { AppointmentRepository } from "../repositories/appointment.repository.js"; +import { AppointmentService } from "../services/appointment/appointment.service.js"; +import { AppointmentController } from "../controllers/appointment.controller.js"; export const container = new Container(); @@ -48,3 +51,14 @@ container.bind(TYPES.TeacherService).to(TeacherService); container .bind(TYPES.TeacherController) .to(TeacherController); + +// appointment +container + .bind(TYPES.AppointmentRepository) + .to(AppointmentRepository); +container + .bind(TYPES.AppointmentService) + .to(AppointmentService); +container + .bind(TYPES.AppointmentController) + .to(AppointmentController);