2025-10-26 22:57:22 +07:00

17 lines
504 B
Dart

part of 'customer_loader_bloc.dart';
@freezed
class CustomerLoaderState with _$CustomerLoaderState {
factory CustomerLoaderState({
required List<Customer> customers,
required Option<CustomerFailure> failureOrOption,
Customer? selectedCustomer,
@Default(false) bool isFetching,
@Default(false) bool hasReachedMax,
@Default(1) int page,
}) = _CustomerLoaderState;
factory CustomerLoaderState.initial() =>
CustomerLoaderState(customers: [], failureOrOption: none());
}