user

package
v0.0.0-...-f8e2896 Latest Latest
Warning

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

Go to latest
Published: Jan 9, 2026 License: MIT Imports: 6 Imported by: 0

Documentation

Index

Constants

View Source
const (
	// Label holds the string label denoting the user type in the database.
	Label = "user"
	// FieldID holds the string denoting the id field in the database.
	FieldID = "id"
	// FieldUsername holds the string denoting the username field in the database.
	FieldUsername = "username"
	// FieldEmail holds the string denoting the email field in the database.
	FieldEmail = "email"
	// FieldPhone holds the string denoting the phone field in the database.
	FieldPhone = "phone"
	// FieldPassword holds the string denoting the password field in the database.
	FieldPassword = "password"
	// FieldStatus holds the string denoting the status field in the database.
	FieldStatus = "status"
	// FieldFullName holds the string denoting the full_name field in the database.
	FieldFullName = "full_name"
	// FieldGender holds the string denoting the gender field in the database.
	FieldGender = "gender"
	// FieldAvatar holds the string denoting the avatar field in the database.
	FieldAvatar = "avatar"
	// FieldLanguage holds the string denoting the language field in the database.
	FieldLanguage = "language"
	// FieldTimezone holds the string denoting the timezone field in the database.
	FieldTimezone = "timezone"
	// FieldCreatedBy holds the string denoting the created_by field in the database.
	FieldCreatedBy = "created_by"
	// FieldUpdatedBy holds the string denoting the updated_by field in the database.
	FieldUpdatedBy = "updated_by"
	// FieldCreatedAt holds the string denoting the created_at field in the database.
	FieldCreatedAt = "created_at"
	// FieldUpdatedAt holds the string denoting the updated_at field in the database.
	FieldUpdatedAt = "updated_at"
	// FieldDeletedAt holds the string denoting the deleted_at field in the database.
	FieldDeletedAt = "deleted_at"
	// EdgeAccounts holds the string denoting the accounts edge name in mutations.
	EdgeAccounts = "accounts"
	// EdgeUserTenants holds the string denoting the user_tenants edge name in mutations.
	EdgeUserTenants = "user_tenants"
	// EdgeUserDepartments holds the string denoting the user_departments edge name in mutations.
	EdgeUserDepartments = "user_departments"
	// EdgeUserRoles holds the string denoting the user_roles edge name in mutations.
	EdgeUserRoles = "user_roles"
	// Table holds the table name of the user in the database.
	Table = "users"
	// AccountsTable is the table that holds the accounts relation/edge.
	AccountsTable = "user_accounts"
	// AccountsInverseTable is the table name for the UserAccount entity.
	// It exists in this package in order to avoid circular dependency with the "useraccount" package.
	AccountsInverseTable = "user_accounts"
	// AccountsColumn is the table column denoting the accounts relation/edge.
	AccountsColumn = "user_id"
	// UserTenantsTable is the table that holds the user_tenants relation/edge.
	UserTenantsTable = "user_tenants"
	// UserTenantsInverseTable is the table name for the UserTenant entity.
	// It exists in this package in order to avoid circular dependency with the "usertenant" package.
	UserTenantsInverseTable = "user_tenants"
	// UserTenantsColumn is the table column denoting the user_tenants relation/edge.
	UserTenantsColumn = "user_id"
	// UserDepartmentsTable is the table that holds the user_departments relation/edge.
	UserDepartmentsTable = "user_departments"
	// UserDepartmentsInverseTable is the table name for the UserDepartment entity.
	// It exists in this package in order to avoid circular dependency with the "userdepartment" package.
	UserDepartmentsInverseTable = "user_departments"
	// UserDepartmentsColumn is the table column denoting the user_departments relation/edge.
	UserDepartmentsColumn = "user_id"
	// UserRolesTable is the table that holds the user_roles relation/edge.
	UserRolesTable = "user_roles"
	// UserRolesInverseTable is the table name for the UserRole entity.
	// It exists in this package in order to avoid circular dependency with the "userrole" package.
	UserRolesInverseTable = "user_roles"
	// UserRolesColumn is the table column denoting the user_roles relation/edge.
	UserRolesColumn = "user_id"
)
View Source
const DefaultGender = GenderUNKNOWN

GenderUNKNOWN is the default value of the Gender enum.

View Source
const DefaultStatus = StatusPENDING

StatusPENDING is the default value of the Status enum.

Variables

