dept

package
v0.0.0-...-acd6729 Latest Latest
Warning

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

Go to latest
Published: Jan 17, 2022 License: MIT Imports: 3 Imported by: 0

Documentation

Index

Constants

View Source
const (
	// Label holds the string label denoting the dept type in the database.
	Label = "dept"
	// FieldID holds the string denoting the id field in the database.
	FieldID = "dept_id"
	// EdgeUser holds the string denoting the user edge name in mutations.
	EdgeUser = "user"
	// UserFieldID holds the string denoting the ID field of the User.
	UserFieldID = "user_id"
	// Table holds the table name of the dept in the database.
	Table = "depts"
	// UserTable is the table that holds the user relation/edge. The primary key declared below.
	UserTable = "dept_user"
	// UserInverseTable is the table name for the User entity.
	// It exists in this package in order to avoid circular dependency with the "user" package.
	UserInverseTable = "users"
)

Variables

View Source
var Columns = []string{
	FieldID,
}

Columns holds all SQL columns for dept fields.

View Source
var (
	// IDValidator is a validator for the "id" field. It is called by the builders before save.
	IDValidator func(string) error
)
View Source
var (
	// UserPrimaryKey and UserColumn2 are the table columns denoting the
	// primary key for the user relation (M2M).
	UserPrimaryKey = []string{"dept_id", "user_id"}
)

Functions

func And

func And(predicates ...predicate.Dept) predicate.Dept

And groups predicates with the AND operator between them.

func HasUser

func HasUser() predicate.Dept

HasUser applies the HasEdge predicate on the "user" edge.

func HasUserWith

func HasUserWith(preds ...predicate.User) predicate.Dept

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

func ID

func ID(id string) predicate.Dept

ID filters vertices based on their ID field.

func IDEQ

func IDEQ(id string) predicate.Dept

IDEQ applies the EQ predicate on the ID field.

func IDGT

func IDGT(id string) predicate.Dept

IDGT applies the GT predicate on the ID field.

func IDGTE

func IDGTE(id string) predicate.Dept

IDGTE applies the GTE predicate on the ID field.

func IDIn

func IDIn(ids ...string) predicate.Dept

IDIn applies the In predicate on the ID field.

func IDLT

func IDLT(id string) predicate.Dept

IDLT applies the LT predicate on the ID field.

func IDLTE

func IDLTE(id string) predicate.Dept

IDLTE applies the LTE predicate on the ID field.

func IDNEQ

func IDNEQ(id string) predicate.Dept

IDNEQ applies the NEQ predicate on the ID field.

func IDNotIn

func IDNotIn(ids ...string) predicate.Dept

IDNotIn applies the NotIn predicate on the ID field.

func Not

Not applies the not operator on the given predicate.

func Or

func Or(predicates ...predicate.Dept) predicate.Dept

Or groups predicates with the OR operator between them.

func ValidColumn

func ValidColumn(column string) bool

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

Types

This section is empty.

Jump to

Keyboard shortcuts

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