From 4e67987110fd6d1a6990ab55611089ebac89c844 Mon Sep 17 00:00:00 2001 From: shanj <18996038927@163.com> Date: Sat, 4 Nov 2023 10:52:34 +0800 Subject: [PATCH] 1 --- SiNan.API/Controllers/GOIController.cs | 2 +- SiNan.Business/GOIBusiness.cs | 7 +++++-- SiNan.Model/Dto/Request/GOI/QueryProductGOIRequest.cs | 3 +++ 3 files changed, 9 insertions(+), 3 deletions(-) diff --git a/SiNan.API/Controllers/GOIController.cs b/SiNan.API/Controllers/GOIController.cs index d95f9fa..35423f2 100644 --- a/SiNan.API/Controllers/GOIController.cs +++ b/SiNan.API/Controllers/GOIController.cs @@ -14,7 +14,7 @@ namespace SiNan.API.Controllers } /// - /// 查询产品综合GOI + /// 产品维度分析-查询产品综合GOI /// /// /// diff --git a/SiNan.Business/GOIBusiness.cs b/SiNan.Business/GOIBusiness.cs index 5660887..223dbd7 100644 --- a/SiNan.Business/GOIBusiness.cs +++ b/SiNan.Business/GOIBusiness.cs @@ -299,14 +299,17 @@ namespace SiNan.Business if (string.IsNullOrEmpty(request.Spu) && string.IsNullOrEmpty(request.Sku)) throw new BusinessException("不能同时缺少spu和sku条件"); - var skuIdList = new List(); + List skuIdList = null; if (!string.IsNullOrEmpty(request.Sku)) { request.Spu = string.Empty; - skuIdList.Add(request.Sku); + skuIdList = new List() { request.Sku }; } if (!string.IsNullOrEmpty(request.Spu)) + { skuIdList = fsql.Select().Where(ps => ps.ProductId == request.Spu).ToList(ps => ps.Id); + } + List list = new List(); diff --git a/SiNan.Model/Dto/Request/GOI/QueryProductGOIRequest.cs b/SiNan.Model/Dto/Request/GOI/QueryProductGOIRequest.cs index 2cdea58..02a009a 100644 --- a/SiNan.Model/Dto/Request/GOI/QueryProductGOIRequest.cs +++ b/SiNan.Model/Dto/Request/GOI/QueryProductGOIRequest.cs @@ -25,6 +25,9 @@ /// public int PageIndex { get; set; } + /// + /// 最大每页5条 + /// public int PageSize { get; set; } public long ShopId { get; set; }