SubscriptionScheduleAddInvoiceItemsItem.fromJson constructor
SubscriptionScheduleAddInvoiceItemsItem.fromJson(
- Object? json
Implementation
factory SubscriptionScheduleAddInvoiceItemsItem.fromJson(Object? json) {
final map = (json as Map).cast<String, Object?>();
return SubscriptionScheduleAddInvoiceItemsItem(
price: map['price'] == null ? null : (map['price'] as String),
priceData: map['price_data'] == null
? null
: InvoiceItemPriceData.fromJson(map['price_data']),
quantity:
map['quantity'] == null ? null : (map['quantity'] as num).toInt(),
taxRates: map['tax_rates'] == null
? null
: (map['tax_rates'] as List<Object?>)
.map((el) => (el as String))
.toList(),
);
}