infoDetail

package
v1.3.0-rc.0...-d217119 Latest Latest
Warning

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

Go to latest
Published: Dec 5, 2024 License: Apache-2.0 Imports: 13 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Command

type Command struct {
	Key          string `json:"key"`
	Target       string `json:"target"`
	JumpOut      bool
	CommandState CommandState `json:"state"`
}

type CommandState

type CommandState struct {
	Visible  bool     `json:"visible"`
	FormData FormData `json:"formData"`
}

type Data

type Data struct {
	Survive                 string  `json:"survive"`
	NodeIP                  string  `json:"nodeIP"`
	Version                 string  `json:"version"`
	Os                      string  `json:"os"`
	ContainerRuntimeVersion string  `json:"containerRuntimeVersion"`
	PodNum                  string  `json:"podNum"`
	Tags                    []Field `json:"tag"`
	Annotation              []Field `json:"annotation"`
	Taints                  []Field `json:"taint"`
}

type Field

type Field struct {
	Label      string               `json:"label,omitempty"`
	Group      string               `json:"group,omitempty"`
	ValueKey   string               `json:"valueKey,omitempty"`
	RenderType string               `json:"renderType,omitempty"`
	SpaceNum   int                  `json:"spaceNum,omitempty"`
	Operations map[string]Operation `json:"operations,omitempty"`
}

type FormData

type FormData struct {
	RecordId string `json:"recordId"`
}

type InfoDetail

type InfoDetail struct {
	SDK   *cptype.SDK
	Ctx   context.Context
	Type  string          `json:"type"`
	Props Props           `json:"props"`
	Data  map[string]Data `json:"data"`
	State State           `json:"state"`
}

func (*InfoDetail) GetLabelGroupAndDisplayName

func (infoDetail *InfoDetail) GetLabelGroupAndDisplayName(label string) (string, string)

func (*InfoDetail) Init

func (infoDetail *InfoDetail) Init(ctx servicehub.Context) error

func (*InfoDetail) Render

type Operation

type Operation struct {
	Key           string                 `json:"key"`
	Reload        bool                   `json:"reload"`
	FillMeta      string                 `json:"fillMeta,omitempty"`
	Target        string                 `json:"target,omitempty"`
	Meta          map[string]interface{} `json:"meta,omitempty"`
	ClickableKeys interface{}            `json:"clickableKeys,omitempty"`
	Text          string                 `json:"text"`
	Command       Command                `json:"command,omitempty"`
}

type Props

type Props struct {
	ColumnNum int     `json:"columnNum"`
	Fields    []Field `json:"fields"`
}

type State

type State struct {
	ClusterName string `json:"clusterName,omitempty"`
	NodeID      string `json:"nodeId,omitempty"`
}

Jump to

Keyboard shortcuts

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