feat: Enhance Hackathon Timeline Management and Admin Features

- Updated HackathonTimelineCreateRequestDto to accept optional title and name fields.
- Added custom validators for HackathonPhase and date checks in hackathon_dto.rs.
- Implemented admin-sensitive data management DTOs for handling user scores and personal info.
- Introduced new admin routes for managing users, roles, and permissions in IAM module.
- Added timeline enforcement middleware to restrict access based on hackathon phases.
- Created tests for timeline enforcement and admin permissions to ensure proper access control.
- Implemented payment middleware as a placeholder for future payment processing logic.
- Enhanced audit logging middleware for improved error handling and logging.
This commit is contained in:
MythEclipse
2025-10-13 10:57:53 +07:00
parent 6f596efadd
commit 6915a97d79
28 changed files with 1331 additions and 114 deletions
+2 -2
View File
@@ -21,7 +21,7 @@ use imphnen_iam::{
v1::auth::auth_repository::AuthRepoImpl,
};
use imphnen_libs::{AppState, SurrealMemClient, SurrealWsClient};
use imphnen_middleware::{auth_middleware, cors_middleware, auth_rate_limiting_middleware, security_headers_middleware};
use imphnen_middleware::{auth_middleware, cors_middleware, rate_limiting_middleware, security_headers_middleware};
use std::sync::Arc;
use utoipa_swagger_ui::SwaggerUi;
@@ -40,7 +40,7 @@ pub async fn gateway_service(
};
let public_routes = Router::new()
.merge(iam_public_routes().layer(from_fn(auth_rate_limiting_middleware)))
.merge(iam_public_routes().layer(from_fn(rate_limiting_middleware)))
.merge(hackathon_public_routes())
.merge(testimonials_public_routes())
.merge(events_public_routes());