Files
worker/lib/features/auth/presentation/providers/customer_groups_provider.g.dart
2025-11-07 15:55:02 +07:00

165 lines
4.9 KiB
Dart

// GENERATED CODE - DO NOT MODIFY BY HAND
part of 'customer_groups_provider.dart';
// **************************************************************************
// RiverpodGenerator
// **************************************************************************
// GENERATED CODE - DO NOT MODIFY BY HAND
// ignore_for_file: type=lint, type=warning
/// Customer Groups Provider
///
/// Fetches list of customer groups (roles) from API for registration form.
/// Requires active session (CSRF token and SID).
/// keepAlive: true ensures the customer groups list persists and doesn't auto-dispose.
@ProviderFor(CustomerGroups)
const customerGroupsProvider = CustomerGroupsProvider._();
/// Customer Groups Provider
///
/// Fetches list of customer groups (roles) from API for registration form.
/// Requires active session (CSRF token and SID).
/// keepAlive: true ensures the customer groups list persists and doesn't auto-dispose.
final class CustomerGroupsProvider
extends $AsyncNotifierProvider<CustomerGroups, List<CustomerGroup>> {
/// Customer Groups Provider
///
/// Fetches list of customer groups (roles) from API for registration form.
/// Requires active session (CSRF token and SID).
/// keepAlive: true ensures the customer groups list persists and doesn't auto-dispose.
const CustomerGroupsProvider._()
: super(
from: null,
argument: null,
retry: null,
name: r'customerGroupsProvider',
isAutoDispose: false,
dependencies: null,
$allTransitiveDependencies: null,
);
@override
String debugGetCreateSourceHash() => _$customerGroupsHash();
@$internal
@override
CustomerGroups create() => CustomerGroups();
}
String _$customerGroupsHash() => r'df9107ef844e3cd320804af8d5dcf2fee2462208';
/// Customer Groups Provider
///
/// Fetches list of customer groups (roles) from API for registration form.
/// Requires active session (CSRF token and SID).
/// keepAlive: true ensures the customer groups list persists and doesn't auto-dispose.
abstract class _$CustomerGroups extends $AsyncNotifier<List<CustomerGroup>> {
FutureOr<List<CustomerGroup>> build();
@$mustCallSuper
@override
void runBuild() {
final created = build();
final ref =
this.ref as $Ref<AsyncValue<List<CustomerGroup>>, List<CustomerGroup>>;
final element =
ref.element
as $ClassProviderElement<
AnyNotifier<AsyncValue<List<CustomerGroup>>, List<CustomerGroup>>,
AsyncValue<List<CustomerGroup>>,
Object?,
Object?
>;
element.handleValue(ref, created);
}
}
/// Provider to get a specific customer group by code/value
@ProviderFor(customerGroupByCode)
const customerGroupByCodeProvider = CustomerGroupByCodeFamily._();
/// Provider to get a specific customer group by code/value
final class CustomerGroupByCodeProvider
extends $FunctionalProvider<CustomerGroup?, CustomerGroup?, CustomerGroup?>
with $Provider<CustomerGroup?> {
/// Provider to get a specific customer group by code/value
const CustomerGroupByCodeProvider._({
required CustomerGroupByCodeFamily super.from,
required String super.argument,
}) : super(
retry: null,
name: r'customerGroupByCodeProvider',
isAutoDispose: true,
dependencies: null,
$allTransitiveDependencies: null,
);
@override
String debugGetCreateSourceHash() => _$customerGroupByCodeHash();
@override
String toString() {
return r'customerGroupByCodeProvider'
''
'($argument)';
}
@$internal
@override
$ProviderElement<CustomerGroup?> $createElement($ProviderPointer pointer) =>
$ProviderElement(pointer);
@override
CustomerGroup? create(Ref ref) {
final argument = this.argument as String;
return customerGroupByCode(ref, argument);
}
/// {@macro riverpod.override_with_value}
Override overrideWithValue(CustomerGroup? value) {
return $ProviderOverride(
origin: this,
providerOverride: $SyncValueProvider<CustomerGroup?>(value),
);
}
@override
bool operator ==(Object other) {
return other is CustomerGroupByCodeProvider && other.argument == argument;
}
@override
int get hashCode {
return argument.hashCode;
}
}
String _$customerGroupByCodeHash() =>
r'0ddf96a19d7c20c9fe3ddfd2af80ac49bfe76512';
/// Provider to get a specific customer group by code/value
final class CustomerGroupByCodeFamily extends $Family
with $FunctionalFamilyOverride<CustomerGroup?, String> {
const CustomerGroupByCodeFamily._()
: super(
retry: null,
name: r'customerGroupByCodeProvider',
dependencies: null,
$allTransitiveDependencies: null,
isAutoDispose: true,
);
/// Provider to get a specific customer group by code/value
CustomerGroupByCodeProvider call(String code) =>
CustomerGroupByCodeProvider._(argument: code, from: this);
@override
String toString() => r'customerGroupByCodeProvider';
}