35 lines
684 B
Dart
35 lines
684 B
Dart
|
|
part of 'company_settings_cubit.dart';
|
||
|
|
|
||
|
|
class CompanySettingsState {
|
||
|
|
final CompanySettingsStatus status;
|
||
|
|
final CompanyModel? company;
|
||
|
|
final String? errorMessage;
|
||
|
|
|
||
|
|
const CompanySettingsState({
|
||
|
|
this.status = CompanySettingsStatus.initial,
|
||
|
|
this.company,
|
||
|
|
this.errorMessage,
|
||
|
|
});
|
||
|
|
|
||
|
|
CompanySettingsState copyWith({
|
||
|
|
CompanySettingsStatus? status,
|
||
|
|
CompanyModel? company,
|
||
|
|
String? errorMessage,
|
||
|
|
}) {
|
||
|
|
return CompanySettingsState(
|
||
|
|
status: status ?? this.status,
|
||
|
|
company: company ?? this.company,
|
||
|
|
errorMessage: errorMessage,
|
||
|
|
);
|
||
|
|
}
|
||
|
|
}
|
||
|
|
|
||
|
|
enum CompanySettingsStatus {
|
||
|
|
initial,
|
||
|
|
ready,
|
||
|
|
saving,
|
||
|
|
uploadingLogo,
|
||
|
|
success,
|
||
|
|
failure,
|
||
|
|
}
|