role

package
v0.1.0 Latest Latest
Warning

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

Go to latest
Published: Feb 24, 2026 License: MIT Imports: 5 Imported by: 2

Documentation

Index

Constants

View Source
const (
	// Label holds the string label denoting the role type in the database.
	Label = "role"
	// FieldID holds the string denoting the id field in the database.
	FieldID = "id"
	// FieldCreatedByID holds the string denoting the created_by_id field in the database.
	FieldCreatedByID = "created_by_id"
	// FieldCreatedAt holds the string denoting the created_at field in the database.
	FieldCreatedAt = "created_at"
	// FieldUpdatedByID holds the string denoting the updated_by_id field in the database.
	FieldUpdatedByID = "updated_by_id"
	// FieldUpdatedAt holds the string denoting the updated_at field in the database.
	FieldUpdatedAt = "updated_at"
	// FieldDeletedByID holds the string denoting the deleted_by_id field in the database.
	FieldDeletedByID = "deleted_by_id"
	// FieldDeletedAt holds the string denoting the deleted_at field in the database.
	FieldDeletedAt = "deleted_at"
	// FieldPublishedAt holds the string denoting the published_at field in the database.
	FieldPublishedAt = "published_at"
	// FieldArchivedAt holds the string denoting the archived_at field in the database.
	FieldArchivedAt = "archived_at"
	// FieldOwnerDomainID holds the string denoting the owner_domain_id field in the database.
	FieldOwnerDomainID = "owner_domain_id"
	// FieldName holds the string denoting the name field in the database.
	FieldName = "name"
	// FieldCode holds the string denoting the code field in the database.
	FieldCode = "code"
	// FieldDescription holds the string denoting the description field in the database.
	FieldDescription = "description"
	// FieldSort holds the string denoting the sort field in the database.
	FieldSort = "sort"
	// FieldIsSystem holds the string denoting the is_system field in the database.
	FieldIsSystem = "is_system"
	// FieldPermissions holds the string denoting the permissions field in the database.
	FieldPermissions = "permissions"
	// FieldDefaultDataScope holds the string denoting the default_data_scope field in the database.
	FieldDefaultDataScope = "default_data_scope"
	// EdgeUsers holds the string denoting the users edge name in mutations.
	EdgeUsers = "users"
	// EdgeAPIKeys holds the string denoting the api_keys edge name in mutations.
	EdgeAPIKeys = "api_keys"
	// EdgeMenus holds the string denoting the menus edge name in mutations.
	EdgeMenus = "menus"
	// EdgeParent holds the string denoting the parent edge name in mutations.
	EdgeParent = "parent"
	// EdgeChildren holds the string denoting the children edge name in mutations.
	EdgeChildren = "children"
	// Table holds the table name of the role in the database.
	Table = "roles"
	// UsersTable is the table that holds the users relation/edge. The primary key declared below.
	UsersTable = "user_roles"
	// UsersInverseTable is the table name for the User entity.
	// It exists in this package in order to avoid circular dependency with the "user" package.
	UsersInverseTable = "users"
	// APIKeysTable is the table that holds the api_keys relation/edge.
	APIKeysTable = "api_keys"
	// APIKeysInverseTable is the table name for the ApiKey entity.
	// It exists in this package in order to avoid circular dependency with the "apikey" package.
	APIKeysInverseTable = "api_keys"
	// APIKeysColumn is the table column denoting the api_keys relation/edge.
	APIKeysColumn = "role_api_keys"
	// MenusTable is the table that holds the menus relation/edge. The primary key declared below.
	MenusTable = "role_menus"
	// MenusInverseTable is the table name for the Menu entity.
	// It exists in this package in order to avoid circular dependency with the "menu" package.
	MenusInverseTable = "menus"
	// ParentTable is the table that holds the parent relation/edge.
	ParentTable = "roles"
	// ParentColumn is the table column denoting the parent relation/edge.
	ParentColumn = "role_children"
	// ChildrenTable is the table that holds the children relation/edge.
	ChildrenTable = "roles"
	// ChildrenColumn is the table column denoting the children relation/edge.
	ChildrenColumn = "role_children"
)

Variables

