CustomerInvoiceSettings.fromJson constructor
CustomerInvoiceSettings.fromJson(
- Object? json
Implementation
factory CustomerInvoiceSettings.fromJson(Object? json) {
final map = (json as Map).cast<String, Object?>();
return CustomerInvoiceSettings(
customFields: map['custom_fields'] == null
? null
: (map['custom_fields'] as List<Object?>)
.map((el) => InvoiceSettingCustomField.fromJson(el))
.toList(),
defaultPaymentMethod: map['default_payment_method'] == null
? null
: (map['default_payment_method'] as String),
footer: map['footer'] == null ? null : (map['footer'] as String),
renderingOptions: map['rendering_options'] == null
? null
: SessionRenderingOptions.fromJson(map['rendering_options']),
);
}