test

package
v0.0.0-...-f683405 Latest Latest
Warning

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

Go to latest
Published: May 30, 2020 License: MIT Imports: 13 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var Path string

Functions

func FilterViewController

func FilterViewController(ctx *fiber.Ctx)

func Register

func Register()

Types

type ActionType

type ActionType string
const (
	RESET    ActionType = "reset"
	SEARCH   ActionType = "search"
	PAGESIZE ActionType = "pagesize"
	ORDER    ActionType = "order"
)

type App

type App struct{}

func (App) Menus

func (App) Menus() []menu.Menu

func (App) Permissions

func (App) Permissions() []user.Permission

func (App) Register

func (App) Register()

func (App) Router

func (App) Router()

func (App) WhenReady

func (App) WhenReady()

type Column

type Column struct {
	Type         ColumnType
	Title        string
	Width        int
	Resize       bool
	Order        bool
	Name         string
	Alias        string
	Select       string
	Options      []html.KeyValue
	InputBuilder func(r *io.Request) html.Renderable
	Attribs      html.Attributes
	QueryBuilder func(r *io.Request) []string
	SimpleFilter string
	Processor    func(column Column, data map[string]interface{}, r *io.Request) string
	Model        interface{}
}

func (Column) Filter

func (col Column) Filter(r *io.Request) html.Renderable

type ColumnType

type ColumnType int
const (
	TEXT    ColumnType = 0
	NUMBER  ColumnType = 1
	DATE    ColumnType = 2
	HTML    ColumnType = 3
	RANGE   ColumnType = 4
	SELECT  ColumnType = 5
	CUSTOM  ColumnType = 6
	ACTIONS ColumnType = 7
	None    ColumnType = 8
)

type Controller

type Controller struct{}

type FilterView

type FilterView struct {
	Style        string
	Columns      []Column
	Model        interface{}
	Join         []Join
	Attribs      html.Attributes
	Unscoped     bool
	QueryBuilder func(r *io.Request) []string

	Pagination Pagination
	// contains filtered or unexported fields
}

func (FilterView) GetData

func (fv FilterView) GetData() []map[string]interface{}

func (*FilterView) Prepare

func (fv *FilterView) Prepare(r *io.Request)

func (FilterView) SizeInput

func (fv FilterView) SizeInput(r *io.Request) string

type Join

type Join struct {
	Model  interface{}
	MainFK string
	DestFK string
}

type MyGroup

type MyGroup struct {
	io.Model
	Name string
}

type MyModel

type MyModel struct {
	io.Model
	Name     string
	Username string
	Group    int
	Type     int
	Alias    string
}

type Pagination

type Pagination struct {
	Records     int
	CurrentPage int
	Pages       int
	Limit       int
	First       int
	Last        int
	PageRange   []int
}

Jump to

Keyboard shortcuts

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