Open Closed

Complicated linq queries placement #6257


User avatar
0
Serge created
  • ABP Framework version: v7.2.2
  • Database System: EF Core (PostgreSQL)
  • Tiered (for MVC) or Auth Server Separated (for Angular): yes

Hi I want to make a join of few tables and select data from result via linq query. Where is the best place to put it: in repositories or in app services? Logically it sounds better in repositories, but EFCore module doesn't have reference to Contracts module with dtos. What is a better approach according to ABP architecture and DDD?

Thank you


2 Answer(s)
  • User Avatar
    0
    maliming created
    Support Team Fullstack Developer

    hi

    The Repositories is the right place.

    You can create a domain model in Domain.Shared.

    Convert the model to DTO in appservice.

  • User Avatar
    0
    Serge created

    ok, thank you

Made with ❤️ on ABP v8.2.0-preview Updated on March 25, 2024, 15:11