Introduce own Numeric type and revert to stdlib from pgx

This commit is contained in:
2021-12-02 21:29:44 +00:00
parent 6f8a94ff5d
commit 4646356b2d
16 changed files with 136 additions and 57 deletions

View File

@ -9,7 +9,7 @@ import (
)
type AccountData struct {
Accounts []postgres.GetAccountsRow
Accounts []postgres.GetAccountsWithBalanceRow
}
func (h *Handler) accounts(c *gin.Context) {
@ -20,7 +20,7 @@ func (h *Handler) accounts(c *gin.Context) {
return
}
accounts, err := h.Service.DB.GetAccounts(c.Request.Context(), budgetUUID)
accounts, err := h.Service.DB.GetAccountsWithBalance(c.Request.Context(), budgetUUID)
if err != nil {
c.AbortWithError(http.StatusInternalServerError, err)
return