fromJson static method

StonePaymentPayload fromJson(
  1. Map json
)

Implementation

static StonePaymentPayload fromJson(Map json) {
  return StonePaymentPayload(
    amount: json['amount'],
    transactionType: StoneTransactionType.values.firstWhere((e) => e.name == json['transaction_type']),
    installmentType: json['installment_type'] != null ? StoneInstallmentType.values.firstWhere((e) => e.name == json['installment_type']) : null,
    installmentCount: json['installment_count'],
    editableAmount: json['editable_amount'],
    orderId: json['order_id'],
  );
}