View Source
var (
	// UsersPrimaryKey and UsersColumn2 are the table columns denoting the
	// primary key for the users relation (M2M).
	UsersPrimaryKey = []string{"user_id", "role_id"}
	// MenusPrimaryKey and MenusColumn2 are the table columns denoting the
	// primary key for the menus relation (M2M).
	MenusPrimaryKey = []string{"role_id", "menu_id"}
)
View Source
var (
	// 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
	// NameValidator is a validator for the "name" field. It is called by the builders before save.
	NameValidator func(string) error
	// CodeValidator is a validator for the "code" field. It is called by the builders before save.
	CodeValidator func(string) error
	// DefaultSort holds the default value on creation for the "sort" field.
	DefaultSort int
	// DefaultIsSystem holds the default value on creation for the "is_system" field.
	DefaultIsSystem bool
	// DefaultDefaultDataScope holds the default value on creation for the "default_data_scope" field.
	DefaultDefaultDataScope string
	// DefaultID holds the default value on creation for the "id" field.
	DefaultID func() uuid.UUID
)

Columns holds all SQL columns for role fields.

View Source
var ForeignKeys = []string{
	"role_children",
}

ForeignKeys holds the SQL foreign-keys that are owned by the "roles" table and are not defined as standalone fields in the schema.

Functions

func And

func And(predicates ...predicate.Role) predicate.Role

And groups predicates with the AND operator between them.

func ArchivedAt

func ArchivedAt(v time.Time) predicate.Role

ArchivedAt applies equality check predicate on the "archived_at" field. It's identical to ArchivedAtEQ.

func ArchivedAtEQ

func ArchivedAtEQ(v time.Time) predicate.Role

ArchivedAtEQ applies the EQ predicate on the "archived_at" field.

func ArchivedAtGT

func ArchivedAtGT(v time.Time) predicate.Role

ArchivedAtGT applies the GT predicate on the "archived_at" field.

func ArchivedAtGTE

func ArchivedAtGTE(v time.Time) predicate.Role

ArchivedAtGTE applies the GTE predicate on the "archived_at" field.

func ArchivedAtIn

func ArchivedAtIn(vs ...time.Time) predicate.Role

ArchivedAtIn applies the In predicate on the "archived_at" field.

func ArchivedAtIsNil

func ArchivedAtIsNil() predicate.Role

ArchivedAtIsNil applies the IsNil predicate on the "archived_at" field.

func ArchivedAtLT

func ArchivedAtLT(v time.Time) predicate.Role

ArchivedAtLT applies the LT predicate on the "archived_at" field.

func ArchivedAtLTE

func ArchivedAtLTE(v time.Time) predicate.Role

ArchivedAtLTE applies the LTE predicate on the "archived_at" field.

func ArchivedAtNEQ

func ArchivedAtNEQ(v time.Time) predicate.Role

ArchivedAtNEQ applies the NEQ predicate on the "archived_at" field.

func ArchivedAtNotIn

func ArchivedAtNotIn(vs ...time.Time) predicate.Role

ArchivedAtNotIn applies the NotIn predicate on the "archived_at" field.

func ArchivedAtNotNil

func ArchivedAtNotNil() predicate.Role

ArchivedAtNotNil applies the NotNil predicate on the "archived_at" field.

func Code

func Code(v string) predicate.Role

Code applies equality check predicate on the "code" field. It's identical to CodeEQ.

func CodeContains

func CodeContains(v string) predicate.Role

CodeContains applies the Contains predicate on the "code" field.

func CodeContainsFold

func CodeContainsFold(v string) predicate.Role

CodeContainsFold applies the ContainsFold predicate on the "code" field.

func CodeEQ

func CodeEQ(v string) predicate.Role

CodeEQ applies the EQ predicate on the "code" field.

func CodeEqualFold

func CodeEqualFold(v string) predicate.Role

CodeEqualFold applies the EqualFold predicate on the "code" field.

func CodeGT

func CodeGT(v string) predicate.Role

CodeGT applies the GT predicate on the "code" field.

func CodeGTE

func CodeGTE(v string) predicate.Role

CodeGTE applies the GTE predicate on the "code" field.

func CodeHasPrefix

func CodeHasPrefix(v string) predicate.Role

CodeHasPrefix applies the HasPrefix predicate on the "code" field.

func CodeHasSuffix

func CodeHasSuffix(v string) predicate.Role

CodeHasSuffix applies the HasSuffix predicate on the "code" field.

func CodeIn

func CodeIn(vs ...string) predicate.Role

CodeIn applies the In predicate on the "code" field.

func CodeLT

