From 4b3fd35893972bb05fd7ab89dc624ab805093ff3 Mon Sep 17 00:00:00 2001 From: zs <zhousong@weben-smart.com> Date: 周日, 18 5月 2025 19:47:46 +0800 Subject: [PATCH] Merge branch 'master' of http://222.71.245.114:9086/r/HIA24016N_PipeLineDemo --- PipeLineLems/server/src/CMS.Plugin.PipeLineLems.Application/Implements/WorkPlanAppService.cs | 53 +++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 files changed, 53 insertions(+), 0 deletions(-) diff --git a/PipeLineLems/server/src/CMS.Plugin.PipeLineLems.Application/Implements/WorkPlanAppService.cs b/PipeLineLems/server/src/CMS.Plugin.PipeLineLems.Application/Implements/WorkPlanAppService.cs index ce8adc5..01ffc44 100644 --- a/PipeLineLems/server/src/CMS.Plugin.PipeLineLems.Application/Implements/WorkPlanAppService.cs +++ b/PipeLineLems/server/src/CMS.Plugin.PipeLineLems.Application/Implements/WorkPlanAppService.cs @@ -12,6 +12,7 @@ using Volo.Abp.ObjectMapping; using Volo.Abp.Users; using CmsQueryExtensions.Entitys; +using System.Collections.Generic; namespace CMS.Plugin.PipeLineLems.Application.Implements; @@ -543,4 +544,56 @@ { return await _workPlanRepository.GetSingleByFilterAsync(whereConditions, is鈥婱ultipleThrowException); } + + + /// <summary> + /// 鏍规嵁鏉′欢鑾峰彇浣滀笟璁″垝琛ㄥ垪琛� + /// </summary> + /// <param name="input"></param> + /// <returns></returns> + public virtual async Task<List<WorkPlanDto>> FindListByFilterAsync(GetWorkPlanInput input, CancellationToken cancellationToken = default) + { + Check.NotNull(input, nameof(input)); + + if (input.Sorting.IsNullOrWhiteSpace()) + { + input.Sorting = nameof(WorkPlan.Sort); + } + + #region 鍔ㄦ�佹瀯閫犳煡璇㈡潯浠� + + //鍔ㄦ�佹瀯閫犳煡璇㈡潯浠� + var whereConditions = DynamicGetQueryParams(input); + + #endregion + + var list = await _workPlanRepository.GetListByFilterAsync(whereConditions?.data); + + return new List<WorkPlanDto>(ObjectMapper.Map<List<WorkPlan>, List<WorkPlanDto>>(list)); + } + /// <summary> + /// 鏍规嵁鏉′欢鑾峰彇鍗曚釜浣滀笟璁″垝琛� + /// </summary> + /// <param name="input"></param> + /// <returns></returns> + public virtual async Task<WorkPlanDto> FindSingleByFilterAsync(GetWorkPlanInput input, CancellationToken cancellationToken = default) + { + Check.NotNull(input, nameof(input)); + + if (input.Sorting.IsNullOrWhiteSpace()) + { + input.Sorting = nameof(WorkPlan.Sort); + } + + #region 鍔ㄦ�佹瀯閫犳煡璇㈡潯浠� + + //鍔ㄦ�佹瀯閫犳煡璇㈡潯浠� + var whereConditions = DynamicGetQueryParams(input); + + #endregion + + var dataObj = await _workPlanRepository.GetSingleByFilterAsync(whereConditions?.data); + + return (ObjectMapper.Map<WorkPlan, WorkPlanDto>(dataObj)); + } } -- Gitblit v1.9.3