Documentation ¶
Index ¶
- type BasePanel
- func (panel *BasePanel) CloneOperator(op *data.Operator, sites map[string]string) *data.Operator
- func (panel *BasePanel) Config() *config.Configuration
- func (panel *BasePanel) Execute(w http.ResponseWriter, r *http.Request, session *html.Session, ...) error
- func (panel *BasePanel) FetchOperatorSites(op *data.Operator) (map[string]string, error)
- func (panel *BasePanel) GetPathTemplate(validPaths []string, defaultTemplate string, path string) string
- func (panel *BasePanel) Initialize(name string, panelProvider html.PanelProvider, templates []BasePanelTemplate, ...) error
- func (panel *BasePanel) Redirect(path string, w http.ResponseWriter, r *http.Request) html.ExecutionResult
- type BasePanelTemplate
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type BasePanel ¶
type BasePanel struct {
// contains filtered or unexported fields
}
BasePanel represents the base for all panels.
func (*BasePanel) CloneOperator ¶
CloneOperator clones an operator and adds missing sites.
func (*BasePanel) Config ¶
func (panel *BasePanel) Config() *config.Configuration
Config gets the configuration object.
func (*BasePanel) Execute ¶
func (panel *BasePanel) Execute(w http.ResponseWriter, r *http.Request, session *html.Session, dataProvider html.PanelDataProvider) error
Execute generates the HTTP output of the panel and writes it to the response writer.
func (*BasePanel) FetchOperatorSites ¶
FetchOperatorSites fetches all sites for an operator using Mentix.
func (*BasePanel) GetPathTemplate ¶
func (panel *BasePanel) GetPathTemplate(validPaths []string, defaultTemplate string, path string) string
GetPathTemplate returns the name of the active template.
func (*BasePanel) Initialize ¶
func (panel *BasePanel) Initialize(name string, panelProvider html.PanelProvider, templates []BasePanelTemplate, conf *config.Configuration, log *zerolog.Logger) error
Initialize initializes the base panel.
func (*BasePanel) Redirect ¶
func (panel *BasePanel) Redirect(path string, w http.ResponseWriter, r *http.Request) html.ExecutionResult
Redirect performs an HTTP redirect.
type BasePanelTemplate ¶
type BasePanelTemplate struct { ID string Name string Provider html.ContentProvider }
BasePanelTemplate represents an HTML template used for initialization.
Click to show internal directories.
Click to hide internal directories.