dashboard

package
v3.6.1 Latest Latest
Warning

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

Go to latest
Published: Sep 8, 2021 License: AGPL-3.0 Imports: 3 Imported by: 0

README

后台仪表盘

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func BlockAdd

func BlockAdd(index int, block ...*Block)

func BlockRegister

func BlockRegister(block ...*Block)

func BlockRemove

func BlockRemove(index int)

BlockRemove 删除元素

func BlockSet

func BlockSet(index int, list ...*Block)

BlockSet 设置元素

func CardAdd

func CardAdd(index int, card ...*Card)

func CardRegister

func CardRegister(card ...*Card)

func CardRemove

func CardRemove(index int)

CardRemove 删除元素

func CardSet

func CardSet(index int, list ...*Card)

CardSet 设置元素

func GlobalFooterAdd

func GlobalFooterAdd(index int, footer ...*GlobalFooter)

func GlobalFooterRegister

func GlobalFooterRegister(footer ...*GlobalFooter)

func GlobalFooterRemove

func GlobalFooterRemove(index int)

GlobalFooterRemove 删除元素

func GlobalFooterSet

func GlobalFooterSet(index int, list ...*GlobalFooter)

GlobalFooterSet 设置元素

func GlobalHeadAdd

func GlobalHeadAdd(index int, footer ...*GlobalHead)

func GlobalHeadRegister

func GlobalHeadRegister(footer ...*GlobalHead)

func GlobalHeadRemove

func GlobalHeadRemove(index int)

GlobalHeadRemove 删除元素

func GlobalHeadSet

func GlobalHeadSet(index int, list ...*GlobalHead)

GlobalHeadSet 设置元素

func TopButtonAdd

func TopButtonAdd(index int, topButton ...*TopButton)

func TopButtonRegister

func TopButtonRegister(topButton ...*TopButton)

func TopButtonRemove

func TopButtonRemove(index int)

TopButtonRemove 删除元素

func TopButtonSet

func TopButtonSet(index int, list ...*TopButton)

TopButtonSet 设置元素

Types

type Block

type Block struct {
	Title  string `json:",omitempty" xml:",omitempty"` // 标题
	Ident  string `json:",omitempty" xml:",omitempty"` // 英文标识
	Extra  echo.H `json:",omitempty" xml:",omitempty"` // 附加数据
	Hidden sql.NullBool
	Tmpl   string //模板文件
	Footer string //页脚模板文件
	// contains filtered or unexported fields
}

func NewBlock

func NewBlock(content func(echo.Context) error) *Block

func (*Block) IsHidden

func (c *Block) IsHidden(ctx echo.Context) bool

func (*Block) Ready

func (c *Block) Ready(ctx echo.Context) error

func (*Block) SetContentGenerator

func (c *Block) SetContentGenerator(content func(echo.Context) error) *Block

func (*Block) SetExtra

func (c *Block) SetExtra(extra echo.H) *Block

func (*Block) SetExtraKV

func (c *Block) SetExtraKV(key string, value interface{}) *Block

func (*Block) SetFooter

func (c *Block) SetFooter(footer string) *Block

func (*Block) SetHidden

func (c *Block) SetHidden(hidden bool) *Block

func (*Block) SetHiddenDetector

func (c *Block) SetHiddenDetector(hidden func(echo.Context) bool) *Block

func (*Block) SetIdent

func (c *Block) SetIdent(ident string) *Block

func (*Block) SetTitle

func (c *Block) SetTitle(title string) *Block

func (*Block) SetTmpl

func (c *Block) SetTmpl(tmpl string) *Block

type Blocks

type Blocks []*Block

func BlockAll

func BlockAll(ctx echo.Context) Blocks

func (*Blocks) Add

func (c *Blocks) Add(index int, list ...*Block)

Add 添加列表项

func (*Blocks) Ready

func (c *Blocks) Ready(ctx echo.Context) error

func (*Blocks) Remove

func (c *Blocks) Remove(index int)

Remove 删除元素

func (*Blocks) Set

func (c *Blocks) Set(index int, list ...*Block)

Set 设置元素

func (*Blocks) Size

func (c *Blocks) Size() int

type Card

type Card struct {
	IconName  string      //图标名称:fa-tasks
	IconColor string      //图标颜色:primary、success、danger、warning、info
	Short     string      //简称
	Name      string      //中文名称
	Summary   string      //说明
	Content   interface{} //数字等内容
	// contains filtered or unexported fields
}

func NewCard

