01a0672f - feat(history): label plain REALU transfers as received/sent - #965
01a0672f - feat(history): label plain REALU transfers as received/sent#965Blume1977 wants to merge 8 commits into
Conversation
Incoming token transfers from a foreign wallet showed up as 'Kauf' in the transaction list, because the row widgets label purely by direction (customer report via RealUnit, 02.09.2026). Brokerbot purchases carry no DFX transaction, so the app cannot tell them apart on its own. The API now classifies every history transfer (backend#5353): purchase and sale for Brokerbot counterparties, transferIn/transferOut for plain token movements. The app stores that category (new transactions.category column, schema v3) and resolves the row title through a shared helper: DFX-backed transactions keep the direction-based buy/sell labels, categorized plain transfers render as received/sent, and rows without a category (legacy data, older API) keep the previous direction labels, so backend and app can roll out independently. Already-synced entries pick up their category on the next sync via the existing update path.
Widget tests now assert the concrete received/sent/buy/sell strings from the localization delegate instead of relative inequality.
|
EN: DE: |
Row titles now follow the theme instead of a hardcoded TextStyle, and the language files end with a newline.
A non-string category on the wire no longer throws in fromJson, so one bad event cannot abort the whole history sync.
Match the DTO majority convention. Drop the extra is-String guard and its type-mismatch test.
|
EN: DE: DetailsReview passes: (1) i18n-pinned titles; (2) Theme textStyle; (3) optional category parsed with Open comments: none unresolved (one earlier summary comment from this work, no review threads). |
Pin the legacy inbound-as-Kauf fallback and the API-category titles (purchase, received, sent, sale) as visual regression screens.
|
EN: DE: DetailsBranch |
|
Closed in favour of a baseline-only PR first (inbound still labelled Kauf). Reopen/rebase this fix after that merge. |
EN: Pins the current history titles: inbound REALU from an external wallet is labelled Kauf. A follow-up PR will change the same screenshot to Empfangen. DE: Hält die heutigen History-Titel fest: eingehende REALU von einer fremden Wallet heissen Kauf. Ein Folge-PR ändert denselben Screenshot zu Empfangen. <details> <summary>Details</summary> No production-code change. One golden (`transaction_history_transfer_labels`) with four rows (100 in, 10 in, 10 out, 20 out). PNGs come from `golden-regenerate.yaml` on the self-hosted runner — not generated locally. The parked fix is #965 / `feat/history-transfer-labels`. After this merge it will be rebased so GitHub shows the pixel before/after on this file. </details> --------- Co-authored-by: TaprootFreakAI <315477232+TaprootFreakAI@users.noreply.github.com> Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
|
Head is still the fork SHA; the rebased fix is on origin/feat/history-transfer-labels and continues in a new PR. |
#969) EN: Labels inbound REALU from an external wallet as Empfangen instead of Kauf, using the API category. The history screenshot diffs against the baseline from #967. DE: Beschriftet eingehende REALU von einer fremden Wallet als Empfangen statt Kauf, anhand der API-Kategorie. Der History-Screenshot diffed gegen die Baseline aus #967. <details> <summary>Details</summary> Same four rows as #967. The shared golden `transaction_history_transfer_labels` changes +10 from Kauf to Empfangen and −10 from Verkauf to Gesendet. Brokerbot rows stay Kauf/Verkauf. Follows closed #965 (fork head could not be force-pushed after the rebase). </details> --------- Co-authored-by: Blume1977 <jana.ruettimann@dfx.swiss> Co-authored-by: TaprootFreakAI <315477232+TaprootFreakAI@users.noreply.github.com> Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
EN:
Labels inbound REALU from an external wallet as Empfangen instead of Kauf, using the API category. The history screenshot diffs against the baseline from #967.
DE:
Beschriftet eingehende REALU von einer fremden Wallet als Empfangen statt Kauf, anhand der API-Kategorie. Der History-Screenshot diffed gegen die Baseline aus #967.
Details
Same four rows as #967. The shared golden
transaction_history_transfer_labelschanges +10 from Kauf to Empfangen and −10 from Verkauf to Gesendet. Brokerbot rows stay Kauf/Verkauf.