pluginsettings

package
v0.0.85-test Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: May 8, 2023 License: AGPL-3.0 Imports: 2 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type DTO

type DTO struct {
	ID             int64
	OrgID          int64
	PluginID       string
	PluginVersion  string
	JSONData       map[string]interface{}
	SecureJSONData map[string][]byte
	Enabled        bool
	Pinned         bool
	Updated        time.Time
}

type GetArgs

type GetArgs struct {
	OrgID int64
}

type GetByPluginIDArgs

type GetByPluginIDArgs struct {
	PluginID string
	OrgID    int64
}

type Service

type Service interface {
	// GetPluginSettings returns all Plugin Settings for the provided Org
	GetPluginSettings(ctx context.Context, args *GetArgs) ([]*DTO, error)
	// GetPluginSettingByPluginID returns a Plugin Settings by Plugin ID
	GetPluginSettingByPluginID(ctx context.Context, args *GetByPluginIDArgs) (*DTO, error)
	// UpdatePluginSetting updates a Plugin Setting
	UpdatePluginSetting(ctx context.Context, args *UpdateArgs) error
	// UpdatePluginSettingPluginVersion updates a Plugin Setting's plugin version
	UpdatePluginSettingPluginVersion(ctx context.Context, args *UpdatePluginVersionArgs) error
	// DecryptedValues decrypts the encrypted secureJSONData of the provided plugin setting and
	// returns the decrypted values.
	DecryptedValues(ps *DTO) map[string]string
}

type UpdateArgs

type UpdateArgs struct {
	Enabled                 bool
	Pinned                  bool
	JSONData                map[string]interface{}
	SecureJSONData          map[string]string
	PluginVersion           string
	PluginID                string
	OrgID                   int64
	EncryptedSecureJSONData map[string][]byte
}

type UpdatePluginVersionArgs

type UpdatePluginVersionArgs struct {
	PluginVersion string
	PluginID      string
	OrgID         int64
}

Directories

Path Synopsis

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL