Documentation ¶
Index ¶
- func NewFakeStore() *fakeStore
- func ProvideService(ac accesscontrol.AccessControl, bus bus.Bus, cfg *setting.Cfg, ...) folder.Service
- func ProvideStore(db db.DB, cfg *setting.Cfg, features featuremgmt.FeatureToggles) *sqlStore
- type DashboardFolderStoreImpl
- func (d *DashboardFolderStoreImpl) GetFolderByID(ctx context.Context, orgID int64, id int64) (*folder.Folder, error)
- func (d *DashboardFolderStoreImpl) GetFolderByTitle(ctx context.Context, orgID int64, title string) (*folder.Folder, error)
- func (d *DashboardFolderStoreImpl) GetFolderByUID(ctx context.Context, orgID int64, uid string) (*folder.Folder, error)
- func (d *DashboardFolderStoreImpl) GetFolders(ctx context.Context, orgID int64, uids []string) (map[string]*folder.Folder, error)
- type Service
- func (s *Service) BuildSaveDashboardCommand(ctx context.Context, dto *dashboards.SaveDashboardDTO) (*dashboards.SaveDashboardCommand, error)
- func (s *Service) Create(ctx context.Context, cmd *folder.CreateFolderCommand) (*folder.Folder, error)
- func (s *Service) DBMigration(db db.DB)
- func (s *Service) Delete(ctx context.Context, cmd *folder.DeleteFolderCommand) error
- func (s *Service) Get(ctx context.Context, cmd *folder.GetFolderQuery) (*folder.Folder, error)
- func (s *Service) GetChildren(ctx context.Context, cmd *folder.GetChildrenQuery) ([]*folder.Folder, error)
- func (s *Service) GetDescendantCounts(ctx context.Context, cmd *folder.GetDescendantCountsQuery) (folder.DescendantCounts, error)
- func (s *Service) GetParents(ctx context.Context, q folder.GetParentsQuery) ([]*folder.Folder, error)
- func (s *Service) MakeUserAdmin(ctx context.Context, orgID int64, userID, folderID int64, ...) error
- func (s *Service) Move(ctx context.Context, cmd *folder.MoveFolderCommand) (*folder.Folder, error)
- func (s *Service) RegisterService(r folder.RegistryService) error
- func (s *Service) Update(ctx context.Context, cmd *folder.UpdateFolderCommand) (*folder.Folder, error)
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func NewFakeStore ¶
func NewFakeStore() *fakeStore
func ProvideService ¶
func ProvideService( ac accesscontrol.AccessControl, bus bus.Bus, cfg *setting.Cfg, dashboardStore dashboards.Store, folderStore folder.FolderStore, db db.DB, features featuremgmt.FeatureToggles, ) folder.Service
func ProvideStore ¶
func ProvideStore(db db.DB, cfg *setting.Cfg, features featuremgmt.FeatureToggles) *sqlStore
Types ¶
type DashboardFolderStoreImpl ¶
type DashboardFolderStoreImpl struct {
// contains filtered or unexported fields
}
DashboardStore implements the FolderStore interface It fetches folders from the dashboard DB table
func ProvideDashboardFolderStore ¶
func ProvideDashboardFolderStore(sqlStore db.DB) *DashboardFolderStoreImpl
func (*DashboardFolderStoreImpl) GetFolderByID ¶
func (*DashboardFolderStoreImpl) GetFolderByTitle ¶
func (*DashboardFolderStoreImpl) GetFolderByUID ¶
type Service ¶
type Service struct {
// contains filtered or unexported fields
}
func (*Service) BuildSaveDashboardCommand ¶
func (s *Service) BuildSaveDashboardCommand(ctx context.Context, dto *dashboards.SaveDashboardDTO) (*dashboards.SaveDashboardCommand, error)
BuildSaveDashboardCommand is a simplified version on DashboardServiceImpl.BuildSaveDashboardCommand keeping only the meaningful functionality for folders
func (*Service) DBMigration ¶
func (*Service) GetChildren ¶
func (*Service) GetDescendantCounts ¶
func (s *Service) GetDescendantCounts(ctx context.Context, cmd *folder.GetDescendantCountsQuery) (folder.DescendantCounts, error)
func (*Service) GetParents ¶
func (*Service) MakeUserAdmin ¶
func (s *Service) MakeUserAdmin(ctx context.Context, orgID int64, userID, folderID int64, setViewAndEditPermissions bool) error
MakeUserAdmin is copy of DashboardServiceImpl.MakeUserAdmin
func (*Service) RegisterService ¶
func (s *Service) RegisterService(r folder.RegistryService) error
Click to show internal directories.
Click to hide internal directories.