func CodeLT(v string) predicate.Role

CodeLT applies the LT predicate on the "code" field.

func CodeLTE

func CodeLTE(v string) predicate.Role

CodeLTE applies the LTE predicate on the "code" field.

func CodeNEQ

func CodeNEQ(v string) predicate.Role

CodeNEQ applies the NEQ predicate on the "code" field.

func CodeNotIn

func CodeNotIn(vs ...string) predicate.Role

CodeNotIn applies the NotIn predicate on the "code" field.

func CreatedAt

func CreatedAt(v time.Time) predicate.Role

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

func CreatedAtEQ

func CreatedAtEQ(v time.Time) predicate.Role

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

func CreatedAtGT

func CreatedAtGT(v time.Time) predicate.Role

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

func CreatedAtGTE

func CreatedAtGTE(v time.Time) predicate.Role

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

func CreatedAtIn

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

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

func CreatedAtIsNil

func CreatedAtIsNil() predicate.Role

CreatedAtIsNil applies the IsNil predicate on the "created_at" field.

func CreatedAtLT

func CreatedAtLT(v time.Time) predicate.Role

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

func CreatedAtLTE

func CreatedAtLTE(v time.Time) predicate.Role

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

func CreatedAtNEQ

func CreatedAtNEQ(v time.Time) predicate.Role

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

func CreatedAtNotIn

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

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

func CreatedAtNotNil

func CreatedAtNotNil() predicate.Role

CreatedAtNotNil applies the NotNil predicate on the "created_at" field.

func CreatedByID

func CreatedByID(v uuid.UUID) predicate.Role

CreatedByID applies equality check predicate on the "created_by_id" field. It's identical to CreatedByIDEQ.

func CreatedByIDEQ

func CreatedByIDEQ(v uuid.UUID) predicate.Role

CreatedByIDEQ applies the EQ predicate on the "created_by_id" field.

func CreatedByIDGT

func CreatedByIDGT(v uuid.UUID) predicate.Role

CreatedByIDGT applies the GT predicate on the "created_by_id" field.

func CreatedByIDGTE

func CreatedByIDGTE(v uuid.UUID) predicate.Role

CreatedByIDGTE applies the GTE predicate on the "created_by_id" field.

func CreatedByIDIn

func CreatedByIDIn(vs ...uuid.UUID) predicate.Role

CreatedByIDIn applies the In predicate on the "created_by_id" field.

func CreatedByIDIsNil

func CreatedByIDIsNil() predicate.Role

CreatedByIDIsNil applies the IsNil predicate on the "created_by_id" field.

func CreatedByIDLT

func CreatedByIDLT(v uuid.UUID) predicate.Role

CreatedByIDLT applies the LT predicate on the "created_by_id" field.

func CreatedByIDLTE

func CreatedByIDLTE(v uuid.UUID) predicate.Role

CreatedByIDLTE applies the LTE predicate on the "created_by_id" field.

func CreatedByIDNEQ

func CreatedByIDNEQ(v uuid.UUID) predicate.Role

CreatedByIDNEQ applies the NEQ predicate on the "created_by_id" field.

func CreatedByIDNotIn

func CreatedByIDNotIn(vs ...uuid.UUID) predicate.Role

CreatedByIDNotIn applies the NotIn predicate on the "created_by_id" field.

func CreatedByIDNotNil

func CreatedByIDNotNil() predicate.Role

CreatedByIDNotNil applies the NotNil predicate on the "created_by_id" field.

func DefaultDataScope

func DefaultDataScope(v string) predicate.Role

DefaultDataScope applies equality check predicate on the "default_data_scope" field. It's identical to DefaultDataScopeEQ.

func DefaultDataScopeContains

func DefaultDataScopeContains(v string) predicate.Role

DefaultDataScopeContains applies the Contains predicate on the "default_data_scope" field.

func DefaultDataScopeContainsFold

func DefaultDataScopeContainsFold(v string) predicate.Role

DefaultDataScopeContainsFold applies the ContainsFold predicate on the "default_data_scope" field.

func DefaultDataScopeEQ

func DefaultDataScopeEQ(v string) predicate.Role

DefaultDataScopeEQ applies the EQ predicate on the "default_data_scope" field.

func DefaultDataScopeEqualFold

func DefaultDataScopeEqualFold(v string) predicate.Role

DefaultDataScopeEqualFold applies the EqualFold predicate on the "default_data_scope" field.

func DefaultDataScopeGT

func DefaultDataScopeGT(v string) predicate.Role

DefaultDataScopeGT applies the GT predicate on the "default_data_scope" field.

func DefaultDataScopeGTE

func DefaultDataScopeGTE(v string) predicate.Role

DefaultDataScopeGTE applies the GTE predicate on the "default_data_scope" field.

func DefaultDataScopeHasPrefix

func DefaultDataScopeHasPrefix(v string) predicate.Role

DefaultDataScopeHasPrefix applies the HasPrefix predicate on the "default_data_scope" field.

func DefaultDataScopeHasSuffix

func DefaultDataScopeHasSuffix(v string) predicate.Role

DefaultDataScopeHasSuffix applies the HasSuffix predicate on the "default_data_scope" field.

func DefaultDataScopeIn

func DefaultDataScopeIn(vs ...string) predicate.Role

DefaultDataScopeIn applies the In predicate on the "default_data_scope" field.

func DefaultDataScopeLT

func DefaultDataScopeLT(v string) predicate.Role

DefaultDataScopeLT applies the LT predicate on the "default_data_scope" field.

func DefaultDataScopeLTE

func DefaultDataScopeLTE(v string) predicate.Role

DefaultDataScopeLTE applies the LTE predicate on the "default_data_scope" field.

func DefaultDataScopeNEQ

func DefaultDataScopeNEQ(v string) predicate.Role

DefaultDataScopeNEQ applies the NEQ predicate on the "default_data_scope" field.

func DefaultDataScopeNotIn

func DefaultDataScopeNotIn(vs ...string) predicate.Role

DefaultDataScopeNotIn applies the NotIn predicate on the "default_data_scope" field.

func DeletedAt

func DeletedAt(v time.Time) predicate.Role

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

func DeletedAtEQ

func DeletedAtEQ(v time.Time) predicate.Role

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

func DeletedAtGT

func DeletedAtGT(v time.Time) predicate.Role

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

func DeletedAtGTE

func DeletedAtGTE(v time.Time) predicate.Role

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

func DeletedAtIn

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

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

func DeletedAtIsNil

func DeletedAtIsNil() predicate.Role

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

func DeletedAtLT

func DeletedAtLT(v time.Time) predicate.Role

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

func DeletedAtLTE

func DeletedAtLTE(v time.Time) predicate.Role

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

func DeletedAtNEQ

func DeletedAtNEQ(v time.Time) predicate.Role

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

func DeletedAtNotIn

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

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

func DeletedAtNotNil

func DeletedAtNotNil() predicate.Role

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

func DeletedByID

func DeletedByID(v uuid.UUID) predicate.Role

DeletedByID applies equality check predicate on the "deleted_by_id" field. It's identical to DeletedByIDEQ.

func DeletedByIDEQ

func DeletedByIDEQ(v uuid.UUID) predicate.Role

DeletedByIDEQ applies the EQ predicate on the "deleted_by_id" field.

func DeletedByIDGT

func DeletedByIDGT(v uuid.UUID) predicate.Role

DeletedByIDGT applies the GT predicate on the "deleted_by_id" field.

func DeletedByIDGTE

func DeletedByIDGTE(v uuid.UUID) predicate.Role

DeletedByIDGTE applies the GTE predicate on the "deleted_by_id" field.

func DeletedByIDIn

func DeletedByIDIn(vs ...uuid.UUID) predicate.Role

DeletedByIDIn applies the In predicate on the "deleted_by_id" field.

func DeletedByIDIsNil

func DeletedByIDIsNil() predicate.Role

DeletedByIDIsNil applies the IsNil predicate on the "deleted_by_id" field.

func DeletedByIDLT

func DeletedByIDLT(v uuid.UUID) predicate.Role

DeletedByIDLT applies the LT predicate on the "deleted_by_id" field.

func DeletedByIDLTE

func DeletedByIDLTE(v uuid.UUID) predicate.Role

DeletedByIDLTE applies the LTE predicate on the "deleted_by_id" field.

func DeletedByIDNEQ

func DeletedByIDNEQ(v uuid.UUID) predicate.Role

DeletedByIDNEQ applies the NEQ predicate on the "deleted_by_id" field.

func DeletedByIDNotIn

func DeletedByIDNotIn(vs ...uuid.UUID) predicate.Role

