Payment.fromMap constructor
Implementation
factory Payment.fromMap(Map<String, dynamic> map) {
return Payment(
map['transaction_uuid'] as String,
map['created_at'] as String,
map['updated_at'] as String,
map['status_code'] as int,
map['currency'] as String,
map['status_denom'] as String,
map['description'] as String,
map['merchant_op_id'] as String,
double.parse(map['amount']["total"]),
List<Product>.from((map['items'] as List<dynamic>).map<Product>((x) => Product.fromMap(x as Map<String,dynamic>),),),
List<Link>.from((map['links'] as List<dynamic>).map<Link>((x) => Link.fromMap(x as Map<String,dynamic>),),),
);
}