Skip to content
Snippets Groups Projects
Unverified Commit 5f358b98 authored by Réthelyi Bálint's avatar Réthelyi Bálint :no_mouth:
Browse files

Add ProductInPult and BoughtInPult structs in api module

The new structures ProductInPult and BoughtInPult in api/model.go file have been added. These implementations are designed to facilitate the handling of product and purchasing data. Adding these types will help to establish a structure for the data flowing in and out of the API endpoints, and thereby improve the general utility and manageability of our system.
parent 961fe8ed
Branches
Tags 1.4.19
1 merge request!25Add API endpoints and middleware for user and product manipulation
package api
import (
"git.sch.bme.hu/disappointment-industries/becskasszasch/db"
"time"
)
type ProductInPult struct {
Product *db.Product `json:"product"`
Amount int64 `json:"amount"`
}
type BoughtInPult struct {
User *db.User `json:"user"`
ProductsInPult []*ProductInPult `json:"productsInPult"`
Date time.Time `json:"date"`
Pultosch *db.User `json:"pultosch"`
}
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment