aboutsummaryrefslogtreecommitdiff
path: root/src/walletTypes.ts
diff options
context:
space:
mode:
authorFlorian Dold <florian.dold@gmail.com>2019-12-05 22:17:01 +0100
committerFlorian Dold <florian.dold@gmail.com>2019-12-05 22:17:01 +0100
commit8115ac660cd9d12ef69ca80fc2e4cf8eec6b1ba1 (patch)
tree1190c1e16fb620d7812b1f26b03f20ed9615e795 /src/walletTypes.ts
parentf67d7f54f9d0fed97446898942e3dfee67ee2985 (diff)
downloadwallet-core-8115ac660cd9d12ef69ca80fc2e4cf8eec6b1ba1.tar.xz
fix refunds
Diffstat (limited to 'src/walletTypes.ts')
-rw-r--r--src/walletTypes.ts14
1 files changed, 12 insertions, 2 deletions
diff --git a/src/walletTypes.ts b/src/walletTypes.ts
index d78fc8126..2413234eb 100644
--- a/src/walletTypes.ts
+++ b/src/walletTypes.ts
@@ -37,6 +37,7 @@ import {
ExchangeWireInfo,
WithdrawalSource,
RetryInfo,
+ PurchaseStatus,
} from "./dbTypes";
import { CoinPaySig, ContractTerms, PayReq } from "./talerTypes";
@@ -520,6 +521,7 @@ export const enum NotificationType {
ReserveDepleted = "reserve-depleted",
WithdrawSessionFinished = "withdraw-session-finished",
WaitingForRetry = "waiting-for-retry",
+ RefundFinished = "refund-finished",
}
export interface ProposalAcceptedNotification {
@@ -585,6 +587,10 @@ export interface WaitingForRetryNotification {
numGivingLiveness: number;
}
+export interface RefundFinishedNotification {
+ type: NotificationType.RefundFinished;
+}
+
export type WalletNotification =
| ProposalAcceptedNotification
| ProposalDownloadedNotification
@@ -599,7 +605,8 @@ export type WalletNotification =
| ReserveConfirmedNotification
| WithdrawSessionFinishedNotification
| ReserveDepletedNotification
- | WaitingForRetryNotification;
+ | WaitingForRetryNotification
+ | RefundFinishedNotification;
export interface OperationError {
type: string;
@@ -612,7 +619,7 @@ export interface PendingExchangeUpdateOperation {
stage: string;
reason: string;
exchangeBaseUrl: string;
- lastError?: OperationError;
+ lastError: OperationError | undefined;
}
export interface PendingBugOperation {
@@ -674,6 +681,9 @@ export interface PendingPayOperation {
type: "pay";
proposalId: string;
isReplay: boolean;
+ status: PurchaseStatus;
+ retryInfo: RetryInfo,
+ lastError: OperationError | undefined;
}
export interface PendingOperationInfoCommon {