// GENERATED CODE - DO NOT MODIFY BY HAND

part of 'all_poultry.dart';

// **************************************************************************
// JsonSerializableGenerator
// **************************************************************************

_AllPoultry _$AllPoultryFromJson(Map<String, dynamic> json) => _AllPoultry(
  user: json['user'] == null
      ? null
      : User.fromJson(json['user'] as Map<String, dynamic>),
  key: json['key'] as String?,
  unitName: json['unit_name'] as String?,
  address: json['address'] == null
      ? null
      : Address.fromJson(json['address'] as Map<String, dynamic>),
  lastHatchingRemainQuantity: (json['last_hatching_remain_quantity'] as num?)
      ?.toInt(),
  provinceAllowSellFree: json['province_allow_sell_free'] as bool?,
  chainCompany: json['chain_company'] == null
      ? null
      : ChainCompany.fromJson(json['chain_company'] as Map<String, dynamic>),
);

Map<String, dynamic> _$AllPoultryToJson(_AllPoultry instance) =>
    <String, dynamic>{
      'user': instance.user,
      'key': instance.key,
      'unit_name': instance.unitName,
      'address': instance.address,
      'last_hatching_remain_quantity': instance.lastHatchingRemainQuantity,
      'province_allow_sell_free': instance.provinceAllowSellFree,
      'chain_company': instance.chainCompany,
    };

_User _$UserFromJson(Map<String, dynamic> json) => _User(
  fullname: json['fullname'] as String?,
  mobile: json['mobile'] as String?,
);

Map<String, dynamic> _$UserToJson(_User instance) => <String, dynamic>{
  'fullname': instance.fullname,
  'mobile': instance.mobile,
};

_Address _$AddressFromJson(Map<String, dynamic> json) => _Address(
  city: json['city'] == null
      ? null
      : City.fromJson(json['city'] as Map<String, dynamic>),
);

Map<String, dynamic> _$AddressToJson(_Address instance) => <String, dynamic>{
  'city': instance.city,
};

_City _$CityFromJson(Map<String, dynamic> json) =>
    _City(name: json['name'] as String?);

Map<String, dynamic> _$CityToJson(_City instance) => <String, dynamic>{
  'name': instance.name,
};

_ChainCompany _$ChainCompanyFromJson(Map<String, dynamic> json) =>
    _ChainCompany(
      chainCompany: json['chain_company'] as bool?,
      hatchingKey: json['hatching_key'] as String?,
    );

Map<String, dynamic> _$ChainCompanyToJson(_ChainCompany instance) =>
    <String, dynamic>{
      'chain_company': instance.chainCompany,
      'hatching_key': instance.hatchingKey,
    };
