This commit is contained in:
2026-07-13 01:38:13 +03:00
parent 9eda119527
commit 98c5a7a1d1
54 changed files with 860 additions and 454 deletions

View File

@@ -1,4 +1,5 @@
import '../entities/client_notification.dart';
import '../entities/pagination_meta.dart';
import '../repositories/notification_repository.dart';
class GetNotificationsUsecase {
@@ -6,7 +7,17 @@ class GetNotificationsUsecase {
GetNotificationsUsecase(this.repository);
Future<List<ClientNotification>> call() {
return repository.getNotifications();
Future<NotificationsResult> call({int page = 1, int pageSize = 10}) {
return repository.getNotifications(page: page, pageSize: pageSize);
}
}
class NotificationsResult {
final List<ClientNotification> notifications;
final PaginationMeta pagination;
NotificationsResult({
required this.notifications,
required this.pagination,
});
}