View Source
var (
	Hooks [1]ent.Hook
	// UsernameValidator is a validator for the "username" field. It is called by the builders before save.
	UsernameValidator func(string) error
	// EmailValidator is a validator for the "email" field. It is called by the builders before save.
	EmailValidator func(string) error
	// PhoneValidator is a validator for the "phone" field. It is called by the builders before save.
	PhoneValidator func(string) error
	// DefaultLanguage holds the default value on creation for the "language" field.
	DefaultLanguage string
	// LanguageValidator is a validator for the "language" field. It is called by the builders before save.
	LanguageValidator func(string) error
	// DefaultTimezone holds the default value on creation for the "timezone" field.
	DefaultTimezone string
	// TimezoneValidator is a validator for the "timezone" field. It is called by the builders before save.
	TimezoneValidator func(string) error
	// DefaultCreatedAt holds the default value on creation for the "created_at" field.
	DefaultCreatedAt func() time.Time
	// DefaultUpdatedAt holds the default value on creation for the "updated_at" field.
	DefaultUpdatedAt func() time.Time
	// UpdateDefaultUpdatedAt holds the default value on update for the "updated_at" field.
	UpdateDefaultUpdatedAt func() time.Time
	// DefaultID holds the default value on creation for the "id" field.
	DefaultID func() int64
)

Note that the variables below are initialized by the runtime package on the initialization of the application. Therefore, it should be imported in the main as follows:

import _ "github.com/yc-alpha/admin/ent/runtime"

Columns holds all SQL columns for user fields.

Functions

func And

func And(predicates ...predicate.User) predicate.User

And groups predicates with the AND operator between them.

func Avatar

func Avatar(v string) predicate.User

Avatar applies equality check predicate on the "avatar" field. It's identical to AvatarEQ.

func AvatarContains

func AvatarContains(v string) predicate.User

AvatarContains applies the Contains predicate on the "avatar" field.

func AvatarContainsFold

func AvatarContainsFold(v string) predicate.User

AvatarContainsFold applies the ContainsFold predicate on the "avatar" field.

func AvatarEQ

func AvatarEQ(v string) predicate.User

AvatarEQ applies the EQ predicate on the "avatar" field.

func AvatarEqualFold

func AvatarEqualFold(v string) predicate.User

AvatarEqualFold applies the EqualFold predicate on the "avatar" field.

func AvatarGT

func AvatarGT(v string) predicate.User

AvatarGT applies the GT predicate on the "avatar" field.

func AvatarGTE

func AvatarGTE(v string) predicate.User

AvatarGTE applies the GTE predicate on the "avatar" field.

func AvatarHasPrefix

func AvatarHasPrefix(v string) predicate.User

AvatarHasPrefix applies the HasPrefix predicate on the "avatar" field.

func AvatarHasSuffix

func AvatarHasSuffix(v string) predicate.User

AvatarHasSuffix applies the HasSuffix predicate on the "avatar" field.

func AvatarIn

func AvatarIn(vs ...string) predicate.User

AvatarIn applies the In predicate on the "avatar" field.

func AvatarIsNil

func AvatarIsNil() predicate.User

AvatarIsNil applies the IsNil predicate on the "avatar" field.

func AvatarLT

func AvatarLT(v string) predicate.User

AvatarLT applies the LT predicate on the "avatar" field.

func AvatarLTE

func AvatarLTE(v string) predicate.User

AvatarLTE applies the LTE predicate on the "avatar" field.

func AvatarNEQ

func AvatarNEQ(v string) predicate.User

AvatarNEQ applies the NEQ predicate on the "avatar" field.

func AvatarNotIn

func AvatarNotIn(vs ...string) predicate.User

AvatarNotIn applies the NotIn predicate on the "avatar" field.

func AvatarNotNil

func AvatarNotNil() predicate.User

AvatarNotNil applies the NotNil predicate on the "avatar" field.

func CreatedAt

func CreatedAt(v time.Time) predicate.User

CreatedAt applies equality check predicate on the "created_at" field. It's identical to CreatedAtEQ.

func CreatedAtEQ

func CreatedAtEQ(v time.Time) predicate.User

CreatedAtEQ applies the EQ predicate on the "created_at" field.

func CreatedAtGT

func CreatedAtGT(v time.Time) predicate.User

CreatedAtGT applies the GT predicate on the "created_at" field.

func CreatedAtGTE

func CreatedAtGTE(v time.Time) predicate.User

CreatedAtGTE applies the GTE predicate on the "created_at" field.

func CreatedAtIn

func CreatedAtIn(vs ...time.Time) predicate.User

CreatedAtIn applies the In predicate on the "created_at" field.

func CreatedAtLT

func CreatedAtLT(v time.Time) predicate.User

CreatedAtLT applies the LT predicate on the "created_at" field.

func CreatedAtLTE

func CreatedAtLTE(v time.Time) predicate.User

CreatedAtLTE applies the LTE predicate on the "created_at" field.

func CreatedAtNEQ

func CreatedAtNEQ(v time.Time) predicate.User

CreatedAtNEQ applies the NEQ predicate on the "created_at" field.

func CreatedAtNotIn

func CreatedAtNotIn(vs ...time.Time) predicate.User

CreatedAtNotIn applies the NotIn predicate on the "created_at" field.

func CreatedBy

func CreatedBy(v int64) predicate.User

