Documentation ¶
Index ¶
- Constants
- Variables
- func And(predicates ...predicate.Brand) predicate.Brand
- func CreatedAt(v time.Time) predicate.Brand
- func CreatedAtEQ(v time.Time) predicate.Brand
- func CreatedAtGT(v time.Time) predicate.Brand
- func CreatedAtGTE(v time.Time) predicate.Brand
- func CreatedAtIn(vs ...time.Time) predicate.Brand
- func CreatedAtLT(v time.Time) predicate.Brand
- func CreatedAtLTE(v time.Time) predicate.Brand
- func CreatedAtNEQ(v time.Time) predicate.Brand
- func CreatedAtNotIn(vs ...time.Time) predicate.Brand
- func DeletedAt(v time.Time) predicate.Brand
- func DeletedAtEQ(v time.Time) predicate.Brand
- func DeletedAtGT(v time.Time) predicate.Brand
- func DeletedAtGTE(v time.Time) predicate.Brand
- func DeletedAtIn(vs ...time.Time) predicate.Brand
- func DeletedAtIsNil() predicate.Brand
- func DeletedAtLT(v time.Time) predicate.Brand
- func DeletedAtLTE(v time.Time) predicate.Brand
- func DeletedAtNEQ(v time.Time) predicate.Brand
- func DeletedAtNotIn(vs ...time.Time) predicate.Brand
- func DeletedAtNotNil() predicate.Brand
- func Description(v string) predicate.Brand
- func DescriptionContains(v string) predicate.Brand
- func DescriptionContainsFold(v string) predicate.Brand
- func DescriptionEQ(v string) predicate.Brand
- func DescriptionEqualFold(v string) predicate.Brand
- func DescriptionGT(v string) predicate.Brand
- func DescriptionGTE(v string) predicate.Brand
- func DescriptionHasPrefix(v string) predicate.Brand
- func DescriptionHasSuffix(v string) predicate.Brand
- func DescriptionIn(vs ...string) predicate.Brand
- func DescriptionIsNil() predicate.Brand
- func DescriptionLT(v string) predicate.Brand
- func DescriptionLTE(v string) predicate.Brand
- func DescriptionNEQ(v string) predicate.Brand
- func DescriptionNotIn(vs ...string) predicate.Brand
- func DescriptionNotNil() predicate.Brand
- func HasSpus() predicate.Brand
- func HasSpusWith(preds ...predicate.Spu) predicate.Brand
- func ID(id uint64) predicate.Brand
- func IDEQ(id uint64) predicate.Brand
- func IDGT(id uint64) predicate.Brand
- func IDGTE(id uint64) predicate.Brand
- func IDIn(ids ...uint64) predicate.Brand
- func IDLT(id uint64) predicate.Brand
- func IDLTE(id uint64) predicate.Brand
- func IDNEQ(id uint64) predicate.Brand
- func IDNotIn(ids ...uint64) predicate.Brand
- func Name(v string) predicate.Brand
- func NameContains(v string) predicate.Brand
- func NameContainsFold(v string) predicate.Brand
- func NameEQ(v string) predicate.Brand
- func NameEqualFold(v string) predicate.Brand
- func NameGT(v string) predicate.Brand
- func NameGTE(v string) predicate.Brand
- func NameHasPrefix(v string) predicate.Brand
- func NameHasSuffix(v string) predicate.Brand
- func NameIn(vs ...string) predicate.Brand
- func NameLT(v string) predicate.Brand
- func NameLTE(v string) predicate.Brand
- func NameNEQ(v string) predicate.Brand
- func NameNotIn(vs ...string) predicate.Brand
- func Not(p predicate.Brand) predicate.Brand
- func Or(predicates ...predicate.Brand) predicate.Brand
- func PicURL(v string) predicate.Brand
- func PicURLContains(v string) predicate.Brand
- func PicURLContainsFold(v string) predicate.Brand
- func PicURLEQ(v string) predicate.Brand
- func PicURLEqualFold(v string) predicate.Brand
- func PicURLGT(v string) predicate.Brand
- func PicURLGTE(v string) predicate.Brand
- func PicURLHasPrefix(v string) predicate.Brand
- func PicURLHasSuffix(v string) predicate.Brand
- func PicURLIn(vs ...string) predicate.Brand
- func PicURLLT(v string) predicate.Brand
- func PicURLLTE(v string) predicate.Brand
- func PicURLNEQ(v string) predicate.Brand
- func PicURLNotIn(vs ...string) predicate.Brand
- func Sort(v uint32) predicate.Brand
- func SortEQ(v uint32) predicate.Brand
- func SortGT(v uint32) predicate.Brand
- func SortGTE(v uint32) predicate.Brand
- func SortIn(vs ...uint32) predicate.Brand
- func SortLT(v uint32) predicate.Brand
- func SortLTE(v uint32) predicate.Brand
- func SortNEQ(v uint32) predicate.Brand
- func SortNotIn(vs ...uint32) predicate.Brand
- func Status(v uint8) predicate.Brand
- func StatusEQ(v uint8) predicate.Brand
- func StatusGT(v uint8) predicate.Brand
- func StatusGTE(v uint8) predicate.Brand
- func StatusIn(vs ...uint8) predicate.Brand
- func StatusIsNil() predicate.Brand
- func StatusLT(v uint8) predicate.Brand
- func StatusLTE(v uint8) predicate.Brand
- func StatusNEQ(v uint8) predicate.Brand
- func StatusNotIn(vs ...uint8) predicate.Brand
- func StatusNotNil() predicate.Brand
- func UpdatedAt(v time.Time) predicate.Brand
- func UpdatedAtEQ(v time.Time) predicate.Brand
- func UpdatedAtGT(v time.Time) predicate.Brand
- func UpdatedAtGTE(v time.Time) predicate.Brand
- func UpdatedAtIn(vs ...time.Time) predicate.Brand
- func UpdatedAtLT(v time.Time) predicate.Brand
- func UpdatedAtLTE(v time.Time) predicate.Brand
- func UpdatedAtNEQ(v time.Time) predicate.Brand
- func UpdatedAtNotIn(vs ...time.Time) predicate.Brand
- func ValidColumn(column string) bool
- type OrderOption
- func ByCreatedAt(opts ...sql.OrderTermOption) OrderOption
- func ByDeletedAt(opts ...sql.OrderTermOption) OrderOption
- func ByDescription(opts ...sql.OrderTermOption) OrderOption
- func ByID(opts ...sql.OrderTermOption) OrderOption
- func ByName(opts ...sql.OrderTermOption) OrderOption
- func ByPicURL(opts ...sql.OrderTermOption) OrderOption
- func BySort(opts ...sql.OrderTermOption) OrderOption
- func BySpus(term sql.OrderTerm, terms ...sql.OrderTerm) OrderOption
- func BySpusCount(opts ...sql.OrderTermOption) OrderOption
- func ByStatus(opts ...sql.OrderTermOption) OrderOption
- func ByUpdatedAt(opts ...sql.OrderTermOption) OrderOption
Constants ¶
const ( // Label holds the string label denoting the brand type in the database. Label = "brand" // 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" // FieldStatus holds the string denoting the status field in the database. FieldStatus = "status" // FieldSort holds the string denoting the sort field in the database. FieldSort = "sort" // FieldDeletedAt holds the string denoting the deleted_at field in the database. FieldDeletedAt = "deleted_at" // FieldName holds the string denoting the name field in the database. FieldName = "name" // FieldPicURL holds the string denoting the pic_url field in the database. FieldPicURL = "pic_url" // FieldDescription holds the string denoting the description field in the database. FieldDescription = "description" // EdgeSpus holds the string denoting the spus edge name in mutations. EdgeSpus = "spus" // Table holds the table name of the brand in the database. Table = "product_brand" // SpusTable is the table that holds the spus relation/edge. SpusTable = "product_spu" // SpusInverseTable is the table name for the Spu entity. // It exists in this package in order to avoid circular dependency with the "spu" package. SpusInverseTable = "product_spu" // SpusColumn is the table column denoting the spus relation/edge. SpusColumn = "brand_id" )
Variables ¶
var ( Hooks [1]ent.Hook Interceptors [1]ent.Interceptor // 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 // DefaultStatus holds the default value on creation for the "status" field. DefaultStatus uint8 // DefaultSort holds the default value on creation for the "sort" field. DefaultSort uint32 )
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/agui-coder/simple-admin-product-rpc/ent/runtime"
var Columns = []string{ FieldID, FieldCreatedAt, FieldUpdatedAt, FieldStatus, FieldSort, FieldDeletedAt, FieldName, FieldPicURL, FieldDescription, }
Columns holds all SQL columns for brand fields.
Functions ¶
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 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 DeletedAt ¶
DeletedAt applies equality check predicate on the "deleted_at" field. It's identical to DeletedAtEQ.
func DeletedAtEQ ¶
DeletedAtEQ applies the EQ predicate on the "deleted_at" field.
func DeletedAtGT ¶
DeletedAtGT applies the GT predicate on the "deleted_at" field.
func DeletedAtGTE ¶
DeletedAtGTE applies the GTE predicate on the "deleted_at" field.
func DeletedAtIn ¶
DeletedAtIn applies the In predicate on the "deleted_at" field.
func DeletedAtIsNil ¶
DeletedAtIsNil applies the IsNil predicate on the "deleted_at" field.
func DeletedAtLT ¶
DeletedAtLT applies the LT predicate on the "deleted_at" field.
func DeletedAtLTE ¶
DeletedAtLTE applies the LTE predicate on the "deleted_at" field.
func DeletedAtNEQ ¶
DeletedAtNEQ applies the NEQ predicate on the "deleted_at" field.
func DeletedAtNotIn ¶
DeletedAtNotIn applies the NotIn predicate on the "deleted_at" field.
func DeletedAtNotNil ¶
DeletedAtNotNil applies the NotNil predicate on the "deleted_at" field.
func Description ¶
Description applies equality check predicate on the "description" field. It's identical to DescriptionEQ.
func DescriptionContains ¶
DescriptionContains applies the Contains predicate on the "description" field.
func DescriptionContainsFold ¶
DescriptionContainsFold applies the ContainsFold predicate on the "description" field.
func DescriptionEQ ¶
DescriptionEQ applies the EQ predicate on the "description" field.
func DescriptionEqualFold ¶
DescriptionEqualFold applies the EqualFold predicate on the "description" field.
func DescriptionGT ¶
DescriptionGT applies the GT predicate on the "description" field.
func DescriptionGTE ¶
DescriptionGTE applies the GTE predicate on the "description" field.
func DescriptionHasPrefix ¶
DescriptionHasPrefix applies the HasPrefix predicate on the "description" field.
func DescriptionHasSuffix ¶
DescriptionHasSuffix applies the HasSuffix predicate on the "description" field.
func DescriptionIn ¶
DescriptionIn applies the In predicate on the "description" field.
func DescriptionIsNil ¶
DescriptionIsNil applies the IsNil predicate on the "description" field.
func DescriptionLT ¶
DescriptionLT applies the LT predicate on the "description" field.
func DescriptionLTE ¶
DescriptionLTE applies the LTE predicate on the "description" field.
func DescriptionNEQ ¶
DescriptionNEQ applies the NEQ predicate on the "description" field.
func DescriptionNotIn ¶
DescriptionNotIn applies the NotIn predicate on the "description" field.
func DescriptionNotNil ¶
DescriptionNotNil applies the NotNil predicate on the "description" field.
func HasSpusWith ¶
HasSpusWith applies the HasEdge predicate on the "spus" edge with a given conditions (other predicates).
func NameContains ¶
NameContains applies the Contains predicate on the "name" field.
func NameContainsFold ¶
NameContainsFold applies the ContainsFold predicate on the "name" field.
func NameEqualFold ¶
NameEqualFold applies the EqualFold predicate on the "name" field.
func NameHasPrefix ¶
NameHasPrefix applies the HasPrefix predicate on the "name" field.
func NameHasSuffix ¶
NameHasSuffix applies the HasSuffix predicate on the "name" field.
func PicURL ¶
PicURL applies equality check predicate on the "pic_url" field. It's identical to PicURLEQ.
func PicURLContains ¶
PicURLContains applies the Contains predicate on the "pic_url" field.
func PicURLContainsFold ¶
PicURLContainsFold applies the ContainsFold predicate on the "pic_url" field.
func PicURLEqualFold ¶
PicURLEqualFold applies the EqualFold predicate on the "pic_url" field.
func PicURLHasPrefix ¶
PicURLHasPrefix applies the HasPrefix predicate on the "pic_url" field.
func PicURLHasSuffix ¶
PicURLHasSuffix applies the HasSuffix predicate on the "pic_url" field.
func PicURLNotIn ¶
PicURLNotIn applies the NotIn predicate on the "pic_url" field.
func Status ¶
Status applies equality check predicate on the "status" field. It's identical to StatusEQ.
func StatusIsNil ¶
StatusIsNil applies the IsNil predicate on the "status" field.
func StatusNotIn ¶
StatusNotIn applies the NotIn predicate on the "status" field.
func StatusNotNil ¶
StatusNotNil applies the NotNil predicate on the "status" 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 OrderOption ¶
OrderOption defines the ordering options for the Brand queries.
func ByCreatedAt ¶
func ByCreatedAt(opts ...sql.OrderTermOption) OrderOption
ByCreatedAt orders the results by the created_at field.
func ByDeletedAt ¶
func ByDeletedAt(opts ...sql.OrderTermOption) OrderOption
ByDeletedAt orders the results by the deleted_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 ByPicURL ¶
func ByPicURL(opts ...sql.OrderTermOption) OrderOption
ByPicURL orders the results by the pic_url field.
func BySort ¶
func BySort(opts ...sql.OrderTermOption) OrderOption
BySort orders the results by the sort field.
func BySpus ¶
func BySpus(term sql.OrderTerm, terms ...sql.OrderTerm) OrderOption
BySpus orders the results by spus terms.
func BySpusCount ¶
func BySpusCount(opts ...sql.OrderTermOption) OrderOption
BySpusCount orders the results by spus count.
func ByStatus ¶
func ByStatus(opts ...sql.OrderTermOption) OrderOption
ByStatus orders the results by the status field.
func ByUpdatedAt ¶
func ByUpdatedAt(opts ...sql.OrderTermOption) OrderOption
ByUpdatedAt orders the results by the updated_at field.