From 0f7b1b210a20e916ee001a3790d902d3dc730e97 Mon Sep 17 00:00:00 2001 From: qowevisa Date: Sun, 24 Nov 2024 00:27:34 +0200 Subject: [PATCH] Add FromValue and ToValue to show for different currencies and some UI fields for easy front --- types/types.go | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/types/types.go b/types/types.go index f1fcdc1..e794c8d 100644 --- a/types/types.go +++ b/types/types.go @@ -89,7 +89,14 @@ type DbTransfer struct { FromCardID uint `json:"from_card_id" example:"1"` ToCardID uint `json:"to_card_id" example:"1"` Value uint64 `json:"value" example:"20000"` + FromValue uint64 `json:"from_value" example:"20000"` + ToValue uint64 `json:"to_value" example:"20000"` Date time.Time `json:"date" example:"29/11/2001 12:00"` + // Purely UI things + ShowValue string `json:"show_value" example:"10.35$"` + HaveDifferentCurrencies bool `json:"have_diff_currs" example:"false"` + FromCard DbCard `json:"from_card"` + ToCard DbCard `json:"to_card"` } type DbItem struct {