dish

package
v0.8.7 Latest Latest
Warning

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

Go to latest
Published: Apr 16, 2024 License: MIT Imports: 4 Imported by: 0

Documentation

Index

Constants

View Source
const (
	// Label holds the string label denoting the dish type in the database.
	Label = "dish"
	// FieldID holds the string denoting the id field in the database.
	FieldID = "id"
	// FieldNameDe holds the string denoting the name_de field in the database.
	FieldNameDe = "name_de"
	// FieldNameEn holds the string denoting the name_en field in the database.
	FieldNameEn = "name_en"
	// EdgeDishOccurrences holds the string denoting the dish_occurrences edge name in mutations.
	EdgeDishOccurrences = "dish_occurrences"
	// EdgeAliases holds the string denoting the aliases edge name in mutations.
	EdgeAliases = "aliases"
	// EdgeSideDishOccurrence holds the string denoting the side_dish_occurrence edge name in mutations.
	EdgeSideDishOccurrence = "side_dish_occurrence"
	// DishAliasFieldID holds the string denoting the ID field of the DishAlias.
	DishAliasFieldID = "alias_name"
	// Table holds the table name of the dish in the database.
	Table = "dish"
	// DishOccurrencesTable is the table that holds the dish_occurrences relation/edge.
	DishOccurrencesTable = "occurrence"
	// DishOccurrencesInverseTable is the table name for the Occurrence entity.
	// It exists in this package in order to avoid circular dependency with the "occurrence" package.
	DishOccurrencesInverseTable = "occurrence"
	// DishOccurrencesColumn is the table column denoting the dish_occurrences relation/edge.
	DishOccurrencesColumn = "dish"
	// AliasesTable is the table that holds the aliases relation/edge.
	AliasesTable = "dish_alias"
	// AliasesInverseTable is the table name for the DishAlias entity.
	// It exists in this package in order to avoid circular dependency with the "dishalias" package.
	AliasesInverseTable = "dish_alias"
	// AliasesColumn is the table column denoting the aliases relation/edge.
	AliasesColumn = "dish"
	// SideDishOccurrenceTable is the table that holds the side_dish_occurrence relation/edge. The primary key declared below.
	SideDishOccurrenceTable = "occurrence_side_dishes"
	// SideDishOccurrenceInverseTable is the table name for the Occurrence entity.
	// It exists in this package in order to avoid circular dependency with the "occurrence" package.
	SideDishOccurrenceInverseTable = "occurrence"
)

Variables

View Source
var (
	// NameDeValidator is a validator for the "name_de" field. It is called by the builders before save.
	NameDeValidator func(string) error
	// NameEnValidator is a validator for the "name_en" field. It is called by the builders before save.
	NameEnValidator func(string) error
	// DefaultID holds the default value on creation for the "id" field.
	DefaultID func() uuid.UUID
)

Columns holds all SQL columns for dish fields.

View Source
var (
	// SideDishOccurrencePrimaryKey and SideDishOccurrenceColumn2 are the table columns denoting the
	// primary key for the side_dish_occurrence relation (M2M).
	SideDishOccurrencePrimaryKey = []string{"occurrence", "dish"}
)

Functions

func And

func And(predicates ...predicate.Dish) predicate.Dish

And groups predicates with the AND operator between them.

func HasAliases

func HasAliases() predicate.Dish

HasAliases applies the HasEdge predicate on the "aliases" edge.

func HasAliasesWith

func HasAliasesWith(preds ...predicate.DishAlias) predicate.Dish

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

func HasDishOccurrences

func HasDishOccurrences() predicate.Dish

HasDishOccurrences applies the HasEdge predicate on the "dish_occurrences" edge.

func HasDishOccurrencesWith

func HasDishOccurrencesWith(preds ...predicate.Occurrence) predicate.Dish

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

func HasSideDishOccurrence

func HasSideDishOccurrence() predicate.Dish

HasSideDishOccurrence applies the HasEdge predicate on the "side_dish_occurrence" edge.

func HasSideDishOccurrenceWith

func HasSideDishOccurrenceWith(preds ...predicate.Occurrence) predicate.Dish

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

func ID

func ID(id uuid.UUID) predicate.Dish

ID filters vertices based on their ID field.

func IDEQ

func IDEQ(id uuid.UUID) predicate.Dish

IDEQ applies the EQ predicate on the ID field.

func IDGT

func IDGT(id uuid.UUID) predicate.Dish

IDGT applies the GT predicate on the ID field.

func IDGTE

func IDGTE(id uuid.UUID) predicate.Dish

IDGTE applies the GTE predicate on the ID field.

func IDIn

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

IDIn applies the In predicate on the ID field.

func IDLT

func IDLT(id uuid.UUID) predicate.Dish

IDLT applies the LT predicate on the ID field.

func IDLTE

func IDLTE(id uuid.UUID) predicate.Dish

IDLTE applies the LTE predicate on the ID field.

func IDNEQ

func IDNEQ(id uuid.UUID) predicate.Dish

IDNEQ applies the NEQ predicate on the ID field.

func IDNotIn

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

IDNotIn applies the NotIn predicate on the ID field.

func NameDe

func NameDe(v string) predicate.Dish

NameDe applies equality check predicate on the "name_de" field. It's identical to NameDeEQ.

