From 0a885e5b7d76562a9d7c9c8f3353a53dd247eced Mon Sep 17 00:00:00 2001 From: Vidhu Kant Sharma Date: Fri, 11 Nov 2022 23:27:37 +0530 Subject: added TotalAmount field to Invoice struct --- invoice/invoice.go | 2 ++ 1 file changed, 2 insertions(+) diff --git a/invoice/invoice.go b/invoice/invoice.go index d195ea3..91b881c 100644 --- a/invoice/invoice.go +++ b/invoice/invoice.go @@ -91,6 +91,8 @@ type Invoice struct { // user can apply a discount on the whole invoice // TODO: float64 isn't the best for this DiscountPercentage float64 `bson:"DiscountPercentage" json:"DiscountPercentage"` + // helps to filter amount by amount + TotalAmount float64 `bson:"TotalAmount" json:"TotalAmount"` /* client may have multiple shipping * addresses but invoice only has one. * Empty ShippingAddress means shipping -- cgit v1.2.3