feat(train-crew): implement train crew management module

- Added DTOs for creating, querying, and updating train crew members.
- Created entity for train crew members with relevant fields and enums for role, nationality, and status.
- Developed service for handling CRUD operations and ensuring no duplicate crew members.
- Implemented controller to manage API endpoints for train crew operations.
- Integrated permissions for viewing, creating, updating, and deleting train crew members.
- Added frontend components for displaying, adding, editing, and deleting train crew members.
- Established API service for interacting with the train crew backend.
- Updated routing and sidebar to include train crew management section.
This commit is contained in:
marshalyordanos
2026-09-04 20:45:41 +03:00
parent ca84aac456
commit 8437a6d5f1
18 changed files with 1086 additions and 0 deletions

View File

@@ -194,6 +194,13 @@ export const QUERY_KEYS = {
byId: (id: string) => ["vehicles", "detail", id] as const,
},
TRAIN_CREW: {
ROOT: ["train-crew"] as const,
list: (filter?: Record<string, unknown>) =>
["train-crew", "list", filter ?? {}] as const,
byId: (id: string) => ["train-crew", "detail", id] as const,
},
FIRST_MILE: {
ROOT: ["first-mile"] as const,
list: (filter?: Record<string, unknown>) =>

View File

@@ -870,4 +870,9 @@ export const URL_CONSTANTS = {
BASE: "/drivers",
BY_ID: (id: string) => `/drivers/${id}`,
},
TRAIN_CREW: {
BASE: "/train-crew",
BY_ID: (id: string) => `/train-crew/${id}`,
},
};