Update order system with new gRPC services and wallet integration
This commit is contained in:
@@ -3,7 +3,15 @@ using FrontOffice.BFF.Products.Protobuf.Protos.Products;
|
||||
|
||||
namespace FrontOffice.Main.Utilities;
|
||||
|
||||
public record Product(long Id, string Title, string Description, string ImageUrl, long Price);
|
||||
public record Product(
|
||||
long Id,
|
||||
string Title,
|
||||
string Description,
|
||||
string ImageUrl,
|
||||
long Price,
|
||||
int Discount = 0,
|
||||
int Rate = 0,
|
||||
int RemainingCount = 0);
|
||||
|
||||
public class ProductService
|
||||
{
|
||||
@@ -81,7 +89,10 @@ public class ProductService
|
||||
Title: m.Title ?? string.Empty,
|
||||
Description: m.Description ?? string.Empty,
|
||||
ImageUrl: string.IsNullOrWhiteSpace(m.ImagePath) ? string.Empty : UrlUtility.DownloadUrl + m.ImagePath,
|
||||
Price: m.Price
|
||||
Price: m.Price,
|
||||
Discount: m.Discount,
|
||||
Rate: m.Rate,
|
||||
RemainingCount: m.RemainingCount
|
||||
);
|
||||
_cache[p.Id] = p;
|
||||
list.Add(p);
|
||||
|
||||
Reference in New Issue
Block a user