productinfo

package
v0.0.0-...-05e3429 Latest Latest
Warning

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

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

Documentation

Index

Constants

View Source
const (
	// Label holds the string label denoting the productinfo type in the database.
	Label = "product_info"
	// FieldID holds the string denoting the id field in the database.
	FieldID = "id"
	// 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"
	// FieldName holds the string denoting the name field in the database.
	FieldName = "name"
	// FieldDescription holds the string denoting the description field in the database.
	FieldDescription = "description"
	// FieldYear holds the string denoting the year field in the database.
	FieldYear = "year"
	// FieldProvider holds the string denoting the provider field in the database.
	FieldProvider = "provider"
	// EdgeTags holds the string denoting the tags edge name in mutations.
	EdgeTags = "tags"
	// EdgeProductTags holds the string denoting the product_tags edge name in mutations.
	EdgeProductTags = "product_tags"
	// Table holds the table name of the productinfo in the database.
	Table = "product_info"
	// TagsTable is the table that holds the tags relation/edge. The primary key declared below.
	TagsTable = "product_tags"
	// TagsInverseTable is the table name for the Tag entity.
	// It exists in this package in order to avoid circular dependency with the "tag" package.
	TagsInverseTable = "tags"
	// ProductTagsTable is the table that holds the product_tags relation/edge.
	ProductTagsTable = "product_tags"
	// ProductTagsInverseTable is the table name for the ProductTag entity.
	// It exists in this package in order to avoid circular dependency with the "producttag" package.
	ProductTagsInverseTable = "product_tags"
	// ProductTagsColumn is the table column denoting the product_tags relation/edge.
	ProductTagsColumn = "product_id"
)

Variables

View Source
var (
	Hooks [1]ent.Hook
	// 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
	// DefaultDescription holds the default value on creation for the "description" field.
	DefaultDescription string
	// YearValidator is a validator for the "year" field. It is called by the builders before save.
	YearValidator func(int) error
	// IDValidator is a validator for the "id" field. It is called by the builders before save.
	IDValidator func(string) error
)

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/thaiha1607/foursquare_server/ent/runtime"

Columns holds all SQL columns for productinfo fields.

View Source
var (
	// TagsPrimaryKey and TagsColumn2 are the table columns denoting the
	// primary key for the tags relation (M2M).
	TagsPrimaryKey = []string{"product_id", "tag_id"}
)

Functions

func And

func And(predicates ...predicate.ProductInfo) predicate.ProductInfo

And groups predicates with the AND operator between them.

func CreatedAt

func CreatedAt(v time.Time) predicate.ProductInfo

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

func CreatedAtEQ

func CreatedAtEQ(v time.Time) predicate.ProductInfo

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

func CreatedAtGT

func CreatedAtGT(v time.Time) predicate.ProductInfo

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

func CreatedAtGTE

func CreatedAtGTE(v time.Time) predicate.ProductInfo

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

func CreatedAtIn

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

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

func CreatedAtLT

func CreatedAtLT(v time.Time) predicate.ProductInfo

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

func CreatedAtLTE

func CreatedAtLTE(v time.Time) predicate.ProductInfo

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

func CreatedAtNEQ

func CreatedAtNEQ(v time.Time) predicate.ProductInfo

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

func CreatedAtNotIn

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

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

func Description

func Description(v string) predicate.ProductInfo

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

func DescriptionContains

func DescriptionContains(v string) predicate.ProductInfo

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

func DescriptionContainsFold

func DescriptionContainsFold(v string) predicate.ProductInfo

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

func DescriptionEQ

func DescriptionEQ(v string) predicate.ProductInfo

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

func DescriptionEqualFold

func DescriptionEqualFold(v string) predicate.ProductInfo

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

func DescriptionGT

func DescriptionGT(v string) predicate.ProductInfo

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

func DescriptionGTE

func DescriptionGTE(v string) predicate.ProductInfo

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

func DescriptionHasPrefix

func DescriptionHasPrefix(v string) predicate.ProductInfo

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

func DescriptionHasSuffix

func DescriptionHasSuffix(v string) predicate.ProductInfo

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

func DescriptionIn

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

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

func DescriptionIsNil

func DescriptionIsNil() predicate.ProductInfo

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

func DescriptionLT

