[v10.3.x] Annotations: Improve query performance when using dashboard filter (#83405)

Annotations: Improve query performance when using dashboard filter (#83112)

* Annotations: Improve query performance when using dashboard filter

* Add dashboard id filter

(cherry picked from commit e7a1ecca28)
This commit is contained in:
Alexander Zobnin
2024-02-27 19:02:11 +03:00
committed by GitHub
parent 8d687b4796
commit 1409398f32
3 changed files with 22 additions and 8 deletions
@@ -68,7 +68,7 @@ func (r *RepositoryImpl) Update(ctx context.Context, item *annotations.Item) err
}
func (r *RepositoryImpl) Find(ctx context.Context, query *annotations.ItemQuery) ([]*annotations.ItemDTO, error) {
resources, err := r.authZ.Authorize(ctx, query.OrgID, query.SignedInUser)
resources, err := r.authZ.Authorize(ctx, query.OrgID, query)
if err != nil {
return make([]*annotations.ItemDTO, 0), err
}