forked from eatvio/eatvio_app
socket fixed
This commit is contained in:
@@ -39,7 +39,7 @@ class PlanModel with _$PlanModel {
|
||||
@JsonKey(name: "is_favorite") required bool isFavorite,
|
||||
@JsonKey(name: "min_price_of_options") required double minPriceOfOptions,
|
||||
@JsonKey(name: "max_price_of_options") required double maxPriceOfOptions,
|
||||
@Default(false) bool wasLikedByMe,
|
||||
@JsonKey(name: "was_liked_by_me") required bool wasLikedByMe,
|
||||
}) = _PlanModel;
|
||||
|
||||
factory PlanModel.fromJson(Map<String, dynamic> json) => _$PlanModelFromJson(json);
|
||||
|
||||
@@ -298,6 +298,7 @@ mixin _$PlanModel {
|
||||
double get minPriceOfOptions => throw _privateConstructorUsedError;
|
||||
@JsonKey(name: "max_price_of_options")
|
||||
double get maxPriceOfOptions => throw _privateConstructorUsedError;
|
||||
@JsonKey(name: "was_liked_by_me")
|
||||
bool get wasLikedByMe => throw _privateConstructorUsedError;
|
||||
|
||||
/// Serializes this PlanModel to a JSON map.
|
||||
@@ -335,7 +336,7 @@ abstract class $PlanModelCopyWith<$Res> {
|
||||
@JsonKey(name: "is_favorite") bool isFavorite,
|
||||
@JsonKey(name: "min_price_of_options") double minPriceOfOptions,
|
||||
@JsonKey(name: "max_price_of_options") double maxPriceOfOptions,
|
||||
bool wasLikedByMe});
|
||||
@JsonKey(name: "was_liked_by_me") bool wasLikedByMe});
|
||||
|
||||
$PlanTypeCopyWith<$Res> get type;
|
||||
$PacketOptionsCopyWith<$Res>? get packet1Options;
|
||||
@@ -555,7 +556,7 @@ abstract class _$$PlanModelImplCopyWith<$Res>
|
||||
@JsonKey(name: "is_favorite") bool isFavorite,
|
||||
@JsonKey(name: "min_price_of_options") double minPriceOfOptions,
|
||||
@JsonKey(name: "max_price_of_options") double maxPriceOfOptions,
|
||||
bool wasLikedByMe});
|
||||
@JsonKey(name: "was_liked_by_me") bool wasLikedByMe});
|
||||
|
||||
@override
|
||||
$PlanTypeCopyWith<$Res> get type;
|
||||
@@ -711,7 +712,7 @@ class _$PlanModelImpl implements _PlanModel {
|
||||
@JsonKey(name: "is_favorite") required this.isFavorite,
|
||||
@JsonKey(name: "min_price_of_options") required this.minPriceOfOptions,
|
||||
@JsonKey(name: "max_price_of_options") required this.maxPriceOfOptions,
|
||||
this.wasLikedByMe = false});
|
||||
@JsonKey(name: "was_liked_by_me") required this.wasLikedByMe});
|
||||
|
||||
factory _$PlanModelImpl.fromJson(Map<String, dynamic> json) =>
|
||||
_$$PlanModelImplFromJson(json);
|
||||
@@ -774,7 +775,7 @@ class _$PlanModelImpl implements _PlanModel {
|
||||
@JsonKey(name: "max_price_of_options")
|
||||
final double maxPriceOfOptions;
|
||||
@override
|
||||
@JsonKey()
|
||||
@JsonKey(name: "was_liked_by_me")
|
||||
final bool wasLikedByMe;
|
||||
|
||||
@override
|
||||
@@ -865,29 +866,30 @@ class _$PlanModelImpl implements _PlanModel {
|
||||
|
||||
abstract class _PlanModel implements PlanModel {
|
||||
const factory _PlanModel(
|
||||
{@JsonKey(name: "id") required final int id,
|
||||
@JsonKey(name: "slug") required final String slug,
|
||||
@JsonKey(name: "name") required final String name,
|
||||
@JsonKey(name: "image") required final String image,
|
||||
@JsonKey(name: "duration") required final int duration,
|
||||
@JsonKey(name: "state") required final String state,
|
||||
@JsonKey(name: "type", fromJson: planTypeFromJson)
|
||||
required final PlanType type,
|
||||
@JsonKey(name: "details") required final String details,
|
||||
@JsonKey(name: "packets_count") required final int packetsCount,
|
||||
@JsonKey(name: "packet1_options") final PacketOptions? packet1Options,
|
||||
@JsonKey(name: "packet2_options") final PacketOptions? packet2Options,
|
||||
@JsonKey(name: "packet3_options") final PacketOptions? packet3Options,
|
||||
@JsonKey(name: "author") required final Author author,
|
||||
@JsonKey(name: "total_likes") required final int totalLikes,
|
||||
@JsonKey(name: "total_views") required final int totalViews,
|
||||
@JsonKey(name: "total_comments") required final int totalComments,
|
||||
@JsonKey(name: "is_favorite") required final bool isFavorite,
|
||||
@JsonKey(name: "min_price_of_options")
|
||||
required final double minPriceOfOptions,
|
||||
@JsonKey(name: "max_price_of_options")
|
||||
required final double maxPriceOfOptions,
|
||||
final bool wasLikedByMe}) = _$PlanModelImpl;
|
||||
{@JsonKey(name: "id") required final int id,
|
||||
@JsonKey(name: "slug") required final String slug,
|
||||
@JsonKey(name: "name") required final String name,
|
||||
@JsonKey(name: "image") required final String image,
|
||||
@JsonKey(name: "duration") required final int duration,
|
||||
@JsonKey(name: "state") required final String state,
|
||||
@JsonKey(name: "type", fromJson: planTypeFromJson)
|
||||
required final PlanType type,
|
||||
@JsonKey(name: "details") required final String details,
|
||||
@JsonKey(name: "packets_count") required final int packetsCount,
|
||||
@JsonKey(name: "packet1_options") final PacketOptions? packet1Options,
|
||||
@JsonKey(name: "packet2_options") final PacketOptions? packet2Options,
|
||||
@JsonKey(name: "packet3_options") final PacketOptions? packet3Options,
|
||||
@JsonKey(name: "author") required final Author author,
|
||||
@JsonKey(name: "total_likes") required final int totalLikes,
|
||||
@JsonKey(name: "total_views") required final int totalViews,
|
||||
@JsonKey(name: "total_comments") required final int totalComments,
|
||||
@JsonKey(name: "is_favorite") required final bool isFavorite,
|
||||
@JsonKey(name: "min_price_of_options")
|
||||
required final double minPriceOfOptions,
|
||||
@JsonKey(name: "max_price_of_options")
|
||||
required final double maxPriceOfOptions,
|
||||
@JsonKey(name: "was_liked_by_me") required final bool wasLikedByMe}) =
|
||||
_$PlanModelImpl;
|
||||
|
||||
factory _PlanModel.fromJson(Map<String, dynamic> json) =
|
||||
_$PlanModelImpl.fromJson;
|
||||
@@ -950,6 +952,7 @@ abstract class _PlanModel implements PlanModel {
|
||||
@JsonKey(name: "max_price_of_options")
|
||||
double get maxPriceOfOptions;
|
||||
@override
|
||||
@JsonKey(name: "was_liked_by_me")
|
||||
bool get wasLikedByMe;
|
||||
|
||||
/// Create a copy of PlanModel
|
||||
|
||||
@@ -54,7 +54,7 @@ _$PlanModelImpl _$$PlanModelImplFromJson(Map<String, dynamic> json) =>
|
||||
isFavorite: json['is_favorite'] as bool,
|
||||
minPriceOfOptions: (json['min_price_of_options'] as num).toDouble(),
|
||||
maxPriceOfOptions: (json['max_price_of_options'] as num).toDouble(),
|
||||
wasLikedByMe: json['wasLikedByMe'] as bool? ?? false,
|
||||
wasLikedByMe: json['was_liked_by_me'] as bool,
|
||||
);
|
||||
|
||||
Map<String, dynamic> _$$PlanModelImplToJson(_$PlanModelImpl instance) =>
|
||||
@@ -78,7 +78,7 @@ Map<String, dynamic> _$$PlanModelImplToJson(_$PlanModelImpl instance) =>
|
||||
'is_favorite': instance.isFavorite,
|
||||
'min_price_of_options': instance.minPriceOfOptions,
|
||||
'max_price_of_options': instance.maxPriceOfOptions,
|
||||
'wasLikedByMe': instance.wasLikedByMe,
|
||||
'was_liked_by_me': instance.wasLikedByMe,
|
||||
};
|
||||
|
||||
_$PacketOptionsImpl _$$PacketOptionsImplFromJson(Map<String, dynamic> json) =>
|
||||
|
||||
Reference in New Issue
Block a user