user

package
v1.56.0 Latest Latest
Warning

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

Go to latest
Published: Jan 28, 2018 License: AGPL-3.0 Imports: 3 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Exists added in v1.56.0

func Exists(users []User, userID string) bool

Exists ehecks if user is in array.

Types

type User

type User struct {
	model.BaseEntity
	Firstname string            `json:"firstname"`
	Lastname  string            `json:"lastname"`
	Email     string            `json:"email"`
	Initials  string            `json:"initials"`
	Active    bool              `json:"active"`
	Editor    bool              `json:"editor"`
	Admin     bool              `json:"admin"`
	ViewUsers bool              `json:"viewUsers"`
	Global    bool              `json:"global"`
	Password  string            `json:"-"`
	Salt      string            `json:"-"`
	Reset     string            `json:"-"`
	Accounts  []account.Account `json:"accounts"`
}

User defines a login.

func (*User) Fullname

func (user *User) Fullname() string

Fullname returns Firstname + Lastname.

func (*User) GetAccount

func (user *User) GetAccount(orgID string) (a account.Account, found bool)

GetAccount returns matching org account using orgID

func (*User) ProtectSecrets

func (user *User) ProtectSecrets()

ProtectSecrets blanks sensitive data.

Jump to

Keyboard shortcuts

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