CreatedBy applies equality check predicate on the "created_by" field. It's identical to CreatedByEQ.

func CreatedByEQ

func CreatedByEQ(v int64) predicate.User

CreatedByEQ applies the EQ predicate on the "created_by" field.

func CreatedByGT

func CreatedByGT(v int64) predicate.User

CreatedByGT applies the GT predicate on the "created_by" field.

func CreatedByGTE

func CreatedByGTE(v int64) predicate.User

CreatedByGTE applies the GTE predicate on the "created_by" field.

func CreatedByIn

func CreatedByIn(vs ...int64) predicate.User

CreatedByIn applies the In predicate on the "created_by" field.

func CreatedByIsNil

func CreatedByIsNil() predicate.User

CreatedByIsNil applies the IsNil predicate on the "created_by" field.

func CreatedByLT

func CreatedByLT(v int64) predicate.User

CreatedByLT applies the LT predicate on the "created_by" field.

func CreatedByLTE

func CreatedByLTE(v int64) predicate.User

CreatedByLTE applies the LTE predicate on the "created_by" field.

func CreatedByNEQ

func CreatedByNEQ(v int64) predicate.User

CreatedByNEQ applies the NEQ predicate on the "created_by" field.

func CreatedByNotIn

func CreatedByNotIn(vs ...int64) predicate.User

CreatedByNotIn applies the NotIn predicate on the "created_by" field.

func CreatedByNotNil

func CreatedByNotNil() predicate.User

CreatedByNotNil applies the NotNil predicate on the "created_by" field.

func DeletedAt

func DeletedAt(v time.Time) predicate.User

DeletedAt applies equality check predicate on the "deleted_at" field. It's identical to DeletedAtEQ.

func DeletedAtEQ

func DeletedAtEQ(v time.Time) predicate.User

DeletedAtEQ applies the EQ predicate on the "deleted_at" field.

func DeletedAtGT

func DeletedAtGT(v time.Time) predicate.User

DeletedAtGT applies the GT predicate on the "deleted_at" field.

func DeletedAtGTE

func DeletedAtGTE(v time.Time) predicate.User

DeletedAtGTE applies the GTE predicate on the "deleted_at" field.

func DeletedAtIn

func DeletedAtIn(vs ...time.Time) predicate.User

DeletedAtIn applies the In predicate on the "deleted_at" field.

func DeletedAtIsNil

func DeletedAtIsNil() predicate.User

DeletedAtIsNil applies the IsNil predicate on the "deleted_at" field.

func DeletedAtLT

func DeletedAtLT(v time.Time) predicate.User

DeletedAtLT applies the LT predicate on the "deleted_at" field.

func DeletedAtLTE

func DeletedAtLTE(v time.Time) predicate.User

DeletedAtLTE applies the LTE predicate on the "deleted_at" field.

func DeletedAtNEQ

func DeletedAtNEQ(v time.Time) predicate.User

DeletedAtNEQ applies the NEQ predicate on the "deleted_at" field.

func DeletedAtNotIn

func DeletedAtNotIn(vs ...time.Time) predicate.User

DeletedAtNotIn applies the NotIn predicate on the "deleted_at" field.

func DeletedAtNotNil

func DeletedAtNotNil() predicate.User

DeletedAtNotNil applies the NotNil predicate on the "deleted_at" field.

func Email

func Email(v string) predicate.User

Email applies equality check predicate on the "email" field. It's identical to EmailEQ.

func EmailContains

func EmailContains(v string) predicate.User

EmailContains applies the Contains predicate on the "email" field.

func EmailContainsFold

func EmailContainsFold(v string) predicate.User

EmailContainsFold applies the ContainsFold predicate on the "email" field.

func EmailEQ

func EmailEQ(v string) predicate.User

EmailEQ applies the EQ predicate on the "email" field.

func EmailEqualFold

func EmailEqualFold(v string) predicate.User

EmailEqualFold applies the EqualFold predicate on the "email" field.

func EmailGT

func EmailGT(v string) predicate.User

EmailGT applies the GT predicate on the "email" field.

func EmailGTE

func EmailGTE(v string) predicate.User

EmailGTE applies the GTE predicate on the "email" field.

func EmailHasPrefix

func EmailHasPrefix(v string) predicate.User

EmailHasPrefix applies the HasPrefix predicate on the "email" field.

func EmailHasSuffix

func EmailHasSuffix(v string) predicate.User

EmailHasSuffix applies the HasSuffix predicate on the "email" field.

func EmailIn

func EmailIn(vs ...string) predicate.User

EmailIn applies the In predicate on the "email" field.

func EmailIsNil

func EmailIsNil() predicate.User

EmailIsNil applies the IsNil predicate on the "email" field.

func EmailLT

func EmailLT(v string) predicate.User

EmailLT applies the LT predicate on the "email" field.

func EmailLTE

func EmailLTE(v string) predicate.User