func DescriptionLT(v string) predicate.ProductInfo

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

func DescriptionLTE

func DescriptionLTE(v string) predicate.ProductInfo

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

func DescriptionNEQ

func DescriptionNEQ(v string) predicate.ProductInfo

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

func DescriptionNotIn

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

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

func DescriptionNotNil

func DescriptionNotNil() predicate.ProductInfo

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

func HasProductTags

func HasProductTags() predicate.ProductInfo

HasProductTags applies the HasEdge predicate on the "product_tags" edge.

func HasProductTagsWith

func HasProductTagsWith(preds ...predicate.ProductTag) predicate.ProductInfo

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

func HasTags

func HasTags() predicate.ProductInfo

HasTags applies the HasEdge predicate on the "tags" edge.

func HasTagsWith

func HasTagsWith(preds ...predicate.Tag) predicate.ProductInfo

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

func ID

ID filters vertices based on their ID field.

func IDContainsFold

func IDContainsFold(id string) predicate.ProductInfo

IDContainsFold applies the ContainsFold predicate on the ID field.

func IDEQ

func IDEQ(id string) predicate.ProductInfo

IDEQ applies the EQ predicate on the ID field.

func IDEqualFold

func IDEqualFold(id string) predicate.ProductInfo

IDEqualFold applies the EqualFold predicate on the ID field.

func IDGT

func IDGT(id string) predicate.ProductInfo

IDGT applies the GT predicate on the ID field.

func IDGTE

func IDGTE(id string) predicate.ProductInfo

IDGTE applies the GTE predicate on the ID field.

func IDIn

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

IDIn applies the In predicate on the ID field.

func IDLT

func IDLT(id string) predicate.ProductInfo

IDLT applies the LT predicate on the ID field.

func IDLTE

func IDLTE(id string) predicate.ProductInfo

IDLTE applies the LTE predicate on the ID field.

func IDNEQ

func IDNEQ(id string) predicate.ProductInfo

IDNEQ applies the NEQ predicate on the ID field.

func IDNotIn

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

IDNotIn applies the NotIn predicate on the ID field.

func Name

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

func NameContains

func NameContains(v string) predicate.ProductInfo

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

func NameContainsFold

func NameContainsFold(v string) predicate.ProductInfo

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

func NameEQ

func NameEQ(v string) predicate.ProductInfo

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

func NameEqualFold

func NameEqualFold(v string) predicate.ProductInfo

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

func NameGT

func NameGT(v string) predicate.ProductInfo

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

func NameGTE

func NameGTE(v string) predicate.ProductInfo

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

func NameHasPrefix

func NameHasPrefix(v string) predicate.ProductInfo

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

func NameHasSuffix

func NameHasSuffix(v string) predicate.ProductInfo

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

func NameIn

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

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

func NameLT

func NameLT(v string) predicate.ProductInfo

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

func NameLTE

func NameLTE(v string) predicate.ProductInfo

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

func NameNEQ

func NameNEQ(v string) predicate.ProductInfo

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

func NameNotIn

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

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.ProductInfo) predicate.ProductInfo

Or groups predicates with the OR operator between them.

func Provider

func Provider(v string) predicate.ProductInfo

Provider applies equality check predicate on the "provider" field. It's identical to ProviderEQ.

func ProviderContains

func ProviderContains(v string) predicate.ProductInfo

ProviderContains applies the Contains predicate on the "provider" field.

func ProviderContainsFold

func ProviderContainsFold(v string) predicate.ProductInfo

ProviderContainsFold applies the ContainsFold predicate on the "provider" field.

func ProviderEQ

func ProviderEQ(v string) predicate.ProductInfo

ProviderEQ applies the EQ predicate on the "provider" field.

func ProviderEqualFold

func ProviderEqualFold(v string) predicate.ProductInfo

ProviderEqualFold applies the EqualFold predicate on the "provider" field.

func ProviderGT

func ProviderGT(v string) predicate.ProductInfo

ProviderGT applies the GT predicate on the "provider" field.

func ProviderGTE

func ProviderGTE(v string) predicate.ProductInfo

ProviderGTE applies the GTE predicate on the "provider" field.

func ProviderHasPrefix

func ProviderHasPrefix(v string) predicate.ProductInfo

ProviderHasPrefix applies the HasPrefix predicate on the "provider" field.

