Skip to content
Snippets Groups Projects
Commit 23d3df46 authored by Danis Kirasirov's avatar Danis Kirasirov :8ball: Committed by Pavel Antonov
Browse files

Установлены опции для получения всех элементов при установке расширений

parent 62bcca35
No related branches found
No related tags found
No related merge requests found
......@@ -7,6 +7,7 @@ import (
"git.perx.ru/perxis/perxis-go/pkg/collections"
"git.perx.ru/perxis/perxis-go/pkg/data"
"git.perx.ru/perxis/perxis-go/pkg/errors"
"git.perx.ru/perxis/perxis-go/pkg/options"
"git.perx.ru/perxis/perxis-go/pkg/setup"
pb "git.perx.ru/perxis/perxis-go/proto/extensions"
"go.uber.org/zap"
......@@ -77,7 +78,7 @@ func (s *storage) GetExtension(ctx context.Context, spaceID, envID string, exten
// FindExtensions возвращает состояния расширений в пространстве
func (s *storage) FindExtensions(ctx context.Context, spaceID, envID string, extensions ...string) ([]*Info, error) {
itms, _, err := s.content.Items.Find(ctx, spaceID, envID, ExtensionsCollection.ID, &items.Filter{ID: extensions})
itms, _, err := s.content.Items.Find(ctx, spaceID, envID, ExtensionsCollection.ID, &items.Filter{ID: extensions}, items.NewFindOptions(options.New(0, 10000)))
if err != nil && !strings.Contains(err.Error(), collections.ErrNotFound.Error()) {
return nil, err
}
......
......@@ -10,6 +10,7 @@ import (
"git.perx.ru/perxis/perxis-go/pkg/collections"
"git.perx.ru/perxis/perxis-go/pkg/errors"
"git.perx.ru/perxis/perxis-go/pkg/items"
"git.perx.ru/perxis/perxis-go/pkg/options"
)
var (
......@@ -323,7 +324,7 @@ func (s *Setup) getItems(ctx context.Context, collID string, confs Items) (map[s
s.EnvironmentID,
collID,
&items.Filter{ID: confs.GetIDs()},
&items.FindOptions{Regular: true, Hidden: true, Templates: true},
&items.FindOptions{Regular: true, Hidden: true, Templates: true, FindOptions: *options.New(0, len(confs))},
)
if err != nil {
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment