refactoring
This commit is contained in:
@@ -10,27 +10,33 @@ abstract class DashboardEvent extends Equatable {
|
||||
class LoadDashboardData extends DashboardEvent {
|
||||
final String organizationId;
|
||||
final String userId;
|
||||
/// Si true, utilise le dashboard global (stats toutes orgs) même quand organizationId est vide.
|
||||
/// Utilisé pour SUPER_ADMIN qui n'appartient pas à une org.
|
||||
final bool useGlobalDashboard;
|
||||
|
||||
const LoadDashboardData({
|
||||
required this.organizationId,
|
||||
required this.userId,
|
||||
this.useGlobalDashboard = false,
|
||||
});
|
||||
|
||||
@override
|
||||
List<Object> get props => [organizationId, userId];
|
||||
List<Object> get props => [organizationId, userId, useGlobalDashboard];
|
||||
}
|
||||
|
||||
class RefreshDashboardData extends DashboardEvent {
|
||||
final String organizationId;
|
||||
final String userId;
|
||||
final bool useGlobalDashboard;
|
||||
|
||||
const RefreshDashboardData({
|
||||
required this.organizationId,
|
||||
required this.userId,
|
||||
this.useGlobalDashboard = false,
|
||||
});
|
||||
|
||||
@override
|
||||
List<Object> get props => [organizationId, userId];
|
||||
List<Object> get props => [organizationId, userId, useGlobalDashboard];
|
||||
}
|
||||
|
||||
class LoadDashboardStats extends DashboardEvent {
|
||||
|
||||
Reference in New Issue
Block a user