From 0947a4fdf51a93223c63635186a019f9a5af1923 Mon Sep 17 00:00:00 2001 From: qowevisa Date: Mon, 12 Aug 2024 18:31:07 +0300 Subject: [PATCH] Add DbDebt to types --- types/types.go | 14 ++++++++++++++ 1 file changed, 14 insertions(+) diff --git a/types/types.go b/types/types.go index d7a058d..38891b7 100644 --- a/types/types.go +++ b/types/types.go @@ -1,5 +1,7 @@ package types +import "time" + // User struct for requests type User struct { Username string `json:"username" binding:"required" example:"testUser"` @@ -36,3 +38,15 @@ type DbCategory struct { ParentID uint `json:"parent_id" example:"0"` UserID uint `json:"user_id" example:"1"` } + +type DbDebt struct { + ID uint `json:"id" example:"1"` + CardID uint `json:"card_id" example:"1"` + Comment string `json:"comment" example:"pizza"` + Value uint64 `json:"value" example:"20000"` + IOwe bool `json:"i_owe" example:"true"` + Date time.Time `json:"date" example:"29/11/2001 12:00"` + DateEnd time.Time `json:"date_end" example:"29/12/2001 12:00"` + Finished bool `json:"finished" example:"false"` + UserID uint `json:"user_id" example:"1"` +}