Refactor and enhance SurrealDB integration and resource management

- Updated `lib.rs` to selectively expose specific entities and services for better clarity.
- Improved SurrealDB client initialization with detailed logging in `surrealdb/mod.rs`.
- Enhanced resource definitions in `resource.rs` with additional utility methods for better resource management.
- Refactored user data retrieval logic in `auth_middleware/mod.rs` for improved readability and efficiency.
- Cleaned up middleware exports in `lib.rs` for clearer API surface.
- Added detailed comments and documentation throughout the SurrealDB module for better maintainability.
- Updated tests to ensure compatibility with new changes and improved structure.
- Introduced new permissions module structure in `imphnen-utils` for future enhancements.
This commit is contained in:
MythEclipse
2025-09-26 17:35:30 +07:00
parent 96debc210a
commit 14b22328de
71 changed files with 1566 additions and 632 deletions
@@ -1,8 +1,7 @@
use super::GachaItemSchema;
use crate::{
AppState, GachaItemDto, MetaRequestDto, ResourceEnum, ResponseListSuccessDto,
get_id, make_thing,
};
use crate::v1::gacha_items::gacha_items_schema::GachaItemSchema;
use crate::{AppState, MetaRequestDto, ResponseListSuccessDto, get_id, make_thing};
use crate::v1::gacha_items::GachaItemDto;
use imphnen_libs::ResourceEnum;
use anyhow::{Result, bail};
use imphnen_iam::QueryListBuilder;
use imphnen_utils::get_iso_date;