Where does paging, sorting, etc go in repository pattern?

前端 未结 5 1756
无人及你
无人及你 2021-02-01 07:04

Where do we put the logic for paging and sorting data in an asp.net repository pattern project?

Should it go in the service layer or put it in the controller and have th

5条回答
  •  鱼传尺愫
    2021-02-01 07:22

    The repository should return a 'PageableResultSet', or something like that, which is responsible for the paging.

提交回复
热议问题