Price.fromJson constructor

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

Implementation

factory Price.fromJson(Map<String, Object?> json) => Price(
      active: json["active"] as bool,
      id: json["id"] == null ? null : json["id"] as String,
      label: json["label"] == null ? null : json["label"] as String,
      nominal: inttegro_money.Amount.fromJson(
        (json["nominal"] as Map).cast<String, Object?>(),
      ),
      original: json["original"] == null
          ? null
          : OriginalPrice.fromJson(
              (json["original"] as Map).cast<String, Object?>(),
            ),
    );