From 1924bfca2439829253df3598481034e5c586e3e2 Mon Sep 17 00:00:00 2001 From: Vidhu Kant Sharma Date: Mon, 9 Oct 2023 21:07:20 +0530 Subject: added route to add items to invoice --- item/item.go | 21 ++++++++++----------- 1 file changed, 10 insertions(+), 11 deletions(-) (limited to 'item/item.go') diff --git a/item/item.go b/item/item.go index 02e568e..3f911fa 100644 --- a/item/item.go +++ b/item/item.go @@ -38,20 +38,19 @@ type Brand struct { } type Item struct { - UserID uint `json:"-"` - User user.User `json:"-"` - BrandID uint - Brand Brand - UnitOfMeasure string // TODO: probably has to be a custom type - HasDecimalQuantity bool - Name string - Description string - HSN string - UnitPrice string // float - GSTPercentage string // float + Name string + Description string + HSN string + UnitOfMeasure string // TODO: probably has to be a custom type + UnitPrice string // float + GSTPercentage string // float } type SavedItem struct { gorm.Model Item + BrandID uint + Brand Brand + UserID uint `json:"-"` + User user.User `json:"-"` } -- cgit v1.2.3