EmailLTE applies the LTE predicate on the "email" field.

func EmailNEQ

func EmailNEQ(v string) predicate.User

EmailNEQ applies the NEQ predicate on the "email" field.

func EmailNotIn

func EmailNotIn(vs ...string) predicate.User

EmailNotIn applies the NotIn predicate on the "email" field.

func EmailNotNil

func EmailNotNil() predicate.User

EmailNotNil applies the NotNil predicate on the "email" field.

func FullName

func FullName(v string) predicate.User

FullName applies equality check predicate on the "full_name" field. It's identical to FullNameEQ.

func FullNameContains

func FullNameContains(v string) predicate.User

FullNameContains applies the Contains predicate on the "full_name" field.

func FullNameContainsFold

func FullNameContainsFold(v string) predicate.User

FullNameContainsFold applies the ContainsFold predicate on the "full_name" field.

func FullNameEQ

func FullNameEQ(v string) predicate.User

FullNameEQ applies the EQ predicate on the "full_name" field.

func FullNameEqualFold

func FullNameEqualFold(v string) predicate.User

FullNameEqualFold applies the EqualFold predicate on the "full_name" field.

func FullNameGT

func FullNameGT(v string) predicate.User

FullNameGT applies the GT predicate on the "full_name" field.

func FullNameGTE

func FullNameGTE(v string) predicate.User

FullNameGTE applies the GTE predicate on the "full_name" field.

func FullNameHasPrefix

func FullNameHasPrefix(v string) predicate.User

FullNameHasPrefix applies the HasPrefix predicate on the "full_name" field.

func FullNameHasSuffix

func FullNameHasSuffix(v string) predicate.User

FullNameHasSuffix applies the HasSuffix predicate on the "full_name" field.

func FullNameIn

func FullNameIn(vs ...string) predicate.User

FullNameIn applies the In predicate on the "full_name" field.

func FullNameIsNil

func FullNameIsNil() predicate.User

FullNameIsNil applies the IsNil predicate on the "full_name" field.

func FullNameLT

func FullNameLT(v string) predicate.User

FullNameLT applies the LT predicate on the "full_name" field.

func FullNameLTE

func FullNameLTE(v string) predicate.User

FullNameLTE applies the LTE predicate on the "full_name" field.

func FullNameNEQ

func FullNameNEQ(v string) predicate.User

FullNameNEQ applies the NEQ predicate on the "full_name" field.

func FullNameNotIn

func FullNameNotIn(vs ...string) predicate.User

FullNameNotIn applies the NotIn predicate on the "full_name" field.

func FullNameNotNil

func FullNameNotNil() predicate.User

FullNameNotNil applies the NotNil predicate on the "full_name" field.

func GenderEQ

func GenderEQ(v Gender) predicate.User

GenderEQ applies the EQ predicate on the "gender" field.

func GenderIn

func GenderIn(vs ...Gender) predicate.User

GenderIn applies the In predicate on the "gender" field.

func GenderNEQ

func GenderNEQ(v Gender) predicate.User

GenderNEQ applies the NEQ predicate on the "gender" field.

func GenderNotIn

func GenderNotIn(vs ...Gender) predicate.User

GenderNotIn applies the NotIn predicate on the "gender" field.

func GenderValidator

func GenderValidator(ge Gender) error

GenderValidator is a validator for the "gender" field enum values. It is called by the builders before save.

func HasAccounts

func HasAccounts() predicate.User

HasAccounts applies the HasEdge predicate on the "accounts" edge.

func HasAccountsWith

func HasAccountsWith(preds ...predicate.UserAccount) predicate.User

HasAccountsWith applies the HasEdge predicate on the "accounts" edge with a given conditions (other predicates).

func HasUserDepartments

func HasUserDepartments() predicate.User

HasUserDepartments applies the HasEdge predicate on the "user_departments" edge.

func HasUserDepartmentsWith

func HasUserDepartmentsWith(preds ...predicate.UserDepartment) predicate.User

HasUserDepartmentsWith applies the HasEdge predicate on the "user_departments" edge with a given conditions (other predicates).

func HasUserRoles

func HasUserRoles() predicate.User

HasUserRoles applies the HasEdge predicate on the "user_roles" edge.

func HasUserRolesWith

func HasUserRolesWith(preds ...predicate.UserRole) predicate.User

HasUserRolesWith applies the HasEdge predicate on the "user_roles" edge with a given conditions (other predicates).

func HasUserTenants

func HasUserTenants() predicate.User

HasUserTenants applies the HasEdge predicate on the "user_tenants" edge.

func HasUserTenantsWith

func HasUserTenantsWith(preds ...predicate.UserTenant) predicate.User

HasUserTenantsWith applies the HasEdge predicate on the "user_tenants" edge with a given conditions (other predicates).

func ID

func ID(id int64) predicate.User

ID filters vertices based on their ID field.

func IDEQ

