Price.fromJson constructor

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

Implementation

factory Price.fromJson(Map<String, dynamic> json) => Price(
      currency: (json['currency'] ?? "") as String,
      total: (json['total'] ?? "") as String,
      fees: json['fees'] != null
          ? List<Fees>.from((json['fees'] as List).map(
              (e) => Fees.fromJson(e as Map<String, dynamic>),
            )).toList()
          : <Fees>[],
      grandTotal: (json['grandTotal'] ?? '') as String,
      base: (json['base'] ?? "") as String,
    );