passo_mobile_app/lib/bloc/profile/eligibility/eligibility_state.dart

121 lines
3.5 KiB
Dart
Raw Permalink Normal View History

part of 'eligibility_bloc.dart';
abstract class EligibilityState extends Equatable {
const EligibilityState();
@override
List<Object> get props => [];
}
class EligibilityInitial extends EligibilityState {}
class EditEligibilityState extends EligibilityState {
final EligibityCert eligibityCert;
final List<Eligibility> eligibilities;
final List<Country> countries;
final List<Region> regions;
final List<Province>? provinces;
final List<CityMunicipality>? cities;
final bool isOverseas;
final Eligibility currentEligibility;
final Region? currentRegion;
final Province? currentProvince;
final CityMunicipality? currentCity;
final Country selectedCountry;
const EditEligibilityState({
required this.provinces,
required this.cities,
required this.currentProvince,
required this.currentCity,
required this.currentRegion,
required this.currentEligibility,
required this.isOverseas,
required this.eligibityCert,
required this.eligibilities,
required this.countries,
required this.regions,
required this.selectedCountry,
});
@override
List<Object> get props =>
[isOverseas, eligibityCert, eligibilities, regions, countries];
}
2023-08-07 06:33:38 +00:00
class EligibilityDeletedState extends EligibilityState {
final bool success;
2023-08-07 06:33:38 +00:00
const EligibilityDeletedState({required this.success});
@override
2023-04-11 01:27:53 +00:00
List<Object> get props => [success];
}
class AddEligibilityState extends EligibilityState {
final List<Eligibility> eligibilities;
final List<Country> countries;
final List<Region> regions;
const AddEligibilityState({
required this.eligibilities,
required this.countries,
required this.regions,
});
@override
List<Object> get props => [eligibilities, countries, regions];
}
class EligibilityEditedState extends EligibilityState {
final Map<dynamic, dynamic> response;
2023-04-11 01:27:53 +00:00
const EligibilityEditedState({required this.response});
@override
List<Object> get props => [response];
}
class EligibilityAddedState extends EligibilityState {
final Map<dynamic, dynamic> response;
const EligibilityAddedState({required this.response});
@override
List<Object> get props => [response];
}
class EligibilityLoadingState extends EligibilityState {}
class EligibilityErrorState extends EligibilityState {
final String message;
const EligibilityErrorState({required this.message});
@override
List<Object> get props => [message];
}
class EligibilityLoaded extends EligibilityState {
final List< AttachmentCategory> attachmentCategory;
final List<EligibityCert> eligibilities;
const EligibilityLoaded({required this.eligibilities, required this.attachmentCategory});
@override
List<Object> get props => [eligibilities];
}
2023-08-07 06:33:38 +00:00
////Attachment AddedState
class EligibilityAttachmentAddedState extends EligibilityState {
final Map<dynamic, dynamic> response;
const EligibilityAttachmentAddedState({required this.response});
}
////Attachment Deleted State State
class EligibilitytAttachmentDeletedState extends EligibilityState {
final bool success;
const EligibilitytAttachmentDeletedState({required this.success});
@override
List<Object> get props => [success];
}
2023-08-27 08:38:05 +00:00
class EligibilityAttachmentViewState extends EligibilityState {
final String fileName;
2023-08-27 08:38:05 +00:00
final String fileUrl;
const EligibilityAttachmentViewState({required this.fileUrl, required this.fileName});
2023-08-27 08:38:05 +00:00
}
class EligibilityAttachmentShareState extends EligibilityState{
final bool success;
const EligibilityAttachmentShareState({required this.success,});
}