diff options
author | Sebastian <sebasjm@gmail.com> | 2022-05-29 01:23:15 -0300 |
---|---|---|
committer | Sebastian <sebasjm@gmail.com> | 2022-05-29 01:23:21 -0300 |
commit | 029340469ac661bab1450b1ff4dcc6e717780e5b (patch) | |
tree | 0e4495cbc332ed5ed2059b8ba12de9be6c2dc98e /packages/taler-util | |
parent | ced08c502fc36ef90bb34fafcb1e2cbfe82f1280 (diff) |
show refund info in purchase
notify refund pending with accept button on the purchase details
better payto box
Diffstat (limited to 'packages/taler-util')
-rw-r--r-- | packages/taler-util/src/transactionsTypes.ts | 12 | ||||
-rw-r--r-- | packages/taler-util/src/walletTypes.ts | 9 |
2 files changed, 21 insertions, 0 deletions
diff --git a/packages/taler-util/src/transactionsTypes.ts b/packages/taler-util/src/transactionsTypes.ts index dcaa56675..f7383f902 100644 --- a/packages/taler-util/src/transactionsTypes.ts +++ b/packages/taler-util/src/transactionsTypes.ts @@ -244,6 +244,11 @@ export interface TransactionPayment extends TransactionCommon { * Amount pending to be picked up */ refundPending: AmountString | undefined; + + /** + * Reference to applied refunds + */ + refunds: RefundInfoShort[]; } export interface OrderShortInfo { @@ -305,6 +310,13 @@ export interface OrderShortInfo { fulfillmentMessage_i18n?: InternationalizedString; } +export interface RefundInfoShort { + transactionId: string, + timestamp: TalerProtocolTimestamp, + amountEffective: AmountString, + amountRaw: AmountString, +} + export interface TransactionRefund extends TransactionCommon { type: TransactionType.Refund; diff --git a/packages/taler-util/src/walletTypes.ts b/packages/taler-util/src/walletTypes.ts index fa884c414..00a489861 100644 --- a/packages/taler-util/src/walletTypes.ts +++ b/packages/taler-util/src/walletTypes.ts @@ -799,6 +799,15 @@ export const codecForApplyRefundRequest = (): Codec<ApplyRefundRequest> => .property("talerRefundUri", codecForString()) .build("ApplyRefundRequest"); +export interface ApplyRefundFromPurchaseIdRequest { + purchaseId: string; +} + +export const codecForApplyRefundFromPurchaseIdRequest = (): Codec<ApplyRefundFromPurchaseIdRequest> => + buildCodecForObject<ApplyRefundFromPurchaseIdRequest>() + .property("purchaseId", codecForString()) + .build("ApplyRefundFromPurchaseIdRequest"); + export interface GetWithdrawalDetailsForUriRequest { talerWithdrawUri: string; restrictAge?: number; |