func ProviderHasSuffix

func ProviderHasSuffix(v string) predicate.ProductInfo

ProviderHasSuffix applies the HasSuffix predicate on the "provider" field.

func ProviderIn

func ProviderIn(vs ...string) predicate.ProductInfo

ProviderIn applies the In predicate on the "provider" field.

func ProviderIsNil

func ProviderIsNil() predicate.ProductInfo

ProviderIsNil applies the IsNil predicate on the "provider" field.

func ProviderLT

func ProviderLT(v string) predicate.ProductInfo

ProviderLT applies the LT predicate on the "provider" field.

func ProviderLTE

func ProviderLTE(v string) predicate.ProductInfo

ProviderLTE applies the LTE predicate on the "provider" field.

func ProviderNEQ

func ProviderNEQ(v string) predicate.ProductInfo

ProviderNEQ applies the NEQ predicate on the "provider" field.

func ProviderNotIn

func ProviderNotIn(vs ...string) predicate.ProductInfo

ProviderNotIn applies the NotIn predicate on the "provider" field.

func ProviderNotNil

func ProviderNotNil() predicate.ProductInfo

ProviderNotNil applies the NotNil predicate on the "provider" field.

func UpdatedAt

func UpdatedAt(v time.Time) predicate.ProductInfo

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

func UpdatedAtEQ

func UpdatedAtEQ(v time.Time) predicate.ProductInfo

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

func UpdatedAtGT

func UpdatedAtGT(v time.Time) predicate.ProductInfo

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

func UpdatedAtGTE

func UpdatedAtGTE(v time.Time) predicate.ProductInfo

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

func UpdatedAtIn

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

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

func UpdatedAtLT

func UpdatedAtLT(v time.Time) predicate.ProductInfo

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

func UpdatedAtLTE

func UpdatedAtLTE(v time.Time) predicate.ProductInfo

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

func UpdatedAtNEQ

func UpdatedAtNEQ(v time.Time) predicate.ProductInfo

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

func UpdatedAtNotIn

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

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

func ValidColumn

func ValidColumn(column string) bool

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

func Year

func Year(v int) predicate.ProductInfo

Year applies equality check predicate on the "year" field. It's identical to YearEQ.

func YearEQ

func YearEQ(v int) predicate.ProductInfo

YearEQ applies the EQ predicate on the "year" field.

func YearGT

func YearGT(v int) predicate.ProductInfo

YearGT applies the GT predicate on the "year" field.

func YearGTE

func YearGTE(v int) predicate.ProductInfo

YearGTE applies the GTE predicate on the "year" field.

func YearIn

func YearIn(vs ...int) predicate.ProductInfo

YearIn applies the In predicate on the "year" field.

func YearIsNil

func YearIsNil() predicate.ProductInfo

YearIsNil applies the IsNil predicate on the "year" field.

func YearLT

func YearLT(v int) predicate.ProductInfo

YearLT applies the LT predicate on the "year" field.

func YearLTE

func YearLTE(v int) predicate.ProductInfo

YearLTE applies the LTE predicate on the "year" field.

func YearNEQ

func YearNEQ(v int) predicate.ProductInfo

YearNEQ applies the NEQ predicate on the "year" field.

func YearNotIn

func YearNotIn(vs ...int) predicate.ProductInfo

YearNotIn applies the NotIn predicate on the "year" field.

func YearNotNil

func YearNotNil() predicate.ProductInfo

YearNotNil applies the NotNil predicate on the "year" field.

Types

type OrderOption

type OrderOption func(*sql.Selector)

OrderOption defines the ordering options for the ProductInfo queries.

func ByCreatedAt

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

ByCreatedAt orders the results by the created_at 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 ByName

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

ByName orders the results by the name field.

func ByProductTags

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

ByProductTags orders the results by product_tags terms.

func ByProductTagsCount

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

ByProductTagsCount orders the results by product_tags count.

func ByProvider

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

ByProvider orders the results by the provider field.

func ByTags

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

ByTags orders the results by tags terms.

func ByTagsCount

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

ByTagsCount orders the results by tags count.

func ByUpdatedAt

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

ByUpdatedAt orders the results by the updated_at field.

func ByYear

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

ByYear orders the results by the year field.

Jump to

Keyboard shortcuts

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