DeletedByIDNotIn applies the NotIn predicate on the "deleted_by_id" field.

func DeletedByIDNotNil

func DeletedByIDNotNil() predicate.Role

DeletedByIDNotNil applies the NotNil predicate on the "deleted_by_id" field.

func Description

func Description(v string) predicate.Role

Description applies equality check predicate on the "description" field. It's identical to DescriptionEQ.

func DescriptionContains

func DescriptionContains(v string) predicate.Role

DescriptionContains applies the Contains predicate on the "description" field.

func DescriptionContainsFold

func DescriptionContainsFold(v string) predicate.Role

DescriptionContainsFold applies the ContainsFold predicate on the "description" field.

func DescriptionEQ

func DescriptionEQ(v string) predicate.Role

DescriptionEQ applies the EQ predicate on the "description" field.

func DescriptionEqualFold

func DescriptionEqualFold(v string) predicate.Role

DescriptionEqualFold applies the EqualFold predicate on the "description" field.

func DescriptionGT

func DescriptionGT(v string) predicate.Role

DescriptionGT applies the GT predicate on the "description" field.

func DescriptionGTE

func DescriptionGTE(v string) predicate.Role

DescriptionGTE applies the GTE predicate on the "description" field.

func DescriptionHasPrefix

func DescriptionHasPrefix(v string) predicate.Role

DescriptionHasPrefix applies the HasPrefix predicate on the "description" field.

func DescriptionHasSuffix

func DescriptionHasSuffix(v string) predicate.Role

DescriptionHasSuffix applies the HasSuffix predicate on the "description" field.

func DescriptionIn

func DescriptionIn(vs ...string) predicate.Role

DescriptionIn applies the In predicate on the "description" field.

func DescriptionIsNil

func DescriptionIsNil() predicate.Role

DescriptionIsNil applies the IsNil predicate on the "description" field.

func DescriptionLT

func DescriptionLT(v string) predicate.Role

DescriptionLT applies the LT predicate on the "description" field.

func DescriptionLTE

func DescriptionLTE(v string) predicate.Role

DescriptionLTE applies the LTE predicate on the "description" field.

func DescriptionNEQ

func DescriptionNEQ(v string) predicate.Role

DescriptionNEQ applies the NEQ predicate on the "description" field.

func DescriptionNotIn

func DescriptionNotIn(vs ...string) predicate.Role

DescriptionNotIn applies the NotIn predicate on the "description" field.

func DescriptionNotNil

func DescriptionNotNil() predicate.Role

DescriptionNotNil applies the NotNil predicate on the "description" field.

func HasAPIKeys

func HasAPIKeys() predicate.Role

HasAPIKeys applies the HasEdge predicate on the "api_keys" edge.

func HasAPIKeysWith

func HasAPIKeysWith(preds ...predicate.ApiKey) predicate.Role

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

func HasChildren

func HasChildren() predicate.Role

HasChildren applies the HasEdge predicate on the "children" edge.

func HasChildrenWith

func HasChildrenWith(preds ...predicate.Role) predicate.Role

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

func HasMenus

func HasMenus() predicate.Role

HasMenus applies the HasEdge predicate on the "menus" edge.

func HasMenusWith

func HasMenusWith(preds ...predicate.Menu) predicate.Role

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

func HasParent

func HasParent() predicate.Role

HasParent applies the HasEdge predicate on the "parent" edge.

func HasParentWith

func HasParentWith(preds ...predicate.Role) predicate.Role

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

func HasUsers

func HasUsers() predicate.Role

HasUsers applies the HasEdge predicate on the "users" edge.

func HasUsersWith

func HasUsersWith(preds ...predicate.User) predicate.Role

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

func ID

func ID(id uuid.UUID) predicate.Role

ID filters vertices based on their ID field.

func IDEQ

func IDEQ(id uuid.UUID) predicate.Role

IDEQ applies the EQ predicate on the ID field.

func IDGT

func IDGT(id uuid.UUID) predicate.Role

IDGT applies the GT predicate on the ID field.

func IDGTE

func IDGTE(id uuid.UUID) predicate.Role

IDGTE applies the GTE predicate on the ID field.

func IDIn

func IDIn(ids ...uuid.UUID) predicate.Role

IDIn applies the In predicate on the ID field.

func IDLT

func IDLT(id uuid.UUID) predicate.Role

