From cd8f76db61f4a1ab1a8a8a4d29b2f3e863b59854 Mon Sep 17 00:00:00 2001
From: Florian Dold <florian@dold.me>
Date: Fri, 26 May 2023 12:19:32 +0200
Subject: taler-util,wallet-core: implement TalerPreciseTimestamp

Fixes #7703
---
 .../src/components/TransactionItem.tsx             | 22 +++++++++++-----------
 1 file changed, 11 insertions(+), 11 deletions(-)

(limited to 'packages/taler-wallet-webextension/src/components/TransactionItem.tsx')

diff --git a/packages/taler-wallet-webextension/src/components/TransactionItem.tsx b/packages/taler-wallet-webextension/src/components/TransactionItem.tsx
index 124729349..15669e63d 100644
--- a/packages/taler-wallet-webextension/src/components/TransactionItem.tsx
+++ b/packages/taler-wallet-webextension/src/components/TransactionItem.tsx
@@ -53,7 +53,7 @@ export function TransactionItem(props: { tx: Transaction }): VNode {
           amount={tx.amountEffective}
           debitCreditIndicator={"credit"}
           title={new URL(tx.exchangeBaseUrl).hostname}
-          timestamp={AbsoluteTime.fromTimestamp(tx.timestamp)}
+          timestamp={AbsoluteTime.fromPreciseTimestamp(tx.timestamp)}
           iconPath={"W"}
           pending={
             tx.txState.major === TransactionMajorState.Pending
@@ -76,7 +76,7 @@ export function TransactionItem(props: { tx: Transaction }): VNode {
           amount={tx.amountEffective}
           debitCreditIndicator={"credit"}
           title={new URL(tx.exchangeBaseUrl).hostname}
-          timestamp={AbsoluteTime.fromTimestamp(tx.timestamp)}
+          timestamp={AbsoluteTime.fromPreciseTimestamp(tx.timestamp)}
           iconPath={"I"}
           pending={
             tx.txState.major === TransactionMajorState.Pending
@@ -100,7 +100,7 @@ export function TransactionItem(props: { tx: Transaction }): VNode {
           debitCreditIndicator={"debit"}
           title={tx.info.merchant.name}
           subtitle={tx.info.summary}
-          timestamp={AbsoluteTime.fromTimestamp(tx.timestamp)}
+          timestamp={AbsoluteTime.fromPreciseTimestamp(tx.timestamp)}
           iconPath={"P"}
           pending={
             tx.txState.major === TransactionMajorState.Pending
@@ -121,7 +121,7 @@ export function TransactionItem(props: { tx: Transaction }): VNode {
               ? tx.paymentInfo.merchant.name
               : "--unknown merchant--"
           } //FIXME: DD37 wallet-core is not returning this value
-          timestamp={AbsoluteTime.fromTimestamp(tx.timestamp)}
+          timestamp={AbsoluteTime.fromPreciseTimestamp(tx.timestamp)}
           iconPath={"R"}
           pending={
             tx.txState.major === TransactionMajorState.Pending
@@ -137,7 +137,7 @@ export function TransactionItem(props: { tx: Transaction }): VNode {
           amount={tx.amountEffective}
           debitCreditIndicator={"credit"}
           title={new URL(tx.merchantBaseUrl).hostname}
-          timestamp={AbsoluteTime.fromTimestamp(tx.timestamp)}
+          timestamp={AbsoluteTime.fromPreciseTimestamp(tx.timestamp)}
           iconPath={"T"}
           pending={
             tx.txState.major === TransactionMajorState.Pending
@@ -153,7 +153,7 @@ export function TransactionItem(props: { tx: Transaction }): VNode {
           amount={tx.amountEffective}
           debitCreditIndicator={"credit"}
           title={"Refresh"}
-          timestamp={AbsoluteTime.fromTimestamp(tx.timestamp)}
+          timestamp={AbsoluteTime.fromPreciseTimestamp(tx.timestamp)}
           iconPath={"R"}
           pending={
             tx.txState.major === TransactionMajorState.Pending
@@ -169,7 +169,7 @@ export function TransactionItem(props: { tx: Transaction }): VNode {
           amount={tx.amountEffective}
           debitCreditIndicator={"debit"}
           title={tx.targetPaytoUri}
-          timestamp={AbsoluteTime.fromTimestamp(tx.timestamp)}
+          timestamp={AbsoluteTime.fromPreciseTimestamp(tx.timestamp)}
           iconPath={"D"}
           pending={
             tx.txState.major === TransactionMajorState.Pending
@@ -185,7 +185,7 @@ export function TransactionItem(props: { tx: Transaction }): VNode {
           amount={tx.amountEffective}
           debitCreditIndicator={"credit"}
           title={tx.info.summary || "Invoice"}
-          timestamp={AbsoluteTime.fromTimestamp(tx.timestamp)}
+          timestamp={AbsoluteTime.fromPreciseTimestamp(tx.timestamp)}
           iconPath={"I"}
           pending={
             tx.txState.major === TransactionMajorState.Pending
@@ -201,7 +201,7 @@ export function TransactionItem(props: { tx: Transaction }): VNode {
           amount={tx.amountEffective}
           debitCreditIndicator={"debit"}
           title={tx.info.summary || "Invoice"}
-          timestamp={AbsoluteTime.fromTimestamp(tx.timestamp)}
+          timestamp={AbsoluteTime.fromPreciseTimestamp(tx.timestamp)}
           iconPath={"I"}
           pending={
             tx.txState.major === TransactionMajorState.Pending
@@ -217,7 +217,7 @@ export function TransactionItem(props: { tx: Transaction }): VNode {
           amount={tx.amountEffective}
           debitCreditIndicator={"credit"}
           title={tx.info.summary || "Transfer"}
-          timestamp={AbsoluteTime.fromTimestamp(tx.timestamp)}
+          timestamp={AbsoluteTime.fromPreciseTimestamp(tx.timestamp)}
           iconPath={"T"}
           pending={
             tx.txState.major === TransactionMajorState.Pending
@@ -233,7 +233,7 @@ export function TransactionItem(props: { tx: Transaction }): VNode {
           amount={tx.amountEffective}
           debitCreditIndicator={"debit"}
           title={tx.info.summary || "Transfer"}
-          timestamp={AbsoluteTime.fromTimestamp(tx.timestamp)}
+          timestamp={AbsoluteTime.fromPreciseTimestamp(tx.timestamp)}
           iconPath={"T"}
           pending={
             tx.txState.major === TransactionMajorState.Pending
-- 
cgit v1.2.3

