go-admin: github.com/GoAdminGroup/go-admin/examples/datamodel Index | Files

package datamodel

import "github.com/GoAdminGroup/go-admin/examples/datamodel"


Package Files

authors.go bootstrap.go content.go goadmin_super_users.go mysql_types.go posts.go tables.go user.go


var Generators = map[string]table.Generator{
    "posts":   GetPostsTable,
    "authors": GetAuthorsTable,

generators is a map of table models.

The key of generators is the prefix of table info url. The corresponding value is the Form and TableName data.



"posts" => http://localhost:9033/admin/info/posts "authors" => http://localhost:9033/admin/info/authors

func GetAllTypesTable Uses

func GetAllTypesTable() table.Table

GetAllTypesTable return the model of table types.

func GetAuthorsTable Uses

func GetAuthorsTable(ctx *context.Context) (authorsTable table.Table)

GetAuthorsTable return the model of table author.

func GetContent Uses

func GetContent(ctx *context.Context) (types.Panel, error)

GetContent return the content of index page.

func GetGoadminSuperUsersTable Uses

func GetGoadminSuperUsersTable(ctx *context.Context) table.Table

func GetPostsTable Uses

func GetPostsTable(ctx *context.Context) (postsTable table.Table)

GetPostsTable return the model of table posts.

func GetUserTable Uses

func GetUserTable(ctx *context.Context) (userTable table.Table)

GetUserTable return the model of table user.

Package datamodel imports 20 packages (graph) and is imported by 17 packages. Updated 2020-08-05. Refresh now. Tools for package owners.