func NewCard(content func(echo.Context) interface{}) *Card

func (*Card) Build

func (c *Card) Build(ctx echo.Context) *Card

func (*Card) SetContentGenerator

func (c *Card) SetContentGenerator(content func(echo.Context) interface{}) *Card

type Cards

type Cards []*Card

func CardAll

func CardAll(_ echo.Context) *Cards

func (*Cards) Add

func (c *Cards) Add(index int, list ...*Card)

func (*Cards) Build

func (c *Cards) Build(ctx echo.Context) Cards

func (*Cards) Remove

func (c *Cards) Remove(index int)

Remove 删除元素

func (*Cards) Set

func (c *Cards) Set(index int, list ...*Card)

Set 设置元素

func (*Cards) Size

func (c *Cards) Size() int
type GlobalFooter struct {
	Tmpl string //模板文件
	// contains filtered or unexported fields
}

func NewGlobalFooter

func NewGlobalFooter(tmpl string, handle ...func(echo.Context) error) *GlobalFooter

func (*GlobalFooter) Ready

func (c *GlobalFooter) Ready(ctx echo.Context) error

func (*GlobalFooter) SetContentGenerator

func (c *GlobalFooter) SetContentGenerator(content func(echo.Context) error) *GlobalFooter

func (*GlobalFooter) SetTmpl

func (c *GlobalFooter) SetTmpl(tmpl string) *GlobalFooter

type GlobalFooters

type GlobalFooters []*GlobalFooter

func GlobalFooterAll

func GlobalFooterAll(_ echo.Context) GlobalFooters

func (*GlobalFooters) Add

func (c *GlobalFooters) Add(index int, list ...*GlobalFooter)

func (*GlobalFooters) Ready

func (c *GlobalFooters) Ready(ctx echo.Context) error

func (*GlobalFooters) Remove

func (c *GlobalFooters) Remove(index int)

Remove 删除元素

func (*GlobalFooters) Set

func (c *GlobalFooters) Set(index int, list ...*GlobalFooter)

Set 设置元素

func (*GlobalFooters) Size

func (c *GlobalFooters) Size() int
type GlobalHead struct {
	Tmpl string //模板文件
	// contains filtered or unexported fields
}

func NewGlobalHead

func NewGlobalHead(tmpl string, handle ...func(echo.Context) error) *GlobalHead

func (*GlobalHead) Ready

func (c *GlobalHead) Ready(ctx echo.Context) error

func (*GlobalHead) SetContentGenerator

func (c *GlobalHead) SetContentGenerator(content func(echo.Context) error) *GlobalHead

func (*GlobalHead) SetTmpl

func (c *GlobalHead) SetTmpl(tmpl string) *GlobalHead

type GlobalHeads

type GlobalHeads []*GlobalHead

func GlobalHeadAll

func GlobalHeadAll(_ echo.Context) GlobalHeads

func (*GlobalHeads) Add

func (c *GlobalHeads) Add(index int, list ...*GlobalHead)

func (*GlobalHeads) Ready

func (c *GlobalHeads) Ready(ctx echo.Context) error

func (*GlobalHeads) Remove

func (c *GlobalHeads) Remove(index int)

Remove 删除元素

func (*GlobalHeads) Set

func (c *GlobalHeads) Set(index int, list ...*GlobalHead)

Set 设置元素

func (*GlobalHeads) Size

func (c *GlobalHeads) Size() int

type TopButton

type TopButton struct {
	Tmpl string //模板文件
	// contains filtered or unexported fields
}

func NewTopButton

func NewTopButton(content func(echo.Context) error) *TopButton

func (*TopButton) Ready

func (c *TopButton) Ready(ctx echo.Context) error

func (*TopButton) SetContentGenerator

func (c *TopButton) SetContentGenerator(content func(echo.Context) error) *TopButton

type TopButtons

type TopButtons []*TopButton

func TopButtonAll

func TopButtonAll(_ echo.Context) TopButtons

func (*TopButtons) Add

func (c *TopButtons) Add(index int, list ...*TopButton)

func (*TopButtons) Ready

func (c *TopButtons) Ready(ctx echo.Context) error

func (*TopButtons) Remove

func (c *TopButtons) Remove(index int)

Remove 删除元素

func (*TopButtons) Set

func (c *TopButtons) Set(index int, list ...*TopButton)

Set 设置元素

func (*TopButtons) Size

func (c *TopButtons) Size() int

Jump to

Keyboard shortcuts

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