// GENERATED CODE - DO NOT MODIFY BY HAND

part of 'equipment_dto.dart';

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

_$EquipmentDtoImpl _$$EquipmentDtoImplFromJson(Map<String, dynamic> json) =>
    _$EquipmentDtoImpl(
      id: (json['id'] as num).toInt(),
      serialNumber: json['serial_number'] as String,
      name: json['name'] as String,
      category: json['category'] as String?,
      manufacturer: json['manufacturer'] as String?,
      model: json['model'] as String?,
      status: json['status'] as String,
      companyId: (json['company_id'] as num).toInt(),
      companyName: json['company_name'] as String?,
      warehouseLocationId: (json['warehouse_location_id'] as num?)?.toInt(),
      warehouseName: json['warehouse_name'] as String?,
      purchaseDate: json['purchase_date'] as String?,
      purchasePrice: (json['purchase_price'] as num?)?.toDouble(),
      currentValue: (json['current_value'] as num?)?.toDouble(),
      warrantyExpiry: json['warranty_expiry'] as String?,
      lastMaintenanceDate: json['last_maintenance_date'] as String?,
      nextMaintenanceDate: json['next_maintenance_date'] as String?,
      specifications: json['specifications'] as Map<String, dynamic>?,
      notes: json['notes'] as String?,
      createdAt: json['created_at'] == null
          ? null
          : DateTime.parse(json['created_at'] as String),
      updatedAt: json['updated_at'] == null
          ? null
          : DateTime.parse(json['updated_at'] as String),
    );

Map<String, dynamic> _$$EquipmentDtoImplToJson(_$EquipmentDtoImpl instance) =>
    <String, dynamic>{
      'id': instance.id,
      'serial_number': instance.serialNumber,
      'name': instance.name,
      'category': instance.category,
      'manufacturer': instance.manufacturer,
      'model': instance.model,
      'status': instance.status,
      'company_id': instance.companyId,
      'company_name': instance.companyName,
      'warehouse_location_id': instance.warehouseLocationId,
      'warehouse_name': instance.warehouseName,
      'purchase_date': instance.purchaseDate,
      'purchase_price': instance.purchasePrice,
      'current_value': instance.currentValue,
      'warranty_expiry': instance.warrantyExpiry,
      'last_maintenance_date': instance.lastMaintenanceDate,
      'next_maintenance_date': instance.nextMaintenanceDate,
      'specifications': instance.specifications,
      'notes': instance.notes,
      'created_at': instance.createdAt?.toIso8601String(),
      'updated_at': instance.updatedAt?.toIso8601String(),
    };
