model

package
v2.6.11 Latest Latest
Warning

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

Go to latest
Published: Mar 20, 2021 License: MIT Imports: 1 Imported by: 10

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func StoreUser added in v2.4.0

func StoreUser(ctx context.Context, user User) context.Context

StoreUser stores given User in context

Types

type User

type User struct {
	Login    string `json:"login"`
	Password string `json:"password,omitempty"`
	ID       uint64 `json:"id"`
}

User of the app

var NoneUser User

NoneUser is a dummy user

func NewUser

func NewUser(id uint64, login string) User

NewUser creates new user with given id, login and profiles

func ReadUser added in v2.4.0

func ReadUser(ctx context.Context) User

ReadUser retrieves user from context

Jump to

Keyboard shortcuts

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