From a8d21f046570eb8513ccaa537eb0b47be8137bbd Mon Sep 17 00:00:00 2001 From: Katos <7927609+katosdev@users.noreply.github.com> Date: Sat, 22 Jun 2024 15:38:27 +0100 Subject: [PATCH] Add totalprice to pagination --- backend/internal/data/repo/pagination.go | 1 + 1 file changed, 1 insertion(+) diff --git a/backend/internal/data/repo/pagination.go b/backend/internal/data/repo/pagination.go index d8878d02..5f540ee4 100644 --- a/backend/internal/data/repo/pagination.go +++ b/backend/internal/data/repo/pagination.go @@ -5,6 +5,7 @@ type PaginationResult[T any] struct { PageSize int `json:"pageSize"` Total int `json:"total"` Items []T `json:"items"` + TotalPrice float64 `json:"totalPrice"` } func calculateOffset(page, pageSize int) int {