[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[GNUnet-SVN] [taler-wallet-webex] branch master updated: show earliest d
From: |
gnunet |
Subject: |
[GNUnet-SVN] [taler-wallet-webex] branch master updated: show earliest deposit expiration when withdrawing |
Date: |
Fri, 28 Apr 2017 23:42:16 +0200 |
This is an automated email from the git hooks/post-receive script.
dold pushed a commit to branch master
in repository wallet-webex.
The following commit(s) were added to refs/heads/master by this push:
new 89067a1 show earliest deposit expiration when withdrawing
89067a1 is described below
commit 89067a16dd9958d2d868090ef1d14a6512a0e68b
Author: Florian Dold <address@hidden>
AuthorDate: Fri Apr 28 23:42:14 2017 +0200
show earliest deposit expiration when withdrawing
---
src/pages/confirm-create-reserve.tsx | 3 ++-
src/types.ts | 1 +
src/wallet.ts | 9 +++++++++
3 files changed, 12 insertions(+), 1 deletion(-)
diff --git a/src/pages/confirm-create-reserve.tsx
b/src/pages/confirm-create-reserve.tsx
index 6b618c2..2f341bb 100644
--- a/src/pages/confirm-create-reserve.tsx
+++ b/src/pages/confirm-create-reserve.tsx
@@ -194,6 +194,7 @@ function renderReserveCreationDetails(rci:
ReserveCreationInfo|null) {
<h3>Overview</h3>
<p>{i18n.str`Withdrawal fees: ${withdrawFeeStr}`}</p>
<p>{i18n.str`Rounding loss: ${overheadStr}`}</p>
+ <p>{i18n.str`Earliest expiration (for deposit):
${moment.unix(rci.earliestDepositExpiration).fromNow()}`}</p>
<h3>Coin Fees</h3>
<table className="pure-table">
<thead>
@@ -439,7 +440,7 @@ class ExchangeSelection extends
ImplicitStateComponent<ExchangeSelectionProps> {
{i18n.str`Change Exchange Provider`}
</button>
<br/>
- <Collapsible initiallyCollapsed={true} title="Fee Details">
+ <Collapsible initiallyCollapsed={true} title="Fee and Spending
Details">
{renderReserveCreationDetails(this.reserveCreationInfo())}
</Collapsible>
<Collapsible initiallyCollapsed={true} title="Auditor Details">
diff --git a/src/types.ts b/src/types.ts
index 4707edd..e357dfa 100644
--- a/src/types.ts
+++ b/src/types.ts
@@ -253,6 +253,7 @@ export interface ReserveCreationInfo {
wireFees: ExchangeWireFeesRecord;
isAudited: boolean;
isTrusted: boolean;
+ earliestDepositExpiration: number;
}
diff --git a/src/wallet.ts b/src/wallet.ts
index bc3cd59..4c44b5d 100644
--- a/src/wallet.ts
+++ b/src/wallet.ts
@@ -1377,6 +1377,14 @@ export class Wallet {
let {isTrusted, isAudited} = await this.getExchangeTrust(exchangeInfo);
+ let earliestDepositExpiration = Infinity;;
+ for (let denom of selectedDenoms) {
+ let expireDeposit = getTalerStampSec(denom.stampExpireDeposit)!;
+ if (expireDeposit < earliestDepositExpiration) {
+ earliestDepositExpiration = expireDeposit;
+ }
+ }
+
let ret: ReserveCreationInfo = {
exchangeInfo,
selectedDenoms,
@@ -1385,6 +1393,7 @@ export class Wallet {
isAudited,
isTrusted,
withdrawFee: acc,
+ earliestDepositExpiration,
overhead: Amounts.sub(amount, actualCoinCost).amount,
};
return ret;
--
To stop receiving notification emails like this one, please contact
address@hidden
[Prev in Thread] |
Current Thread |
[Next in Thread] |
- [GNUnet-SVN] [taler-wallet-webex] branch master updated: show earliest deposit expiration when withdrawing,
gnunet <=