// GENERATED CODE - DO NOT MODIFY BY HAND

part of 'notification_response_model.dart';

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

_NotificationResponseModel _$NotificationResponseModelFromJson(
  Map<String, dynamic> json,
) => _NotificationResponseModel(
  success: json['success'] as bool?,
  message: json['message'] as String?,
  data:
      (json['data'] as List<dynamic>?)
          ?.map((e) => NotificationItem.fromJson(e as Map<String, dynamic>))
          .toList(),
  error:
      json['error'] == null
          ? null
          : ErrorModel.fromJson(json['error'] as Map<String, dynamic>),
  meta:
      json['meta'] == null
          ? null
          : Meta.fromJson(json['meta'] as Map<String, dynamic>),
);

Map<String, dynamic> _$NotificationResponseModelToJson(
  _NotificationResponseModel instance,
) => <String, dynamic>{
  'success': instance.success,
  'message': instance.message,
  'data': instance.data,
  'error': instance.error,
  'meta': instance.meta,
};

_NotificationItem _$NotificationItemFromJson(Map<String, dynamic> json) =>
    _NotificationItem(
      id: json['id'] as String?,
      userId: json['user_id'] as String?,
      recipient:
          json['recipient'] == null
              ? null
              : Recipient.fromJson(json['recipient'] as Map<String, dynamic>),
      title: json['title'] as String?,
      message: json['message'] as String?,
      link: json['link'] as String?,
      image: json['image'] as String?,
      priority: json['priority'] as String?,
      type: json['type'] as String?,
      eventType: json['event_type'] as String?,
      status: json['status'] as String?,
      methods: json['methods'] as Map<String, dynamic>?,
      metadata: json['metadata'] as Map<String, dynamic>?,
      scheduleAt: (json['schedule_at'] as num?)?.toInt(),
      createdAt: (json['created_at'] as num?)?.toInt(),
      updatedAt: (json['updated_at'] as num?)?.toInt(),
      seen: json['seen'] as bool?,
      seenAt: (json['seen_at'] as num?)?.toInt(),
      isScheduled: json['is_scheduled'] as bool?,
      scheduledAt: (json['scheduled_at'] as num?)?.toInt(),
    );

Map<String, dynamic> _$NotificationItemToJson(_NotificationItem instance) =>
    <String, dynamic>{
      'id': instance.id,
      'user_id': instance.userId,
      'recipient': instance.recipient,
      'title': instance.title,
      'message': instance.message,
      'link': instance.link,
      'image': instance.image,
      'priority': instance.priority,
      'type': instance.type,
      'event_type': instance.eventType,
      'status': instance.status,
      'methods': instance.methods,
      'metadata': instance.metadata,
      'schedule_at': instance.scheduleAt,
      'created_at': instance.createdAt,
      'updated_at': instance.updatedAt,
      'seen': instance.seen,
      'seen_at': instance.seenAt,
      'is_scheduled': instance.isScheduled,
      'scheduled_at': instance.scheduledAt,
    };
