CreateNotificationSchemeDetails.fromJson constructor

CreateNotificationSchemeDetails.fromJson(
  1. Map<String, Object?> json
)

Implementation

factory CreateNotificationSchemeDetails.fromJson(Map<String, Object?> json) {
  return CreateNotificationSchemeDetails(
    description: json[r'description'] as String?,
    name: json[r'name'] as String? ?? '',
    notificationSchemeEvents:
        (json[r'notificationSchemeEvents'] as List<Object?>?)
                ?.map((i) => NotificationSchemeEventDetails.fromJson(
                    i as Map<String, Object?>? ?? const {}))
                .toList() ??
            [],
  );
}