From e3127db7e01304daa0dba71e5bc55584f6c63d7f Mon Sep 17 00:00:00 2001 From: maliming Date: Thu, 20 Aug 2026 11:05:22 +0800 Subject: [PATCH] Point to the mapping libraries for the query projection sample --- .../domain-driven-design/application-services.md | 12 +----------- 1 file changed, 1 insertion(+), 11 deletions(-) diff --git a/docs/en/framework/architecture/domain-driven-design/application-services.md b/docs/en/framework/architecture/domain-driven-design/application-services.md index d1c0186f6d..2aab4cf35a 100644 --- a/docs/en/framework/architecture/domain-driven-design/application-services.md +++ b/docs/en/framework/architecture/domain-driven-design/application-services.md @@ -482,17 +482,7 @@ public class BookProjector : IQueryProjectionMapper } ```` -[Mapperly](https://mapperly.riok.app/) can generate that method for you: - -````csharp -[Mapper(RequiredMappingStrategy = RequiredMappingStrategy.Target)] -public partial class BookProjector : IQueryProjectionMapper -{ - public partial IQueryable ProjectTo(IQueryable source); -} -```` - -> `RequiredMappingStrategy.Target` tells Mapperly to only require the DTO members to be mapped. Without it, it reports a warning for every entity property that the DTO doesn't have. +You don't have to write the `Select` by hand. Both [Mapperly](https://mapperly.riok.app/) and [AutoMapper](https://docs.automapper.org) can project an `IQueryable`, refer to their own documentation for it and to the [object to object mapping document](../../infrastructure/object-to-object-mapping.md) for their ABP integrations. ABP registers the projection mappers by convention, you don't need to configure anything else. Filters (like soft delete and multi-tenancy), sorting and paging are still applied to the query before the projection.