From 2177adec7bc191f161fb793663a5e5109264d5ee Mon Sep 17 00:00:00 2001 From: gdlcf88 Date: Tue, 9 Aug 2022 13:51:03 +0800 Subject: [PATCH] Fix `FlashSalePlanAppService.CreateFilteredQueryAsync` method --- .../FlashSalePlans/FlashSalePlanAppService.cs | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/plugins/FlashSales/src/EasyAbp.EShop.Plugins.FlashSales.Application/EasyAbp/EShop/Plugins/FlashSales/FlashSalePlans/FlashSalePlanAppService.cs b/plugins/FlashSales/src/EasyAbp.EShop.Plugins.FlashSales.Application/EasyAbp/EShop/Plugins/FlashSales/FlashSalePlans/FlashSalePlanAppService.cs index 2eb6b92d..b61b3a50 100644 --- a/plugins/FlashSales/src/EasyAbp.EShop.Plugins.FlashSales.Application/EasyAbp/EShop/Plugins/FlashSales/FlashSalePlans/FlashSalePlanAppService.cs +++ b/plugins/FlashSales/src/EasyAbp.EShop.Plugins.FlashSales.Application/EasyAbp/EShop/Plugins/FlashSales/FlashSalePlans/FlashSalePlanAppService.cs @@ -121,6 +121,11 @@ public class FlashSalePlanAppService : { await CheckGetListPolicyAsync(); + if (input.IncludeUnpublished) + { + await CheckMultiStorePolicyAsync(input.StoreId, FlashSalesPermissions.FlashSalePlan.Manage); + } + return await base.GetListAsync(input); } @@ -191,11 +196,6 @@ public class FlashSalePlanAppService : protected override async Task> CreateFilteredQueryAsync(FlashSalePlanGetListInput input) { - if (input.IncludeUnpublished) - { - await CheckMultiStorePolicyAsync(input.StoreId, FlashSalesPermissions.FlashSalePlan.Manage); - } - return (await base.CreateFilteredQueryAsync(input)) .WhereIf(input.StoreId.HasValue, x => x.StoreId == input.StoreId.Value) .WhereIf(input.ProductId.HasValue, x => x.ProductId == input.ProductId.Value)