# Conflicts:
#	lib/presentation/navigation/app_router.dart
#	pubspec.yaml
This commit is contained in:
2026-08-11 00:14:00 +03:00
parent c9b8d143d1
commit 182be1049b
351 changed files with 24566 additions and 22898 deletions

View File

@@ -1,43 +1,43 @@
import '../../domain/entities/client_notification.dart';
enum NotificationsStatus { initial, loading, loadingMore, success, failure }
class NotificationsState {
final NotificationsStatus status;
final List<ClientNotification> notifications;
final String? errorMessage;
final int currentPage;
final int totalPages;
final bool hasMore;
final bool isLoadingMore;
const NotificationsState({
this.status = NotificationsStatus.initial,
this.notifications = const [],
this.errorMessage,
this.currentPage = 1,
this.totalPages = 1,
this.hasMore = true,
this.isLoadingMore = false,
});
NotificationsState copyWith({
NotificationsStatus? status,
List<ClientNotification>? notifications,
String? errorMessage,
int? currentPage,
int? totalPages,
bool? hasMore,
bool? isLoadingMore,
}) {
return NotificationsState(
status: status ?? this.status,
notifications: notifications ?? this.notifications,
errorMessage: errorMessage ?? this.errorMessage,
currentPage: currentPage ?? this.currentPage,
totalPages: totalPages ?? this.totalPages,
hasMore: hasMore ?? this.hasMore,
isLoadingMore: isLoadingMore ?? this.isLoadingMore,
);
}
import '../../domain/entities/client_notification.dart';
enum NotificationsStatus { initial, loading, loadingMore, success, failure }
class NotificationsState {
final NotificationsStatus status;
final List<ClientNotification> notifications;
final String? errorMessage;
final int currentPage;
final int totalPages;
final bool hasMore;
final bool isLoadingMore;
const NotificationsState({
this.status = NotificationsStatus.initial,
this.notifications = const [],
this.errorMessage,
this.currentPage = 1,
this.totalPages = 1,
this.hasMore = true,
this.isLoadingMore = false,
});
NotificationsState copyWith({
NotificationsStatus? status,
List<ClientNotification>? notifications,
String? errorMessage,
int? currentPage,
int? totalPages,
bool? hasMore,
bool? isLoadingMore,
}) {
return NotificationsState(
status: status ?? this.status,
notifications: notifications ?? this.notifications,
errorMessage: errorMessage ?? this.errorMessage,
currentPage: currentPage ?? this.currentPage,
totalPages: totalPages ?? this.totalPages,
hasMore: hasMore ?? this.hasMore,
isLoadingMore: isLoadingMore ?? this.isLoadingMore,
);
}
}