func IDEQ(id int64) predicate.User

IDEQ applies the EQ predicate on the ID field.

func IDGT

func IDGT(id int64) predicate.User

IDGT applies the GT predicate on the ID field.

func IDGTE

func IDGTE(id int64) predicate.User

IDGTE applies the GTE predicate on the ID field.

func IDIn

func IDIn(ids ...int64) predicate.User

IDIn applies the In predicate on the ID field.

func IDLT

func IDLT(id int64) predicate.User

IDLT applies the LT predicate on the ID field.

func IDLTE

func IDLTE(id int64) predicate.User

IDLTE applies the LTE predicate on the ID field.

func IDNEQ

func IDNEQ(id int64) predicate.User

IDNEQ applies the NEQ predicate on the ID field.

func IDNotIn

func IDNotIn(ids ...int64) predicate.User

IDNotIn applies the NotIn predicate on the ID field.

func Language

func Language(v string) predicate.User

Language applies equality check predicate on the "language" field. It's identical to LanguageEQ.

func LanguageContains

func LanguageContains(v string) predicate.User

LanguageContains applies the Contains predicate on the "language" field.

func LanguageContainsFold

func LanguageContainsFold(v string) predicate.User

LanguageContainsFold applies the ContainsFold predicate on the "language" field.

func LanguageEQ

func LanguageEQ(v string) predicate.User

LanguageEQ applies the EQ predicate on the "language" field.

func LanguageEqualFold

func LanguageEqualFold(v string) predicate.User

LanguageEqualFold applies the EqualFold predicate on the "language" field.

func LanguageGT

func LanguageGT(v string) predicate.User

LanguageGT applies the GT predicate on the "language" field.

func LanguageGTE

func LanguageGTE(v string) predicate.User

LanguageGTE applies the GTE predicate on the "language" field.

func LanguageHasPrefix

func LanguageHasPrefix(v string) predicate.User

LanguageHasPrefix applies the HasPrefix predicate on the "language" field.

func LanguageHasSuffix

func LanguageHasSuffix(v string) predicate.User

LanguageHasSuffix applies the HasSuffix predicate on the "language" field.

func LanguageIn

func LanguageIn(vs ...string) predicate.User

LanguageIn applies the In predicate on the "language" field.

func LanguageLT

func LanguageLT(v string) predicate.User

LanguageLT applies the LT predicate on the "language" field.

func LanguageLTE

func LanguageLTE(v string) predicate.User

LanguageLTE applies the LTE predicate on the "language" field.

func LanguageNEQ

func LanguageNEQ(v string) predicate.User

LanguageNEQ applies the NEQ predicate on the "language" field.

func LanguageNotIn

func LanguageNotIn(vs ...string) predicate.User

LanguageNotIn applies the NotIn predicate on the "language" field.

func Not

Not applies the not operator on the given predicate.

func Or

func Or(predicates ...predicate.User) predicate.User

Or groups predicates with the OR operator between them.

func Password

func Password(v string) predicate.User

Password applies equality check predicate on the "password" field. It's identical to PasswordEQ.

func PasswordContains

func PasswordContains(v string) predicate.User

PasswordContains applies the Contains predicate on the "password" field.

func PasswordContainsFold

func PasswordContainsFold(v string) predicate.User

PasswordContainsFold applies the ContainsFold predicate on the "password" field.

func PasswordEQ

func PasswordEQ(v string) predicate.User

PasswordEQ applies the EQ predicate on the "password" field.

func PasswordEqualFold

func PasswordEqualFold(v string) predicate.User

PasswordEqualFold applies the EqualFold predicate on the "password" field.

func PasswordGT

func PasswordGT(v string) predicate.User

PasswordGT applies the GT predicate on the "password" field.

func PasswordGTE

func PasswordGTE(v string) predicate.User

PasswordGTE applies the GTE predicate on the "password" field.

func PasswordHasPrefix

func PasswordHasPrefix(v string) predicate.User

PasswordHasPrefix applies the HasPrefix predicate on the "password" field.

func PasswordHasSuffix

func PasswordHasSuffix(v string) predicate.User

PasswordHasSuffix applies the HasSuffix predicate on the "password" field.

func PasswordIn

func PasswordIn(vs ...string) predicate.User

PasswordIn applies the In predicate on the "password" field.

func PasswordIsNil

func PasswordIsNil() predicate.User

PasswordIsNil applies the IsNil predicate on the "password" field.

func PasswordLT

func PasswordLT(v string) predicate.User

PasswordLT applies the LT predicate on the "password" field.

func PasswordLTE

func PasswordLTE(v string) predicate.User

PasswordLTE applies the LTE predicate on the "password" field.

func PasswordNEQ

func PasswordNEQ(v string) predicate.User

PasswordNEQ applies the NEQ predicate on the "password" field.

func PasswordNotIn

func PasswordNotIn(vs ...string) predicate.User