IDLT applies the LT predicate on the ID field.

func IDLTE

func IDLTE(id uuid.UUID) predicate.Role

IDLTE applies the LTE predicate on the ID field.

func IDNEQ

func IDNEQ(id uuid.UUID) predicate.Role

IDNEQ applies the NEQ predicate on the ID field.

func IDNotIn

func IDNotIn(ids ...uuid.UUID) predicate.Role

IDNotIn applies the NotIn predicate on the ID field.

func IsSystem

func IsSystem(v bool) predicate.Role

IsSystem applies equality check predicate on the "is_system" field. It's identical to IsSystemEQ.

func IsSystemEQ

func IsSystemEQ(v bool) predicate.Role

IsSystemEQ applies the EQ predicate on the "is_system" field.

func IsSystemNEQ

func IsSystemNEQ(v bool) predicate.Role

IsSystemNEQ applies the NEQ predicate on the "is_system" field.

func Name

func Name(v string) predicate.Role

Name applies equality check predicate on the "name" field. It's identical to NameEQ.

func NameContains

func NameContains(v string) predicate.Role

NameContains applies the Contains predicate on the "name" field.

func NameContainsFold

func NameContainsFold(v string) predicate.Role

NameContainsFold applies the ContainsFold predicate on the "name" field.

func NameEQ

func NameEQ(v string) predicate.Role

NameEQ applies the EQ predicate on the "name" field.

func NameEqualFold

func NameEqualFold(v string) predicate.Role

NameEqualFold applies the EqualFold predicate on the "name" field.

func NameGT

func NameGT(v string) predicate.Role

NameGT applies the GT predicate on the "name" field.

func NameGTE

func NameGTE(v string) predicate.Role

NameGTE applies the GTE predicate on the "name" field.

func NameHasPrefix

func NameHasPrefix(v string) predicate.Role

NameHasPrefix applies the HasPrefix predicate on the "name" field.

func NameHasSuffix

func NameHasSuffix(v string) predicate.Role

NameHasSuffix applies the HasSuffix predicate on the "name" field.

func NameIn

func NameIn(vs ...string) predicate.Role

NameIn applies the In predicate on the "name" field.

func NameLT

func NameLT(v string) predicate.Role

NameLT applies the LT predicate on the "name" field.

func NameLTE

func NameLTE(v string) predicate.Role

NameLTE applies the LTE predicate on the "name" field.

func NameNEQ

func NameNEQ(v string) predicate.Role

NameNEQ applies the NEQ predicate on the "name" field.

func NameNotIn

func NameNotIn(vs ...string) predicate.Role

NameNotIn applies the NotIn predicate on the "name" field.

func Not

Not applies the not operator on the given predicate.

func Or

func Or(predicates ...predicate.Role) predicate.Role

Or groups predicates with the OR operator between them.

func OwnerDomainID

func OwnerDomainID(v uuid.UUID) predicate.Role

OwnerDomainID applies equality check predicate on the "owner_domain_id" field. It's identical to OwnerDomainIDEQ.

func OwnerDomainIDEQ

func OwnerDomainIDEQ(v uuid.UUID) predicate.Role

OwnerDomainIDEQ applies the EQ predicate on the "owner_domain_id" field.

func OwnerDomainIDGT

func OwnerDomainIDGT(v uuid.UUID) predicate.Role

OwnerDomainIDGT applies the GT predicate on the "owner_domain_id" field.

func OwnerDomainIDGTE

func OwnerDomainIDGTE(v uuid.UUID) predicate.Role

OwnerDomainIDGTE applies the GTE predicate on the "owner_domain_id" field.

func OwnerDomainIDIn

func OwnerDomainIDIn(vs ...uuid.UUID) predicate.Role

OwnerDomainIDIn applies the In predicate on the "owner_domain_id" field.

func OwnerDomainIDIsNil

func OwnerDomainIDIsNil() predicate.Role

OwnerDomainIDIsNil applies the IsNil predicate on the "owner_domain_id" field.

func OwnerDomainIDLT

func OwnerDomainIDLT(v uuid.UUID) predicate.Role

OwnerDomainIDLT applies the LT predicate on the "owner_domain_id" field.

func OwnerDomainIDLTE

func OwnerDomainIDLTE(v uuid.UUID) predicate.Role

OwnerDomainIDLTE applies the LTE predicate on the "owner_domain_id" field.

func OwnerDomainIDNEQ

func OwnerDomainIDNEQ(v uuid.UUID) predicate.Role

OwnerDomainIDNEQ applies the NEQ predicate on the "owner_domain_id" field.

func OwnerDomainIDNotIn

func OwnerDomainIDNotIn(vs ...uuid.UUID) predicate.Role

OwnerDomainIDNotIn applies the NotIn predicate on the "owner_domain_id" field.

func OwnerDomainIDNotNil

func OwnerDomainIDNotNil() predicate.Role

OwnerDomainIDNotNil applies the NotNil predicate on the "owner_domain_id" field.

func PublishedAt

func PublishedAt(v time.Time) predicate.Role

PublishedAt applies equality check predicate on the "published_at" field. It's identical to PublishedAtEQ.

func PublishedAtEQ

func PublishedAtEQ(v time.Time) predicate.Role

PublishedAtEQ applies the EQ predicate on the "published_at" field.

func PublishedAtGT

func PublishedAtGT(v time.Time) predicate.Role

PublishedAtGT applies the GT predicate on the "published_at" field.

func PublishedAtGTE

func PublishedAtGTE(v time.Time) predicate.Role

PublishedAtGTE applies the GTE predicate on the "published_at" field.

func PublishedAtIn

func PublishedAtIn(vs ...time.Time) predicate.Role

PublishedAtIn applies the In predicate on the "published_at" field.

func PublishedAtIsNil

func PublishedAtIsNil() predicate.Role

PublishedAtIsNil applies the IsNil predicate on the "published_at" field.

func PublishedAtLT

func PublishedAtLT(v time.Time) predicate.Role

PublishedAtLT applies the LT predicate on the "published_at" field.

func PublishedAtLTE

func PublishedAtLTE(v time.Time) predicate.Role

PublishedAtLTE applies the LTE predicate on the "published_at" field.

func PublishedAtNEQ

func PublishedAtNEQ(v time.Time) predicate.Role

PublishedAtNEQ applies the NEQ predicate on the "published_at" field.

func PublishedAtNotIn

func PublishedAtNotIn(vs ...time.Time) predicate.Role

PublishedAtNotIn applies the NotIn predicate on the "published_at" field.

func PublishedAtNotNil

func PublishedAtNotNil() predicate.Role

PublishedAtNotNil applies the NotNil predicate on the "published_at" field.

func Sort

func Sort(v int) predicate.Role

Sort applies equality check predicate on the "sort" field. It's identical to SortEQ.

func SortEQ

func SortEQ(v int) predicate.Role

SortEQ applies the EQ predicate on the "sort" field.

func SortGT

func SortGT(v int) predicate.Role

SortGT applies the GT predicate on the "sort" field.

func SortGTE

func SortGTE(v int) predicate.Role

SortGTE applies the GTE predicate on the "sort" field.

func SortIn

func SortIn(vs ...int) predicate.Role

SortIn applies the In predicate on the "sort" field.

func SortLT

func SortLT(v int) predicate.Role

SortLT applies the LT predicate on the "sort" field.

func SortLTE

func SortLTE(v int) predicate.Role

SortLTE applies the LTE predicate on the "sort" field.

func SortNEQ

func SortNEQ(v int) predicate.Role

SortNEQ applies the NEQ predicate on the "sort" field.

func SortNotIn

func SortNotIn(vs ...int) predicate.Role

SortNotIn applies the NotIn predicate on the "sort" field.

func UpdatedAt

func UpdatedAt(v time.Time) predicate.Role

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

func UpdatedAtEQ

func UpdatedAtEQ(v time.Time) predicate.Role

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

func UpdatedAtGT

func UpdatedAtGT(v time.Time) predicate.Role

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

func UpdatedAtGTE

func UpdatedAtGTE(v time.Time) predicate.Role

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

func UpdatedAtIn

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

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

func UpdatedAtIsNil

func UpdatedAtIsNil() predicate.Role

UpdatedAtIsNil applies the IsNil predicate on the "updated_at" field.

func UpdatedAtLT

func UpdatedAtLT(v time.Time) predicate.Role

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

func UpdatedAtLTE

func UpdatedAtLTE(v time.Time) predicate.Role

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

func UpdatedAtNEQ

func UpdatedAtNEQ(v time.Time) predicate.Role

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

func UpdatedAtNotIn

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

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

func UpdatedAtNotNil