func NameDeContains

func NameDeContains(v string) predicate.Dish

NameDeContains applies the Contains predicate on the "name_de" field.

func NameDeContainsFold

func NameDeContainsFold(v string) predicate.Dish

NameDeContainsFold applies the ContainsFold predicate on the "name_de" field.

func NameDeEQ

func NameDeEQ(v string) predicate.Dish

NameDeEQ applies the EQ predicate on the "name_de" field.

func NameDeEqualFold

func NameDeEqualFold(v string) predicate.Dish

NameDeEqualFold applies the EqualFold predicate on the "name_de" field.

func NameDeGT

func NameDeGT(v string) predicate.Dish

NameDeGT applies the GT predicate on the "name_de" field.

func NameDeGTE

func NameDeGTE(v string) predicate.Dish

NameDeGTE applies the GTE predicate on the "name_de" field.

func NameDeHasPrefix

func NameDeHasPrefix(v string) predicate.Dish

NameDeHasPrefix applies the HasPrefix predicate on the "name_de" field.

func NameDeHasSuffix

func NameDeHasSuffix(v string) predicate.Dish

NameDeHasSuffix applies the HasSuffix predicate on the "name_de" field.

func NameDeIn

func NameDeIn(vs ...string) predicate.Dish

NameDeIn applies the In predicate on the "name_de" field.

func NameDeLT

func NameDeLT(v string) predicate.Dish

NameDeLT applies the LT predicate on the "name_de" field.

func NameDeLTE

func NameDeLTE(v string) predicate.Dish

NameDeLTE applies the LTE predicate on the "name_de" field.

func NameDeNEQ

func NameDeNEQ(v string) predicate.Dish

NameDeNEQ applies the NEQ predicate on the "name_de" field.

func NameDeNotIn

func NameDeNotIn(vs ...string) predicate.Dish

NameDeNotIn applies the NotIn predicate on the "name_de" field.

func NameEn

func NameEn(v string) predicate.Dish

NameEn applies equality check predicate on the "name_en" field. It's identical to NameEnEQ.

func NameEnContains

func NameEnContains(v string) predicate.Dish

NameEnContains applies the Contains predicate on the "name_en" field.

func NameEnContainsFold

func NameEnContainsFold(v string) predicate.Dish

NameEnContainsFold applies the ContainsFold predicate on the "name_en" field.

func NameEnEQ

func NameEnEQ(v string) predicate.Dish

NameEnEQ applies the EQ predicate on the "name_en" field.

func NameEnEqualFold

func NameEnEqualFold(v string) predicate.Dish

NameEnEqualFold applies the EqualFold predicate on the "name_en" field.

func NameEnGT

func NameEnGT(v string) predicate.Dish

NameEnGT applies the GT predicate on the "name_en" field.

func NameEnGTE

func NameEnGTE(v string) predicate.Dish

NameEnGTE applies the GTE predicate on the "name_en" field.

func NameEnHasPrefix

func NameEnHasPrefix(v string) predicate.Dish

NameEnHasPrefix applies the HasPrefix predicate on the "name_en" field.

func NameEnHasSuffix

func NameEnHasSuffix(v string) predicate.Dish

NameEnHasSuffix applies the HasSuffix predicate on the "name_en" field.

func NameEnIn

func NameEnIn(vs ...string) predicate.Dish

NameEnIn applies the In predicate on the "name_en" field.

func NameEnIsNil

func NameEnIsNil() predicate.Dish

NameEnIsNil applies the IsNil predicate on the "name_en" field.

func NameEnLT

func NameEnLT(v string) predicate.Dish

NameEnLT applies the LT predicate on the "name_en" field.

func NameEnLTE

func NameEnLTE(v string) predicate.Dish

NameEnLTE applies the LTE predicate on the "name_en" field.

func NameEnNEQ

func NameEnNEQ(v string) predicate.Dish

NameEnNEQ applies the NEQ predicate on the "name_en" field.

func NameEnNotIn

func NameEnNotIn(vs ...string) predicate.Dish

NameEnNotIn applies the NotIn predicate on the "name_en" field.

func NameEnNotNil

func NameEnNotNil() predicate.Dish

NameEnNotNil applies the NotNil predicate on the "name_en" field.

func Not

Not applies the not operator on the given predicate.

func Or

func Or(predicates ...predicate.Dish) predicate.Dish

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

type OrderOption

type OrderOption func(*sql.Selector)

OrderOption defines the ordering options for the Dish queries.

func ByAliases

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

ByAliases orders the results by aliases terms.

func ByAliasesCount

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

ByAliasesCount orders the results by aliases count.

func ByDishOccurrences

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

ByDishOccurrences orders the results by dish_occurrences terms.

func ByDishOccurrencesCount

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

ByDishOccurrencesCount orders the results by dish_occurrences count.

func ByID

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

ByID orders the results by the id field.

func ByNameDe

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

ByNameDe orders the results by the name_de field.

func ByNameEn

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

ByNameEn orders the results by the name_en field.

func BySideDishOccurrence

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

BySideDishOccurrence orders the results by side_dish_occurrence terms.

func BySideDishOccurrenceCount

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

BySideDishOccurrenceCount orders the results by side_dish_occurrence count.

Jump to

Keyboard shortcuts

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