Commit Graph

2 Commits

Author SHA1 Message Date
limitcool
b7628c770b Refactor user handler and middleware for improved error handling and logging
- Consolidated user ID retrieval and permission checks into helper functions.
- Updated UserHandler to utilize BaseHandler for common database and configuration access.
- Enhanced logging for user-related operations, including login, registration, and password changes.
- Removed redundant context handling in middleware and improved readability.
- Introduced FileUtil for file URL generation and management, encapsulating file-related logic.
- Refactored FileRepo and UserRepo to streamline database operations and error handling.
- Deleted unused request_id middleware and integrated its functionality into request_logger.
- Removed legacy test runner script to simplify testing process.
2025-06-17 23:09:02 +08:00
limitcool
df066bc077 feat: Implement user and admin services with separate and simple modes
- Added middleware utility functions to retrieve user IDs from context.
- Created separate and simple routing structures for user and admin functionalities.
- Developed user and admin service interfaces with implementations for both separate and simple modes.
- Implemented user registration, login, password change, and user info retrieval functionalities.
- Integrated role, menu, and permission management within the admin services.
- Established lifecycle hooks for service initialization and shutdown logging.
- Enhanced error handling and logging throughout the service methods.
2025-04-22 21:31:49 +08:00