// GENERATED CODE - DO NOT MODIFY BY HAND

part of 'tenant_model.dart';

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

TenantModel _$TenantModelFromJson(Map<String, dynamic> json) => TenantModel(
  serverId: json['id'] as String,
  businessCode: json['business_code'] as String,
  businessName: json['business_name'] as String,
  businessEmail: json['business_email'] as String?,
  businessPhone: json['business_phone'] as String?,
  businessType: json['business_type'] as String?,
  serverLogoUrl: json['server_logo_url'] as String?,
  subdomain: json['subdomain'] as String?,
  onlineStoreName: json['online_store_name'] as String?,
  onlineOpenTime: json['online_open_time'] as String?,
  onlineCloseTime: json['online_close_time'] as String?,
  isCloseService: json['is_close_service'] as bool?,
  preparationTimeMinutes: (json['preparation_time_minutes'] as num?)?.toInt(),
  orderIntervalMinutes: (json['order_interval_minutes'] as num?)?.toInt(),
  allowCod: json['allow_cod'] as bool?,
  maxDeliveryRadiusKm: (json['max_delivery_radius_km'] as num?)?.toDouble(),
  deliveryFeeType: json['delivery_fee_type'] as String?,
  deliveryFlatFee: (json['delivery_flat_fee'] as num?)?.toDouble(),
  deliveryFeePerKm: (json['delivery_fee_per_km'] as num?)?.toDouble(),
  deliveryBaseFee: (json['delivery_base_fee'] as num?)?.toDouble(),
  reviewDisplayType: json['review_display_type'] as String?,
  reviewDisplayPolicy: json['review_display_policy'] as String?,
  subscriptionLevel: json['subscription_level'] as String?,
  limitOutlet: (json['limit_outlet'] as num?)?.toInt(),
  subscriptionExpiresAt: json['subscription_expires_at'] == null
      ? null
      : DateTime.parse(json['subscription_expires_at'] as String),
  createdAt: DateTime.parse(json['created_at'] as String),
  updatedAt: DateTime.parse(json['updated_at'] as String),
);

Map<String, dynamic> _$TenantModelToJson(
  TenantModel instance,
) => <String, dynamic>{
  'id': instance.serverId,
  'business_code': instance.businessCode,
  'business_name': instance.businessName,
  'business_email': instance.businessEmail,
  'business_phone': instance.businessPhone,
  'business_type': instance.businessType,
  'server_logo_url': instance.serverLogoUrl,
  'subdomain': instance.subdomain,
  'online_store_name': instance.onlineStoreName,
  'online_open_time': instance.onlineOpenTime,
  'online_close_time': instance.onlineCloseTime,
  'is_close_service': instance.isCloseService,
  'preparation_time_minutes': instance.preparationTimeMinutes,
  'order_interval_minutes': instance.orderIntervalMinutes,
  'allow_cod': instance.allowCod,
  'max_delivery_radius_km': instance.maxDeliveryRadiusKm,
  'delivery_fee_type': instance.deliveryFeeType,
  'delivery_flat_fee': instance.deliveryFlatFee,
  'delivery_fee_per_km': instance.deliveryFeePerKm,
  'delivery_base_fee': instance.deliveryBaseFee,
  'review_display_type': instance.reviewDisplayType,
  'review_display_policy': instance.reviewDisplayPolicy,
  'subscription_level': instance.subscriptionLevel,
  'limit_outlet': instance.limitOutlet,
  'subscription_expires_at': instance.subscriptionExpiresAt?.toIso8601String(),
  'created_at': instance.createdAt.toIso8601String(),
  'updated_at': instance.updatedAt.toIso8601String(),
};
