model

package
Version: v0.0.0-...-105474d Latest Latest
Warning

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

Go to latest
Published: Jan 15, 2020 License: MIT Imports: 6 Imported by: 0

Documentation

Index

Constants

View Source
const (
	N        = 16384
	R        = 8
	P        = 1
	KEYLENTH = 32
)

Variables

This section is empty.

Functions

func CheckPassword

func CheckPassword(user, pwd, ctime, cpwd string) bool

func EncryptPassword

func EncryptPassword(user, pwd, ctime string) ([]byte, error)

func GetConfFileList

func GetConfFileList(env string, page, size int) (*common.PageDataType, error)

func GetConfTagList

func GetConfTagList(page, size int) (*common.PageDataType, error)

func GetCronTagList

func GetCronTagList(page, size int) (*common.PageDataType, error)

func GetCronTaskList

func GetCronTaskList(env string, page, size int) (*common.PageDataType, error)

func GetUserList

func GetUserList(page, size int) (*common.PageDataType, error)

Types

type ConfFile

type ConfFile struct {
	ConfId   string `json:"confid"`
	ConfName string `json:"confname"`
	Path     string `json:"path"`
	Content  string `json:"content"`
}

func (*ConfFile) Create

func (f *ConfFile) Create(env string) (bool, error)

func (*ConfFile) Delete

func (f *ConfFile) Delete(env string) (bool, error)

func (*ConfFile) Update

func (f *ConfFile) Update(env string) (bool, error)

type ConfTag

type ConfTag struct {
	TagId   string `json:"tagid"`
	Tagname string `json::tagname`
	Remark  string `json:"remark"`
}

func (*ConfTag) Create

func (t *ConfTag) Create() (bool, error)

func (*ConfTag) Delete

func (t *ConfTag) Delete() (bool, error)

type CronNode

type CronNode struct {
	NodeName string `json:"nodename"`
	LoadStat string `json:"loadstat"`
}

func GetCronNodeList

func GetCronNodeList(env string) ([]*CronNode, error)

type CronTag

type CronTag struct {
	TagId   string `json:"tagid"`
	Tagname string `json:"tagname"`
	Remark  string `json:"remark"`
}

func (*CronTag) Create

func (t *CronTag) Create() (bool, error)

func (*CronTag) Delete

func (t *CronTag) Delete() (bool, error)

type CronTask

type CronTask struct {
	CronID   string `json:"cronid"`
	CronName string `json:"cronname"`
	Env      string `json:"env"`
	Args     string `json:"args"`
	Schedule string `json:"schedule"`
	Enable   string `json:"enable"`
	Ctime    int64  `json:"ctime"`
	Mtime    int64  `json:"mtime"`
	Remark   string `json:"remark"`
}

func (*CronTask) Create

func (t *CronTask) Create() (bool, error)

func (*CronTask) Delete

func (t *CronTask) Delete() (bool, error)

func (*CronTask) Status

func (t *CronTask) Status() (bool, error)

func (*CronTask) Update

func (t *CronTask) Update() (bool, error)

func (*CronTask) UpdateStatus

func (t *CronTask) UpdateStatus() (bool, error)

type User

type User struct {
	UserId   string `json:"userid"`
	Username string `json:"username"`
	Nickname string `json:"nickname"`
	Password string `json:"password"`
	Ctime    int64  `json:"ctime"`
	Mtime    int64  `json:"mtime"`
}

func (*User) Create

func (u *User) Create() (bool, error)

func (*User) Delete

func (u *User) Delete() (bool, error)

func (*User) Update

func (u *User) Update() (bool, error)

type UserPassword

type UserPassword struct {
	Username string `json:"username"`
	Password string `json:"password"`
	Ctime    string `json:"ctime"`
}

func GetUserPassword

func GetUserPassword(user string) (*UserPassword, error)

Jump to

Keyboard shortcuts

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