PasswordNotIn applies the NotIn predicate on the "password" field.

func PasswordNotNil

func PasswordNotNil() predicate.User

PasswordNotNil applies the NotNil predicate on the "password" field.

func Phone

func Phone(v string) predicate.User

Phone applies equality check predicate on the "phone" field. It's identical to PhoneEQ.

func PhoneContains

func PhoneContains(v string) predicate.User

PhoneContains applies the Contains predicate on the "phone" field.

func PhoneContainsFold

func PhoneContainsFold(v string) predicate.User

PhoneContainsFold applies the ContainsFold predicate on the "phone" field.

func PhoneEQ

func PhoneEQ(v string) predicate.User

PhoneEQ applies the EQ predicate on the "phone" field.

func PhoneEqualFold

func PhoneEqualFold(v string) predicate.User

PhoneEqualFold applies the EqualFold predicate on the "phone" field.

func PhoneGT

func PhoneGT(v string) predicate.User

PhoneGT applies the GT predicate on the "phone" field.

func PhoneGTE

func PhoneGTE(v string) predicate.User

PhoneGTE applies the GTE predicate on the "phone" field.

func PhoneHasPrefix

func PhoneHasPrefix(v string) predicate.User

PhoneHasPrefix applies the HasPrefix predicate on the "phone" field.

func PhoneHasSuffix

func PhoneHasSuffix(v string) predicate.User

PhoneHasSuffix applies the HasSuffix predicate on the "phone" field.

func PhoneIn

func PhoneIn(vs ...string) predicate.User

PhoneIn applies the In predicate on the "phone" field.

func PhoneIsNil

func PhoneIsNil() predicate.User

PhoneIsNil applies the IsNil predicate on the "phone" field.

func PhoneLT

func PhoneLT(v string) predicate.User

PhoneLT applies the LT predicate on the "phone" field.

func PhoneLTE

func PhoneLTE(v string) predicate.User

PhoneLTE applies the LTE predicate on the "phone" field.

func PhoneNEQ

func PhoneNEQ(v string) predicate.User

PhoneNEQ applies the NEQ predicate on the "phone" field.

func PhoneNotIn

func PhoneNotIn(vs ...string) predicate.User

PhoneNotIn applies the NotIn predicate on the "phone" field.

func PhoneNotNil

func PhoneNotNil() predicate.User

PhoneNotNil applies the NotNil predicate on the "phone" field.

func StatusEQ

func StatusEQ(v Status) predicate.User

StatusEQ applies the EQ predicate on the "status" field.

func StatusIn

func StatusIn(vs ...Status) predicate.User

StatusIn applies the In predicate on the "status" field.

func StatusNEQ

func StatusNEQ(v Status) predicate.User

StatusNEQ applies the NEQ predicate on the "status" field.

func StatusNotIn

func StatusNotIn(vs ...Status) predicate.User

StatusNotIn applies the NotIn predicate on the "status" field.

func StatusValidator

func StatusValidator(s Status) error

StatusValidator is a validator for the "status" field enum values. It is called by the builders before save.

func Timezone

func Timezone(v string) predicate.User

Timezone applies equality check predicate on the "timezone" field. It's identical to TimezoneEQ.

func TimezoneContains

func TimezoneContains(v string) predicate.User

TimezoneContains applies the Contains predicate on the "timezone" field.

func TimezoneContainsFold

func TimezoneContainsFold(v string) predicate.User

TimezoneContainsFold applies the ContainsFold predicate on the "timezone" field.

func TimezoneEQ

func TimezoneEQ(v string) predicate.User

TimezoneEQ applies the EQ predicate on the "timezone" field.

func TimezoneEqualFold

func TimezoneEqualFold(v string) predicate.User

TimezoneEqualFold applies the EqualFold predicate on the "timezone" field.

func TimezoneGT

func TimezoneGT(v string) predicate.User

TimezoneGT applies the GT predicate on the "timezone" field.

func TimezoneGTE

func TimezoneGTE(v string) predicate.User

TimezoneGTE applies the GTE predicate on the "timezone" field.

func TimezoneHasPrefix

func TimezoneHasPrefix(v string) predicate.User

TimezoneHasPrefix applies the HasPrefix predicate on the "timezone" field.

func TimezoneHasSuffix

func TimezoneHasSuffix(v string) predicate.User

TimezoneHasSuffix applies the HasSuffix predicate on the "timezone" field.

func TimezoneIn

func TimezoneIn(vs ...string) predicate.User

TimezoneIn applies the In predicate on the "timezone" field.

func TimezoneLT

func TimezoneLT(v string) predicate.User

TimezoneLT applies the LT predicate on the "timezone" field.

func TimezoneLTE

func TimezoneLTE(v string) predicate.User

TimezoneLTE applies the LTE predicate on the "timezone" field.

func TimezoneNEQ

func TimezoneNEQ(v string) predicate.User

