pub trait StatsRepository: Send + Sync {
// Required methods
fn get_admin_dashboard_stats<'life0, 'async_trait>(
&'life0 self,
) -> Pin<Box<dyn Future<Output = Result<AdminDashboardStats, AppError>> + Send + 'async_trait>>
where Self: 'async_trait,
'life0: 'async_trait;
fn get_seed_data_stats<'life0, 'async_trait>(
&'life0 self,
) -> Pin<Box<dyn Future<Output = Result<SeedDataStats, AppError>> + Send + 'async_trait>>
where Self: 'async_trait,
'life0: 'async_trait;
fn get_syndic_stats<'life0, 'async_trait>(
&'life0 self,
organization_id: Uuid,
) -> Pin<Box<dyn Future<Output = Result<SyndicDashboardStats, AppError>> + Send + 'async_trait>>
where Self: 'async_trait,
'life0: 'async_trait;
fn get_owner_stats<'life0, 'async_trait>(
&'life0 self,
owner_id: Uuid,
) -> Pin<Box<dyn Future<Output = Result<SyndicDashboardStats, AppError>> + Send + 'async_trait>>
where Self: 'async_trait,
'life0: 'async_trait;
fn get_owner_dues_by_acp<'life0, 'async_trait>(
&'life0 self,
owner_id: Uuid,
) -> Pin<Box<dyn Future<Output = Result<Vec<DuAupresDuneAcp>, AppError>> + Send + 'async_trait>>
where Self: 'async_trait,
'life0: 'async_trait;
fn find_owner_id_by_user_id<'life0, 'async_trait>(
&'life0 self,
user_id: Uuid,
) -> Pin<Box<dyn Future<Output = Result<Option<Uuid>, AppError>> + Send + 'async_trait>>
where Self: 'async_trait,
'life0: 'async_trait;
fn get_syndic_urgent_tasks<'life0, 'async_trait>(
&'life0 self,
organization_id: Uuid,
) -> Pin<Box<dyn Future<Output = Result<Vec<UrgentTask>, AppError>> + Send + 'async_trait>>
where Self: 'async_trait,
'life0: 'async_trait;
}Required Methods§
fn get_admin_dashboard_stats<'life0, 'async_trait>(
&'life0 self,
) -> Pin<Box<dyn Future<Output = Result<AdminDashboardStats, AppError>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
fn get_seed_data_stats<'life0, 'async_trait>(
&'life0 self,
) -> Pin<Box<dyn Future<Output = Result<SeedDataStats, AppError>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
Sourcefn get_syndic_stats<'life0, 'async_trait>(
&'life0 self,
organization_id: Uuid,
) -> Pin<Box<dyn Future<Output = Result<SyndicDashboardStats, AppError>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
fn get_syndic_stats<'life0, 'async_trait>(
&'life0 self,
organization_id: Uuid,
) -> Pin<Box<dyn Future<Output = Result<SyndicDashboardStats, AppError>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
Returns stats for all buildings in the given organization.
Sourcefn get_owner_stats<'life0, 'async_trait>(
&'life0 self,
owner_id: Uuid,
) -> Pin<Box<dyn Future<Output = Result<SyndicDashboardStats, AppError>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
fn get_owner_stats<'life0, 'async_trait>(
&'life0 self,
owner_id: Uuid,
) -> Pin<Box<dyn Future<Output = Result<SyndicDashboardStats, AppError>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
Returns stats for buildings where the given owner has active units.
Sourcefn get_owner_dues_by_acp<'life0, 'async_trait>(
&'life0 self,
owner_id: Uuid,
) -> Pin<Box<dyn Future<Output = Result<Vec<DuAupresDuneAcp>, AppError>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
fn get_owner_dues_by_acp<'life0, 'async_trait>(
&'life0 self,
owner_id: Uuid,
) -> Pin<Box<dyn Future<Output = Result<Vec<DuAupresDuneAcp>, AppError>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
Ce que le copropriétaire doit, ventilé par association.
Séparée de get_owner_stats parce qu’elle répond à une autre question :
celle-là dit « combien », celle-ci dit « à QUI ». Un copropriétaire peut
détenir des lots dans plusieurs ACP, et chacune est une personne morale
avec son propre compte bancaire (Art. 3.86 § 1er et § 3).
Un montant global laisse croire qu’un virement unique suffit. Il paierait la mauvaise personne morale pour une partie de la somme (#867).
Liste vide si le copropriétaire ne doit rien : c’est une bonne nouvelle, pas une erreur.
Sourcefn find_owner_id_by_user_id<'life0, 'async_trait>(
&'life0 self,
user_id: Uuid,
) -> Pin<Box<dyn Future<Output = Result<Option<Uuid>, AppError>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
fn find_owner_id_by_user_id<'life0, 'async_trait>(
&'life0 self,
user_id: Uuid,
) -> Pin<Box<dyn Future<Output = Result<Option<Uuid>, AppError>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
Looks up the owner record id associated with a user id.
Sourcefn get_syndic_urgent_tasks<'life0, 'async_trait>(
&'life0 self,
organization_id: Uuid,
) -> Pin<Box<dyn Future<Output = Result<Vec<UrgentTask>, AppError>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
fn get_syndic_urgent_tasks<'life0, 'async_trait>(
&'life0 self,
organization_id: Uuid,
) -> Pin<Box<dyn Future<Output = Result<Vec<UrgentTask>, AppError>> + Send + 'async_trait>>where
Self: 'async_trait,
'life0: 'async_trait,
Returns urgent tasks (overdue expenses, upcoming meetings, old pending charges) for the given organization.
Dyn Compatibility§
This trait is dyn compatible.
In older versions of Rust, dyn compatibility was called "object safety".