You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Description / Steps to reproduce / Feature proposal
Currently, we have a temporary implementation for an inclusion resolver e.g. (in the find method in todo.repository.ts):
// poor-mans inclusion resolver, this should be handled by DefaultCrudRepo// and use `inq` operator to fetch related todo-lists in fewer DB queries// this is a temporary implementationif(include&&include.length&&include[0].relation==='todoList'){awaitPromise.all(result.map(asyncr=>{r.todoList=awaitthis.todoList(r.id);}),);}
- Overwrote find and findById functions in TodoRepository, TodoListRepository, TodoListImage to include a hard-coded retrieval of related models. #3195 is for improvement of this
- Updated response schemas for controller methods find and findById to leverage getModelSchemaRef and includeRelations
- Updated TodoList tutorial
Co-authored-by: Miroslav Bajtoš <[email protected]>
- Overwrote find and findById functions in TodoRepository, TodoListRepository, TodoListImage to include a hard-coded retrieval of related models. #3195 is for improvement of this
- Updated response schemas for controller methods find and findById to leverage getModelSchemaRef and includeRelations
- Updated TodoList tutorial
Co-authored-by: Miroslav Bajtoš <[email protected]>
Description / Steps to reproduce / Feature proposal
Currently, we have a temporary implementation for an inclusion resolver e.g. (in the
find
method in todo.repository.ts):Related: #2633
Acceptance Criteria
find
methods fetch related instances relation models at a production-grade level.DefaultCrudRepository
inq
operator to fetch the related model instance(s) in fewer DB queriescc @bajtos
The text was updated successfully, but these errors were encountered: