TaxProductResourceLineItemTaxBreakdown.fromJson constructor
TaxProductResourceLineItemTaxBreakdown.fromJson(
- Object? json
Implementation
factory TaxProductResourceLineItemTaxBreakdown.fromJson(Object? json) {
final map = (json as Map).cast<String, Object?>();
return TaxProductResourceLineItemTaxBreakdown(
amount: (map['amount'] as num).toInt(),
jurisdiction:
TaxProductResourceJurisdiction.fromJson(map['jurisdiction']),
sourcing: TaxProductResourceLineItemTaxBreakdownSourcing.fromJson(
map['sourcing']),
taxRateDetails: map['tax_rate_details'] == null
? null
: TaxProductResourceLineItemTaxBreakdownTaxRateDetails.fromJson(
map['tax_rate_details']),
taxabilityReason:
TaxProductResourceLineItemTaxBreakdownTaxabilityReason.fromJson(
map['taxability_reason']),
taxableAmount: (map['taxable_amount'] as num).toInt(),
);
}