feat(order info): added order info screen

This commit is contained in:
Username1548
2025-04-04 20:21:31 +07:00
parent 9715f4cac9
commit 748484cf8f
387 changed files with 16171 additions and 18199 deletions

View File

@@ -61,7 +61,7 @@ class AboutPlanCubit extends Cubit<AboutPlanState> {
EasyDebounce.debounce(
'like_plan_$slug',
Duration(seconds: 1),
const Duration(seconds: 1),
() async {
try {
await planRepository.likePlan(slug);
@@ -86,7 +86,7 @@ class AboutPlanCubit extends Cubit<AboutPlanState> {
}
EasyDebounce.debounce(
'add_or_remove_plan_to_favorites',
Duration(seconds: 1),
const Duration(seconds: 1),
() async {
try {
await planRepository.addToFavorite(slug);
@@ -112,7 +112,7 @@ class AboutPlanCubit extends Cubit<AboutPlanState> {
}
EasyDebounce.debounce(
'add_or_remove_plan_to_favorites',
Duration(seconds: 1),
const Duration(seconds: 1),
() async {
try {
await planRepository.removeFromFavorite(slug);

View File

@@ -12,8 +12,7 @@ part of 'about_plan_state.dart';
T _$identity<T>(T value) => value;
final _privateConstructorUsedError = UnsupportedError(
'It seems like you constructed your class using `MyClass._()`. This constructor is only meant to be used by freezed and you are not supposed to need it nor use it.\nPlease check the documentation here for more information: https://github.com/rrousselGit/freezed#adding-getters-and-methods-to-our-models',
);
'It seems like you constructed your class using `MyClass._()`. This constructor is only meant to be used by freezed and you are not supposed to need it nor use it.\nPlease check the documentation here for more information: https://github.com/rrousselGit/freezed#adding-getters-and-methods-to-our-models');
/// @nodoc
mixin _$AboutPlanState {
@@ -32,16 +31,14 @@ mixin _$AboutPlanState {
/// @nodoc
abstract class $AboutPlanStateCopyWith<$Res> {
factory $AboutPlanStateCopyWith(
AboutPlanState value,
$Res Function(AboutPlanState) then,
) = _$AboutPlanStateCopyWithImpl<$Res, AboutPlanState>;
AboutPlanState value, $Res Function(AboutPlanState) then) =
_$AboutPlanStateCopyWithImpl<$Res, AboutPlanState>;
@useResult
$Res call({
bool isLoading,
String? error,
PlanModel? planModel,
int chosenOptionIndex,
});
$Res call(
{bool isLoading,
String? error,
PlanModel? planModel,
int chosenOptionIndex});
$PlanModelCopyWith<$Res>? get planModel;
}
@@ -66,31 +63,24 @@ class _$AboutPlanStateCopyWithImpl<$Res, $Val extends AboutPlanState>
Object? planModel = freezed,
Object? chosenOptionIndex = null,
}) {
return _then(
_value.copyWith(
isLoading:
null == isLoading
? _value.isLoading
: isLoading // ignore: cast_nullable_to_non_nullable
as bool,
error:
freezed == error
? _value.error
: error // ignore: cast_nullable_to_non_nullable
as String?,
planModel:
freezed == planModel
? _value.planModel
: planModel // ignore: cast_nullable_to_non_nullable
as PlanModel?,
chosenOptionIndex:
null == chosenOptionIndex
? _value.chosenOptionIndex
: chosenOptionIndex // ignore: cast_nullable_to_non_nullable
as int,
)
as $Val,
);
return _then(_value.copyWith(
isLoading: null == isLoading
? _value.isLoading
: isLoading // ignore: cast_nullable_to_non_nullable
as bool,
error: freezed == error
? _value.error
: error // ignore: cast_nullable_to_non_nullable
as String?,
planModel: freezed == planModel
? _value.planModel
: planModel // ignore: cast_nullable_to_non_nullable
as PlanModel?,
chosenOptionIndex: null == chosenOptionIndex
? _value.chosenOptionIndex
: chosenOptionIndex // ignore: cast_nullable_to_non_nullable
as int,
) as $Val);
}
/// Create a copy of AboutPlanState
@@ -111,18 +101,16 @@ class _$AboutPlanStateCopyWithImpl<$Res, $Val extends AboutPlanState>
/// @nodoc
abstract class _$$AboutPlanStateImplCopyWith<$Res>
implements $AboutPlanStateCopyWith<$Res> {
factory _$$AboutPlanStateImplCopyWith(
_$AboutPlanStateImpl value,
$Res Function(_$AboutPlanStateImpl) then,
) = __$$AboutPlanStateImplCopyWithImpl<$Res>;
factory _$$AboutPlanStateImplCopyWith(_$AboutPlanStateImpl value,
$Res Function(_$AboutPlanStateImpl) then) =
__$$AboutPlanStateImplCopyWithImpl<$Res>;
@override
@useResult
$Res call({
bool isLoading,
String? error,
PlanModel? planModel,
int chosenOptionIndex,
});
$Res call(
{bool isLoading,
String? error,
PlanModel? planModel,
int chosenOptionIndex});
@override
$PlanModelCopyWith<$Res>? get planModel;
@@ -133,9 +121,8 @@ class __$$AboutPlanStateImplCopyWithImpl<$Res>
extends _$AboutPlanStateCopyWithImpl<$Res, _$AboutPlanStateImpl>
implements _$$AboutPlanStateImplCopyWith<$Res> {
__$$AboutPlanStateImplCopyWithImpl(
_$AboutPlanStateImpl _value,
$Res Function(_$AboutPlanStateImpl) _then,
) : super(_value, _then);
_$AboutPlanStateImpl _value, $Res Function(_$AboutPlanStateImpl) _then)
: super(_value, _then);
/// Create a copy of AboutPlanState
/// with the given fields replaced by the non-null parameter values.
@@ -147,42 +134,35 @@ class __$$AboutPlanStateImplCopyWithImpl<$Res>
Object? planModel = freezed,
Object? chosenOptionIndex = null,
}) {
return _then(
_$AboutPlanStateImpl(
isLoading:
null == isLoading
? _value.isLoading
: isLoading // ignore: cast_nullable_to_non_nullable
as bool,
error:
freezed == error
? _value.error
: error // ignore: cast_nullable_to_non_nullable
as String?,
planModel:
freezed == planModel
? _value.planModel
: planModel // ignore: cast_nullable_to_non_nullable
as PlanModel?,
chosenOptionIndex:
null == chosenOptionIndex
? _value.chosenOptionIndex
: chosenOptionIndex // ignore: cast_nullable_to_non_nullable
as int,
),
);
return _then(_$AboutPlanStateImpl(
isLoading: null == isLoading
? _value.isLoading
: isLoading // ignore: cast_nullable_to_non_nullable
as bool,
error: freezed == error
? _value.error
: error // ignore: cast_nullable_to_non_nullable
as String?,
planModel: freezed == planModel
? _value.planModel
: planModel // ignore: cast_nullable_to_non_nullable
as PlanModel?,
chosenOptionIndex: null == chosenOptionIndex
? _value.chosenOptionIndex
: chosenOptionIndex // ignore: cast_nullable_to_non_nullable
as int,
));
}
}
/// @nodoc
class _$AboutPlanStateImpl implements _AboutPlanState {
const _$AboutPlanStateImpl({
required this.isLoading,
required this.error,
required this.planModel,
required this.chosenOptionIndex,
});
const _$AboutPlanStateImpl(
{required this.isLoading,
required this.error,
required this.planModel,
required this.chosenOptionIndex});
@override
final bool isLoading;
@@ -223,18 +203,15 @@ class _$AboutPlanStateImpl implements _AboutPlanState {
@pragma('vm:prefer-inline')
_$$AboutPlanStateImplCopyWith<_$AboutPlanStateImpl> get copyWith =>
__$$AboutPlanStateImplCopyWithImpl<_$AboutPlanStateImpl>(
this,
_$identity,
);
this, _$identity);
}
abstract class _AboutPlanState implements AboutPlanState {
const factory _AboutPlanState({
required final bool isLoading,
required final String? error,
required final PlanModel? planModel,
required final int chosenOptionIndex,
}) = _$AboutPlanStateImpl;
const factory _AboutPlanState(
{required final bool isLoading,
required final String? error,
required final PlanModel? planModel,
required final int chosenOptionIndex}) = _$AboutPlanStateImpl;
@override
bool get isLoading;