model

package
v0.0.5 Latest Latest
Warning

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

Go to latest
Published: Jun 24, 2024 License: MIT Imports: 4 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func BindToView

func BindToView(view *pb.User, model *User)

BindToView bind to view.

func BindToViewIgnore added in v0.0.5

func BindToViewIgnore(view *pb.User, model *User)

func NewView added in v0.0.2

func NewView(model *User) *pb.User

Types

type User

type User struct {
	ID      int64
	Nick    string
	Enabled int8
	Balance float32
	Total   float32
	Num     int

	UpdatedAt time.Time
	CreatedAt time.Time
	Sub       []*User
	User      *User
	// contains filtered or unexported fields
}

func NewModel added in v0.0.2

func NewModel(view *pb.User) *User

func (*User) Bind

func (p *User) Bind(view *pb.User)

Bind UserModel.

func (*User) GetPrivate

func (p *User) GetPrivate() string

func (*User) NewView added in v0.0.2

func (p *User) NewView() *pb.User

func (*User) SetPrivate

func (p *User) SetPrivate(priv string)

Jump to

Keyboard shortcuts

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