models

package
v0.0.5 Latest Latest
Warning

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

Go to latest
Published: Apr 12, 2021 License: MIT Imports: 4 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func GetInformationResponse

func GetInformationResponse() ([]byte, error)

returns basic information

func GetJSONResponse

func GetJSONResponse(
	message string,
	alert string,
	status string,
	token string,
	httpStatus int,
) ([]byte, error)

general message model

Types

type InformationModel

type InformationModel map[string]string

type LoginRequest

type LoginRequest struct {
	Username string `json:"username"`
	Password string `json:"password"`
}

login request struct

type LoginWithTokenRequest

type LoginWithTokenRequest struct {
	Username string `json:"username"`
	Password string `json:"password"`
	Token    string `json:"token"`
}

login with token request

type MessageModel

type MessageModel map[string]string

type OutputUserStruct

type OutputUserStruct struct {
	Username     string    `json:"username"`
	Root         bool      `json:"root"`
	Mail         string    `json:"mail"`
	RegisterDate time.Time `json:"register_date"`
	Status       string    `json:"status"`
}

struct for user as response

type PermissionModel

type PermissionModel struct {
	ID              int    `json:"ID"`
	Name            string `json:"name"`
	Color           string `json:"color"`
	PermissionLevel int    `json:"permission-level"`
}

permission model

type RowConfigModel

type RowConfigModel struct {
	Type string `json:"type"`
	Name string `json:"name"`
}

table column config model

type TableModel

type TableModel struct {
	ID         int    `json:"id"`
	Name       string `json:"name"`
	Entries    int    `json:"entries"`
	MinPermLvl int    `json:"min_perm_lvl"`
	CreatedAt  string `json:"created_at"`
}

table model

Jump to

Keyboard shortcuts

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