idempotency key delivery fix
This commit is contained in:
@@ -1,3 +1,4 @@
|
||||
import 'package:pshared/api/responses/payment/quotation.dart';
|
||||
import 'package:pshared/models/payment/fees/line.dart';
|
||||
import 'package:pshared/models/payment/fx/quote.dart';
|
||||
import 'package:pshared/models/payment/money.dart';
|
||||
@@ -23,3 +24,29 @@ class PaymentQuote {
|
||||
required this.fxQuote,
|
||||
});
|
||||
}
|
||||
|
||||
class PaymentQuoteX extends PaymentQuote {
|
||||
final String idempotencyKey;
|
||||
|
||||
const PaymentQuoteX({
|
||||
required super.quoteRef,
|
||||
required super.debitAmount,
|
||||
required super.expectedSettlementAmount,
|
||||
required super.expectedFeeTotal,
|
||||
required super.feeLines,
|
||||
required super.networkFee,
|
||||
required super.fxQuote,
|
||||
required this.idempotencyKey,
|
||||
});
|
||||
|
||||
factory PaymentQuoteX.build({required PaymentQuote quote, required String idempotencyKey}) => PaymentQuoteX(
|
||||
quoteRef: quote.quoteRef,
|
||||
debitAmount: quote.debitAmount,
|
||||
expectedSettlementAmount: quote.expectedSettlementAmount,
|
||||
expectedFeeTotal: quote.expectedFeeTotal,
|
||||
feeLines: quote.feeLines,
|
||||
networkFee: quote.networkFee,
|
||||
fxQuote: quote.fxQuote,
|
||||
idempotencyKey: idempotencyKey,
|
||||
);
|
||||
}
|
||||
|
||||
@@ -4,6 +4,7 @@ import 'package:pshared/models/payment/quote_aggregate.dart';
|
||||
|
||||
class PaymentQuotes {
|
||||
final String quoteRef;
|
||||
final String idempotencyKey;
|
||||
final PaymentQuoteAggregate? aggregate;
|
||||
final List<PaymentQuote>? quotes;
|
||||
|
||||
@@ -11,5 +12,6 @@ class PaymentQuotes {
|
||||
required this.quoteRef,
|
||||
required this.aggregate,
|
||||
required this.quotes,
|
||||
required this.idempotencyKey,
|
||||
});
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user