TimezoneNEQ applies the NEQ predicate on the "timezone" field.

func TimezoneNotIn

func TimezoneNotIn(vs ...string) predicate.User

TimezoneNotIn applies the NotIn predicate on the "timezone" field.

func UpdatedAt

func UpdatedAt(v time.Time) predicate.User

UpdatedAt applies equality check predicate on the "updated_at" field. It's identical to UpdatedAtEQ.

func UpdatedAtEQ

func UpdatedAtEQ(v time.Time) predicate.User

UpdatedAtEQ applies the EQ predicate on the "updated_at" field.

func UpdatedAtGT

func UpdatedAtGT(v time.Time) predicate.User

UpdatedAtGT applies the GT predicate on the "updated_at" field.

func UpdatedAtGTE

func UpdatedAtGTE(v time.Time) predicate.User

UpdatedAtGTE applies the GTE predicate on the "updated_at" field.

func UpdatedAtIn

func UpdatedAtIn(vs ...time.Time) predicate.User

UpdatedAtIn applies the In predicate on the "updated_at" field.

func UpdatedAtLT

func UpdatedAtLT(v time.Time) predicate.User

UpdatedAtLT applies the LT predicate on the "updated_at" field.

func UpdatedAtLTE

func UpdatedAtLTE(v time.Time) predicate.User

UpdatedAtLTE applies the LTE predicate on the "updated_at" field.

func UpdatedAtNEQ

func UpdatedAtNEQ(v time.Time) predicate.User

UpdatedAtNEQ applies the NEQ predicate on the "updated_at" field.

func UpdatedAtNotIn

func UpdatedAtNotIn(vs ...time.Time) predicate.User

UpdatedAtNotIn applies the NotIn predicate on the "updated_at" field.

func UpdatedBy

func UpdatedBy(v int64) predicate.User

UpdatedBy applies equality check predicate on the "updated_by" field. It's identical to UpdatedByEQ.

func UpdatedByEQ

func UpdatedByEQ(v int64) predicate.User

UpdatedByEQ applies the EQ predicate on the "updated_by" field.

func UpdatedByGT

func UpdatedByGT(v int64) predicate.User

UpdatedByGT applies the GT predicate on the "updated_by" field.

func UpdatedByGTE

func UpdatedByGTE(v int64) predicate.User

UpdatedByGTE applies the GTE predicate on the "updated_by" field.

func UpdatedByIn

func UpdatedByIn(vs ...int64) predicate.User

UpdatedByIn applies the In predicate on the "updated_by" field.

func UpdatedByIsNil

func UpdatedByIsNil() predicate.User

UpdatedByIsNil applies the IsNil predicate on the "updated_by" field.

func UpdatedByLT

func UpdatedByLT(v int64) predicate.User

UpdatedByLT applies the LT predicate on the "updated_by" field.

func UpdatedByLTE

func UpdatedByLTE(v int64) predicate.User

UpdatedByLTE applies the LTE predicate on the "updated_by" field.

func UpdatedByNEQ

func UpdatedByNEQ(v int64) predicate.User

UpdatedByNEQ applies the NEQ predicate on the "updated_by" field.

func UpdatedByNotIn

func UpdatedByNotIn(vs ...int64) predicate.User

UpdatedByNotIn applies the NotIn predicate on the "updated_by" field.

func UpdatedByNotNil

func UpdatedByNotNil() predicate.User

UpdatedByNotNil applies the NotNil predicate on the "updated_by" field.

func Username

func Username(v string) predicate.User

Username applies equality check predicate on the "username" field. It's identical to UsernameEQ.

func UsernameContains

func UsernameContains(v string) predicate.User

UsernameContains applies the Contains predicate on the "username" field.

func UsernameContainsFold

func UsernameContainsFold(v string) predicate.User

UsernameContainsFold applies the ContainsFold predicate on the "username" field.

func UsernameEQ

func UsernameEQ(v string) predicate.User

UsernameEQ applies the EQ predicate on the "username" field.

func UsernameEqualFold

func UsernameEqualFold(v string) predicate.User

UsernameEqualFold applies the EqualFold predicate on the "username" field.

func UsernameGT

func UsernameGT(v string) predicate.User

UsernameGT applies the GT predicate on the "username" field.

func UsernameGTE

func UsernameGTE(v string) predicate.User

UsernameGTE applies the GTE predicate on the "username" field.

func UsernameHasPrefix

func UsernameHasPrefix(v string) predicate.User

UsernameHasPrefix applies the HasPrefix predicate on the "username" field.

func UsernameHasSuffix

func UsernameHasSuffix(v string) predicate.User

UsernameHasSuffix applies the HasSuffix predicate on the "username" field.

func UsernameIn

func UsernameIn(vs ...string) predicate.User

UsernameIn applies the In predicate on the "username" field.

func UsernameLT

func UsernameLT(v string) predicate.User