func UpdatedAtNotNil() predicate.Role

UpdatedAtNotNil applies the NotNil predicate on the "updated_at" field.

func UpdatedByID

func UpdatedByID(v uuid.UUID) predicate.Role

UpdatedByID applies equality check predicate on the "updated_by_id" field. It's identical to UpdatedByIDEQ.

func UpdatedByIDEQ

func UpdatedByIDEQ(v uuid.UUID) predicate.Role

UpdatedByIDEQ applies the EQ predicate on the "updated_by_id" field.

func UpdatedByIDGT

func UpdatedByIDGT(v uuid.UUID) predicate.Role

UpdatedByIDGT applies the GT predicate on the "updated_by_id" field.

func UpdatedByIDGTE

func UpdatedByIDGTE(v uuid.UUID) predicate.Role

UpdatedByIDGTE applies the GTE predicate on the "updated_by_id" field.

func UpdatedByIDIn

func UpdatedByIDIn(vs ...uuid.UUID) predicate.Role

UpdatedByIDIn applies the In predicate on the "updated_by_id" field.

func UpdatedByIDIsNil

func UpdatedByIDIsNil() predicate.Role

UpdatedByIDIsNil applies the IsNil predicate on the "updated_by_id" field.

func UpdatedByIDLT

func UpdatedByIDLT(v uuid.UUID) predicate.Role

UpdatedByIDLT applies the LT predicate on the "updated_by_id" field.

func UpdatedByIDLTE

func UpdatedByIDLTE(v uuid.UUID) predicate.Role

UpdatedByIDLTE applies the LTE predicate on the "updated_by_id" field.

func UpdatedByIDNEQ

func UpdatedByIDNEQ(v uuid.UUID) predicate.Role

UpdatedByIDNEQ applies the NEQ predicate on the "updated_by_id" field.

func UpdatedByIDNotIn

func UpdatedByIDNotIn(vs ...uuid.UUID) predicate.Role

UpdatedByIDNotIn applies the NotIn predicate on the "updated_by_id" field.

func UpdatedByIDNotNil

func UpdatedByIDNotNil() predicate.Role

UpdatedByIDNotNil applies the NotNil predicate on the "updated_by_id" field.

func ValidColumn

func ValidColumn(column string) bool

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

Types

type OrderOption

type OrderOption func(*sql.Selector)

OrderOption defines the ordering options for the Role queries.

func ByAPIKeys

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

ByAPIKeys orders the results by api_keys terms.

func ByAPIKeysCount

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

ByAPIKeysCount orders the results by api_keys count.

func ByArchivedAt

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

ByArchivedAt orders the results by the archived_at field.

func ByChildren

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

ByChildren orders the results by children terms.

func ByChildrenCount

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

ByChildrenCount orders the results by children count.

func ByCode

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

ByCode orders the results by the code field.

func ByCreatedAt

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

ByCreatedAt orders the results by the created_at field.

func ByCreatedByID

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

ByCreatedByID orders the results by the created_by_id field.

func ByDefaultDataScope

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

ByDefaultDataScope orders the results by the default_data_scope field.

func ByDeletedAt

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

ByDeletedAt orders the results by the deleted_at field.

func ByDeletedByID

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

ByDeletedByID orders the results by the deleted_by_id field.

func ByDescription

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

ByDescription orders the results by the description field.

func ByID

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

ByID orders the results by the id field.

func ByIsSystem

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

ByIsSystem orders the results by the is_system field.

func ByMenus

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

ByMenus orders the results by menus terms.

func ByMenusCount

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

ByMenusCount orders the results by menus count.

func ByName

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

ByName orders the results by the name field.

func ByOwnerDomainID

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

ByOwnerDomainID orders the results by the owner_domain_id field.

func ByParentField

func ByParentField(field string, opts ...sql.OrderTermOption) OrderOption

ByParentField orders the results by parent field.

func ByPublishedAt

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

ByPublishedAt orders the results by the published_at field.

func BySort

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

BySort orders the results by the sort field.

func ByUpdatedAt

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

ByUpdatedAt orders the results by the updated_at field.

func ByUpdatedByID

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

ByUpdatedByID orders the results by the updated_by_id field.

func ByUsers

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

ByUsers orders the results by users terms.

func ByUsersCount

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

ByUsersCount orders the results by users count.

Jump to

Keyboard shortcuts

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