Documentation ¶
Index ¶
- Constants
- Variables
- func AccessTypeEQ(v AccessType) predicate.User
- func AccessTypeIn(vs ...AccessType) predicate.User
- func AccessTypeNEQ(v AccessType) predicate.User
- func AccessTypeNotIn(vs ...AccessType) predicate.User
- func AccessTypeValidator(at AccessType) error
- func And(predicates ...predicate.User) predicate.User
- func CreatedAt(v time.Time) predicate.User
- func CreatedAtEQ(v time.Time) predicate.User
- func CreatedAtGT(v time.Time) predicate.User
- func CreatedAtGTE(v time.Time) predicate.User
- func CreatedAtIn(vs ...time.Time) predicate.User
- func CreatedAtIsNil() predicate.User
- func CreatedAtLT(v time.Time) predicate.User
- func CreatedAtLTE(v time.Time) predicate.User
- func CreatedAtNEQ(v time.Time) predicate.User
- func CreatedAtNotIn(vs ...time.Time) predicate.User
- func CreatedAtNotNil() predicate.User
- func Email(v string) predicate.User
- func EmailContains(v string) predicate.User
- func EmailContainsFold(v string) predicate.User
- func EmailEQ(v string) predicate.User
- func EmailEqualFold(v string) predicate.User
- func EmailGT(v string) predicate.User
- func EmailGTE(v string) predicate.User
- func EmailHasPrefix(v string) predicate.User
- func EmailHasSuffix(v string) predicate.User
- func EmailIn(vs ...string) predicate.User
- func EmailIsNil() predicate.User
- func EmailLT(v string) predicate.User
- func EmailLTE(v string) predicate.User
- func EmailNEQ(v string) predicate.User
- func EmailNotIn(vs ...string) predicate.User
- func EmailNotNil() predicate.User
- func FirstName(v string) predicate.User
- func FirstNameContains(v string) predicate.User
- func FirstNameContainsFold(v string) predicate.User
- func FirstNameEQ(v string) predicate.User
- func FirstNameEqualFold(v string) predicate.User
- func FirstNameGT(v string) predicate.User
- func FirstNameGTE(v string) predicate.User
- func FirstNameHasPrefix(v string) predicate.User
- func FirstNameHasSuffix(v string) predicate.User
- func FirstNameIn(vs ...string) predicate.User
- func FirstNameLT(v string) predicate.User
- func FirstNameLTE(v string) predicate.User
- func FirstNameNEQ(v string) predicate.User
- func FirstNameNotIn(vs ...string) predicate.User
- func HasFiles() predicate.User
- func HasFilesWith(preds ...predicate.File) predicate.User
- func ID(id int) predicate.User
- func IDEQ(id int) predicate.User
- func IDGT(id int) predicate.User
- func IDGTE(id int) predicate.User
- func IDIn(ids ...int) predicate.User
- func IDLT(id int) predicate.User
- func IDLTE(id int) predicate.User
- func IDNEQ(id int) predicate.User
- func IDNotIn(ids ...int) predicate.User
- func LastLoginAt(v time.Time) predicate.User
- func LastLoginAtEQ(v time.Time) predicate.User
- func LastLoginAtGT(v time.Time) predicate.User
- func LastLoginAtGTE(v time.Time) predicate.User
- func LastLoginAtIn(vs ...time.Time) predicate.User
- func LastLoginAtIsNil() predicate.User
- func LastLoginAtLT(v time.Time) predicate.User
- func LastLoginAtLTE(v time.Time) predicate.User
- func LastLoginAtNEQ(v time.Time) predicate.User
- func LastLoginAtNotIn(vs ...time.Time) predicate.User
- func LastLoginAtNotNil() predicate.User
- func LastName(v string) predicate.User
- func LastNameContains(v string) predicate.User
- func LastNameContainsFold(v string) predicate.User
- func LastNameEQ(v string) predicate.User
- func LastNameEqualFold(v string) predicate.User
- func LastNameGT(v string) predicate.User
- func LastNameGTE(v string) predicate.User
- func LastNameHasPrefix(v string) predicate.User
- func LastNameHasSuffix(v string) predicate.User
- func LastNameIn(vs ...string) predicate.User
- func LastNameLT(v string) predicate.User
- func LastNameLTE(v string) predicate.User
- func LastNameNEQ(v string) predicate.User
- func LastNameNotIn(vs ...string) predicate.User
- func Not(p predicate.User) predicate.User
- func Or(predicates ...predicate.User) predicate.User
- func Password(v string) predicate.User
- func PasswordContains(v string) predicate.User
- func PasswordContainsFold(v string) predicate.User
- func PasswordEQ(v string) predicate.User
- func PasswordEqualFold(v string) predicate.User
- func PasswordGT(v string) predicate.User
- func PasswordGTE(v string) predicate.User
- func PasswordHasPrefix(v string) predicate.User
- func PasswordHasSuffix(v string) predicate.User
- func PasswordIn(vs ...string) predicate.User
- func PasswordLT(v string) predicate.User
- func PasswordLTE(v string) predicate.User
- func PasswordNEQ(v string) predicate.User
- func PasswordNotIn(vs ...string) predicate.User
- func UpdatedAt(v time.Time) predicate.User
- func UpdatedAtEQ(v time.Time) predicate.User
- func UpdatedAtGT(v time.Time) predicate.User
- func UpdatedAtGTE(v time.Time) predicate.User
- func UpdatedAtIn(vs ...time.Time) predicate.User
- func UpdatedAtLT(v time.Time) predicate.User
- func UpdatedAtLTE(v time.Time) predicate.User
- func UpdatedAtNEQ(v time.Time) predicate.User
- func UpdatedAtNotIn(vs ...time.Time) predicate.User
- func ValidColumn(column string) bool
- type AccessType
- type OrderOption
- func ByAccessType(opts ...sql.OrderTermOption) OrderOption
- func ByCreatedAt(opts ...sql.OrderTermOption) OrderOption
- func ByEmail(opts ...sql.OrderTermOption) OrderOption
- func ByFiles(term sql.OrderTerm, terms ...sql.OrderTerm) OrderOption
- func ByFilesCount(opts ...sql.OrderTermOption) OrderOption
- func ByFirstName(opts ...sql.OrderTermOption) OrderOption
- func ByID(opts ...sql.OrderTermOption) OrderOption
- func ByLastLoginAt(opts ...sql.OrderTermOption) OrderOption
- func ByLastName(opts ...sql.OrderTermOption) OrderOption
- func ByPassword(opts ...sql.OrderTermOption) OrderOption
- func ByUpdatedAt(opts ...sql.OrderTermOption) OrderOption
Constants ¶
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" // FieldFirstName holds the string denoting the first_name field in the database. FieldFirstName = "first_name" // FieldLastName holds the string denoting the last_name field in the database. FieldLastName = "last_name" // FieldEmail holds the string denoting the email field in the database. FieldEmail = "email" // FieldPassword holds the string denoting the password field in the database. FieldPassword = "password" // FieldAccessType holds the string denoting the access_type field in the database. FieldAccessType = "access_type" // 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" // FieldLastLoginAt holds the string denoting the last_login_at field in the database. FieldLastLoginAt = "last_login_at" // EdgeFiles holds the string denoting the files edge name in mutations. EdgeFiles = "files" // Table holds the table name of the user in the database. Table = "users" // FilesTable is the table that holds the files relation/edge. FilesTable = "files" // FilesInverseTable is the table name for the File entity. // It exists in this package in order to avoid circular dependency with the "file" package. FilesInverseTable = "files" // FilesColumn is the table column denoting the files relation/edge. FilesColumn = "user_id" )
const DefaultAccessType = AccessTypeCustomer
AccessTypeCustomer is the default value of the AccessType enum.
Variables ¶
var ( // FirstNameValidator is a validator for the "first_name" field. It is called by the builders before save. FirstNameValidator func(string) error // LastNameValidator is a validator for the "last_name" field. It is called by the builders before save. LastNameValidator func(string) error // EmailValidator is a validator for the "email" field. It is called by the builders before save. EmailValidator func(string) error // PasswordValidator is a validator for the "password" field. It is called by the builders before save. PasswordValidator 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 )
var Columns = []string{ FieldID, FieldFirstName, FieldLastName, FieldEmail, FieldPassword, FieldAccessType, FieldCreatedAt, FieldUpdatedAt, FieldLastLoginAt, }
Columns holds all SQL columns for user fields.
Functions ¶
func AccessTypeEQ ¶
func AccessTypeEQ(v AccessType) predicate.User
AccessTypeEQ applies the EQ predicate on the "access_type" field.
func AccessTypeIn ¶
func AccessTypeIn(vs ...AccessType) predicate.User
AccessTypeIn applies the In predicate on the "access_type" field.
func AccessTypeNEQ ¶
func AccessTypeNEQ(v AccessType) predicate.User
AccessTypeNEQ applies the NEQ predicate on the "access_type" field.
func AccessTypeNotIn ¶
func AccessTypeNotIn(vs ...AccessType) predicate.User
AccessTypeNotIn applies the NotIn predicate on the "access_type" field.
func AccessTypeValidator ¶
func AccessTypeValidator(at AccessType) error
AccessTypeValidator is a validator for the "access_type" field enum values. It is called by the builders before save.
func CreatedAt ¶
CreatedAt applies equality check predicate on the "created_at" field. It's identical to CreatedAtEQ.
func CreatedAtEQ ¶
CreatedAtEQ applies the EQ predicate on the "created_at" field.
func CreatedAtGT ¶
CreatedAtGT applies the GT predicate on the "created_at" field.
func CreatedAtGTE ¶
CreatedAtGTE applies the GTE predicate on the "created_at" field.
func CreatedAtIn ¶
CreatedAtIn applies the In predicate on the "created_at" field.
func CreatedAtIsNil ¶
CreatedAtIsNil applies the IsNil predicate on the "created_at" field.
func CreatedAtLT ¶
CreatedAtLT applies the LT predicate on the "created_at" field.
func CreatedAtLTE ¶
CreatedAtLTE applies the LTE predicate on the "created_at" field.
func CreatedAtNEQ ¶
CreatedAtNEQ applies the NEQ predicate on the "created_at" field.
func CreatedAtNotIn ¶
CreatedAtNotIn applies the NotIn predicate on the "created_at" field.
func CreatedAtNotNil ¶
CreatedAtNotNil applies the NotNil predicate on the "created_at" field.
func Email ¶
Email applies equality check predicate on the "email" field. It's identical to EmailEQ.
func EmailContains ¶
EmailContains applies the Contains predicate on the "email" field.
func EmailContainsFold ¶
EmailContainsFold applies the ContainsFold predicate on the "email" field.
func EmailEqualFold ¶
EmailEqualFold applies the EqualFold predicate on the "email" field.
func EmailHasPrefix ¶
EmailHasPrefix applies the HasPrefix predicate on the "email" field.
func EmailHasSuffix ¶
EmailHasSuffix applies the HasSuffix predicate on the "email" field.
func EmailIsNil ¶
EmailIsNil applies the IsNil predicate on the "email" field.
func EmailNotIn ¶
EmailNotIn applies the NotIn predicate on the "email" field.
func EmailNotNil ¶
EmailNotNil applies the NotNil predicate on the "email" field.
func FirstName ¶
FirstName applies equality check predicate on the "first_name" field. It's identical to FirstNameEQ.
func FirstNameContains ¶
FirstNameContains applies the Contains predicate on the "first_name" field.
func FirstNameContainsFold ¶
FirstNameContainsFold applies the ContainsFold predicate on the "first_name" field.
func FirstNameEQ ¶
FirstNameEQ applies the EQ predicate on the "first_name" field.
func FirstNameEqualFold ¶
FirstNameEqualFold applies the EqualFold predicate on the "first_name" field.
func FirstNameGT ¶
FirstNameGT applies the GT predicate on the "first_name" field.
func FirstNameGTE ¶
FirstNameGTE applies the GTE predicate on the "first_name" field.
func FirstNameHasPrefix ¶
FirstNameHasPrefix applies the HasPrefix predicate on the "first_name" field.
func FirstNameHasSuffix ¶
FirstNameHasSuffix applies the HasSuffix predicate on the "first_name" field.
func FirstNameIn ¶
FirstNameIn applies the In predicate on the "first_name" field.
func FirstNameLT ¶
FirstNameLT applies the LT predicate on the "first_name" field.
func FirstNameLTE ¶
FirstNameLTE applies the LTE predicate on the "first_name" field.
func FirstNameNEQ ¶
FirstNameNEQ applies the NEQ predicate on the "first_name" field.
func FirstNameNotIn ¶
FirstNameNotIn applies the NotIn predicate on the "first_name" field.
func HasFilesWith ¶
HasFilesWith applies the HasEdge predicate on the "files" edge with a given conditions (other predicates).
func LastLoginAt ¶
LastLoginAt applies equality check predicate on the "last_login_at" field. It's identical to LastLoginAtEQ.
func LastLoginAtEQ ¶
LastLoginAtEQ applies the EQ predicate on the "last_login_at" field.
func LastLoginAtGT ¶
LastLoginAtGT applies the GT predicate on the "last_login_at" field.
func LastLoginAtGTE ¶
LastLoginAtGTE applies the GTE predicate on the "last_login_at" field.
func LastLoginAtIn ¶
LastLoginAtIn applies the In predicate on the "last_login_at" field.
func LastLoginAtIsNil ¶
LastLoginAtIsNil applies the IsNil predicate on the "last_login_at" field.
func LastLoginAtLT ¶
LastLoginAtLT applies the LT predicate on the "last_login_at" field.
func LastLoginAtLTE ¶
LastLoginAtLTE applies the LTE predicate on the "last_login_at" field.
func LastLoginAtNEQ ¶
LastLoginAtNEQ applies the NEQ predicate on the "last_login_at" field.
func LastLoginAtNotIn ¶
LastLoginAtNotIn applies the NotIn predicate on the "last_login_at" field.
func LastLoginAtNotNil ¶
LastLoginAtNotNil applies the NotNil predicate on the "last_login_at" field.
func LastName ¶
LastName applies equality check predicate on the "last_name" field. It's identical to LastNameEQ.
func LastNameContains ¶
LastNameContains applies the Contains predicate on the "last_name" field.
func LastNameContainsFold ¶
LastNameContainsFold applies the ContainsFold predicate on the "last_name" field.
func LastNameEQ ¶
LastNameEQ applies the EQ predicate on the "last_name" field.
func LastNameEqualFold ¶
LastNameEqualFold applies the EqualFold predicate on the "last_name" field.
func LastNameGT ¶
LastNameGT applies the GT predicate on the "last_name" field.
func LastNameGTE ¶
LastNameGTE applies the GTE predicate on the "last_name" field.
func LastNameHasPrefix ¶
LastNameHasPrefix applies the HasPrefix predicate on the "last_name" field.
func LastNameHasSuffix ¶
LastNameHasSuffix applies the HasSuffix predicate on the "last_name" field.
func LastNameIn ¶
LastNameIn applies the In predicate on the "last_name" field.
func LastNameLT ¶
LastNameLT applies the LT predicate on the "last_name" field.
func LastNameLTE ¶
LastNameLTE applies the LTE predicate on the "last_name" field.
func LastNameNEQ ¶
LastNameNEQ applies the NEQ predicate on the "last_name" field.
func LastNameNotIn ¶
LastNameNotIn applies the NotIn predicate on the "last_name" field.
func Password ¶
Password applies equality check predicate on the "password" field. It's identical to PasswordEQ.
func PasswordContains ¶
PasswordContains applies the Contains predicate on the "password" field.
func PasswordContainsFold ¶
PasswordContainsFold applies the ContainsFold predicate on the "password" field.
func PasswordEQ ¶
PasswordEQ applies the EQ predicate on the "password" field.
func PasswordEqualFold ¶
PasswordEqualFold applies the EqualFold predicate on the "password" field.
func PasswordGT ¶
PasswordGT applies the GT predicate on the "password" field.
func PasswordGTE ¶
PasswordGTE applies the GTE predicate on the "password" field.
func PasswordHasPrefix ¶
PasswordHasPrefix applies the HasPrefix predicate on the "password" field.
func PasswordHasSuffix ¶
PasswordHasSuffix applies the HasSuffix predicate on the "password" field.
func PasswordIn ¶
PasswordIn applies the In predicate on the "password" field.
func PasswordLT ¶
PasswordLT applies the LT predicate on the "password" field.
func PasswordLTE ¶
PasswordLTE applies the LTE predicate on the "password" field.
func PasswordNEQ ¶
PasswordNEQ applies the NEQ predicate on the "password" field.
func PasswordNotIn ¶
PasswordNotIn applies the NotIn predicate on the "password" field.
func UpdatedAt ¶
UpdatedAt applies equality check predicate on the "updated_at" field. It's identical to UpdatedAtEQ.
func UpdatedAtEQ ¶
UpdatedAtEQ applies the EQ predicate on the "updated_at" field.
func UpdatedAtGT ¶
UpdatedAtGT applies the GT predicate on the "updated_at" field.
func UpdatedAtGTE ¶
UpdatedAtGTE applies the GTE predicate on the "updated_at" field.
func UpdatedAtIn ¶
UpdatedAtIn applies the In predicate on the "updated_at" field.
func UpdatedAtLT ¶
UpdatedAtLT applies the LT predicate on the "updated_at" field.
func UpdatedAtLTE ¶
UpdatedAtLTE applies the LTE predicate on the "updated_at" field.
func UpdatedAtNEQ ¶
UpdatedAtNEQ applies the NEQ predicate on the "updated_at" field.
func UpdatedAtNotIn ¶
UpdatedAtNotIn applies the NotIn predicate on the "updated_at" field.
func ValidColumn ¶
ValidColumn reports if the column name is valid (part of the table columns).
Types ¶
type AccessType ¶
type AccessType string
AccessType defines the type for the "access_type" enum field.
const ( AccessTypeAdmin AccessType = "Admin" AccessTypeCustomer AccessType = "Customer" )
AccessType values.
func (AccessType) String ¶
func (at AccessType) String() string
type OrderOption ¶
OrderOption defines the ordering options for the User queries.
func ByAccessType ¶
func ByAccessType(opts ...sql.OrderTermOption) OrderOption
ByAccessType orders the results by the access_type field.
func ByCreatedAt ¶
func ByCreatedAt(opts ...sql.OrderTermOption) OrderOption
ByCreatedAt orders the results by the created_at field.
func ByEmail ¶
func ByEmail(opts ...sql.OrderTermOption) OrderOption
ByEmail orders the results by the email field.
func ByFiles ¶
func ByFiles(term sql.OrderTerm, terms ...sql.OrderTerm) OrderOption
ByFiles orders the results by files terms.
func ByFilesCount ¶
func ByFilesCount(opts ...sql.OrderTermOption) OrderOption
ByFilesCount orders the results by files count.
func ByFirstName ¶
func ByFirstName(opts ...sql.OrderTermOption) OrderOption
ByFirstName orders the results by the first_name field.
func ByID ¶
func ByID(opts ...sql.OrderTermOption) OrderOption
ByID orders the results by the id field.
func ByLastLoginAt ¶
func ByLastLoginAt(opts ...sql.OrderTermOption) OrderOption
ByLastLoginAt orders the results by the last_login_at field.
func ByLastName ¶
func ByLastName(opts ...sql.OrderTermOption) OrderOption
ByLastName orders the results by the last_name field.
func ByPassword ¶
func ByPassword(opts ...sql.OrderTermOption) OrderOption
ByPassword orders the results by the password field.
func ByUpdatedAt ¶
func ByUpdatedAt(opts ...sql.OrderTermOption) OrderOption
ByUpdatedAt orders the results by the updated_at field.