UsernameLT applies the LT predicate on the "username" field.

func UsernameLTE

func UsernameLTE(v string) predicate.User

UsernameLTE applies the LTE predicate on the "username" field.

func UsernameNEQ

func UsernameNEQ(v string) predicate.User

UsernameNEQ applies the NEQ predicate on the "username" field.

func UsernameNotIn

func UsernameNotIn(vs ...string) predicate.User

UsernameNotIn applies the NotIn predicate on the "username" field.

func ValidColumn

func ValidColumn(column string) bool

ValidColumn reports if the column name is valid (part of the table columns).

Types

type Gender

type Gender string

Gender defines the type for the "gender" enum field.

const (
	GenderMALE    Gender = "MALE"
	GenderFEMALE  Gender = "FEMALE"
	GenderUNKNOWN Gender = "UNKNOWN"
)

Gender values.

func (Gender) String

func (ge Gender) String() string

type OrderOption

type OrderOption func(*sql.Selector)

OrderOption defines the ordering options for the User queries.

func ByAccounts

func ByAccounts(term sql.OrderTerm, terms ...sql.OrderTerm) OrderOption

ByAccounts orders the results by accounts terms.

func ByAccountsCount

func ByAccountsCount(opts ...sql.OrderTermOption) OrderOption

ByAccountsCount orders the results by accounts count.

func ByAvatar

func ByAvatar(opts ...sql.OrderTermOption) OrderOption

ByAvatar orders the results by the avatar field.

func ByCreatedAt

func ByCreatedAt(opts ...sql.OrderTermOption) OrderOption

ByCreatedAt orders the results by the created_at field.

func ByCreatedBy

func ByCreatedBy(opts ...sql.OrderTermOption) OrderOption

ByCreatedBy orders the results by the created_by field.

func ByDeletedAt

func ByDeletedAt(opts ...sql.OrderTermOption) OrderOption

ByDeletedAt orders the results by the deleted_at field.

func ByEmail

func ByEmail(opts ...sql.OrderTermOption) OrderOption

ByEmail orders the results by the email field.

func ByFullName

func ByFullName(opts ...sql.OrderTermOption) OrderOption

ByFullName orders the results by the full_name field.

func ByGender

func ByGender(opts ...sql.OrderTermOption) OrderOption

ByGender orders the results by the gender field.

func ByID

func ByID(opts ...sql.OrderTermOption) OrderOption

ByID orders the results by the id field.

func ByLanguage

func ByLanguage(opts ...sql.OrderTermOption) OrderOption

ByLanguage orders the results by the language field.

func ByPassword

func ByPassword(opts ...sql.OrderTermOption) OrderOption

ByPassword orders the results by the password field.

func ByPhone

func ByPhone(opts ...sql.OrderTermOption) OrderOption

ByPhone orders the results by the phone field.

func ByStatus

func ByStatus(opts ...sql.OrderTermOption) OrderOption

ByStatus orders the results by the status field.

func ByTimezone

func ByTimezone(opts ...sql.OrderTermOption) OrderOption

ByTimezone orders the results by the timezone field.

func ByUpdatedAt

func ByUpdatedAt(opts ...sql.OrderTermOption) OrderOption

ByUpdatedAt orders the results by the updated_at field.

func ByUpdatedBy

func ByUpdatedBy(opts ...sql.OrderTermOption) OrderOption

ByUpdatedBy orders the results by the updated_by field.

func ByUserDepartments

func ByUserDepartments(term sql.OrderTerm, terms ...sql.OrderTerm) OrderOption

ByUserDepartments orders the results by user_departments terms.

func ByUserDepartmentsCount

func ByUserDepartmentsCount(opts ...sql.OrderTermOption) OrderOption

ByUserDepartmentsCount orders the results by user_departments count.

func ByUserRoles

func ByUserRoles(term sql.OrderTerm, terms ...sql.OrderTerm) OrderOption

ByUserRoles orders the results by user_roles terms.

func ByUserRolesCount

func ByUserRolesCount(opts ...sql.OrderTermOption) OrderOption

ByUserRolesCount orders the results by user_roles count.

func ByUserTenants

func ByUserTenants(term sql.OrderTerm, terms ...sql.OrderTerm) OrderOption

ByUserTenants orders the results by user_tenants terms.

func ByUserTenantsCount

func ByUserTenantsCount(opts ...sql.OrderTermOption) OrderOption

ByUserTenantsCount orders the results by user_tenants count.

func ByUsername

func ByUsername(opts ...sql.OrderTermOption) OrderOption

ByUsername orders the results by the username field.

type Status

type Status string

Status defines the type for the "status" enum field.

const (
	StatusACTIVE   Status = "ACTIVE"
	StatusDISABLED Status = "DISABLED"
	StatusPENDING  Status = "PENDING"
)

Status values.

func (Status) String

func (s Status) String() string

Jump to

Keyboard shortcuts

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