feat: Implement person and tag management services
- Added `Person` and `Tag` models to the core library. - Created `PersonService` and `TagService` traits with implementations for managing persons and tags. - Introduced repositories for `Person`, `Tag`, `FaceRegion`, and `PersonShare` with PostgreSQL support. - Updated authorization logic to include permissions for accessing and editing persons. - Enhanced the schema to support new models and relationships. - Implemented database migrations for new tables related to persons and tags. - Added request and response structures for API interactions with persons and tags.
This commit is contained in:
@@ -2,7 +2,7 @@ use std::sync::Arc;
|
||||
|
||||
use libertas_core::{
|
||||
config::AppConfig,
|
||||
services::{AlbumService, MediaService, UserService},
|
||||
services::{AlbumService, MediaService, PersonService, TagService, UserService},
|
||||
};
|
||||
|
||||
use crate::security::TokenGenerator;
|
||||
@@ -12,6 +12,8 @@ pub struct AppState {
|
||||
pub user_service: Arc<dyn UserService>,
|
||||
pub media_service: Arc<dyn MediaService>,
|
||||
pub album_service: Arc<dyn AlbumService>,
|
||||
pub tag_service: Arc<dyn TagService>,
|
||||
pub person_service: Arc<dyn PersonService>,
|
||||
pub token_generator: Arc<dyn TokenGenerator>,
|
||||
pub nats_client: async_nats::Client,
|
||||
pub config: AppConfig,
|
||||
|
||||
Reference in New Issue
Block a user