19cc7a778c
- Deleted old gRPC service definitions in `game_grpc.pb.go` and `public.go`. - Added new API server implementations for objectstory, player, and shop services. - Introduced configuration files for new APIs in `etc/*.yaml`. - Created main entry points for each service in `objectstory.go`, `player.go`, and `shop.go`. - Removed unused user update handler and user API files. - Added utility functions for context management and HTTP header parsing. - Introduced PostgreSQL backup configuration in `backup/postgreSql.yaml`.
441 lines
14 KiB
Go
441 lines
14 KiB
Go
// Code generated by ent, DO NOT EDIT.
|
|
|
|
package games
|
|
|
|
import (
|
|
"juwan-backend/app/game/rpc/internal/models/predicate"
|
|
"time"
|
|
|
|
"entgo.io/ent/dialect/sql"
|
|
)
|
|
|
|
// ID filters vertices based on their ID field.
|
|
func ID(id int64) predicate.Games {
|
|
return predicate.Games(sql.FieldEQ(FieldID, id))
|
|
}
|
|
|
|
// IDEQ applies the EQ predicate on the ID field.
|
|
func IDEQ(id int64) predicate.Games {
|
|
return predicate.Games(sql.FieldEQ(FieldID, id))
|
|
}
|
|
|
|
// IDNEQ applies the NEQ predicate on the ID field.
|
|
func IDNEQ(id int64) predicate.Games {
|
|
return predicate.Games(sql.FieldNEQ(FieldID, id))
|
|
}
|
|
|
|
// IDIn applies the In predicate on the ID field.
|
|
func IDIn(ids ...int64) predicate.Games {
|
|
return predicate.Games(sql.FieldIn(FieldID, ids...))
|
|
}
|
|
|
|
// IDNotIn applies the NotIn predicate on the ID field.
|
|
func IDNotIn(ids ...int64) predicate.Games {
|
|
return predicate.Games(sql.FieldNotIn(FieldID, ids...))
|
|
}
|
|
|
|
// IDGT applies the GT predicate on the ID field.
|
|
func IDGT(id int64) predicate.Games {
|
|
return predicate.Games(sql.FieldGT(FieldID, id))
|
|
}
|
|
|
|
// IDGTE applies the GTE predicate on the ID field.
|
|
func IDGTE(id int64) predicate.Games {
|
|
return predicate.Games(sql.FieldGTE(FieldID, id))
|
|
}
|
|
|
|
// IDLT applies the LT predicate on the ID field.
|
|
func IDLT(id int64) predicate.Games {
|
|
return predicate.Games(sql.FieldLT(FieldID, id))
|
|
}
|
|
|
|
// IDLTE applies the LTE predicate on the ID field.
|
|
func IDLTE(id int64) predicate.Games {
|
|
return predicate.Games(sql.FieldLTE(FieldID, id))
|
|
}
|
|
|
|
// Name applies equality check predicate on the "name" field. It's identical to NameEQ.
|
|
func Name(v string) predicate.Games {
|
|
return predicate.Games(sql.FieldEQ(FieldName, v))
|
|
}
|
|
|
|
// Icon applies equality check predicate on the "icon" field. It's identical to IconEQ.
|
|
func Icon(v string) predicate.Games {
|
|
return predicate.Games(sql.FieldEQ(FieldIcon, v))
|
|
}
|
|
|
|
// Category applies equality check predicate on the "category" field. It's identical to CategoryEQ.
|
|
func Category(v string) predicate.Games {
|
|
return predicate.Games(sql.FieldEQ(FieldCategory, v))
|
|
}
|
|
|
|
// SortOrder applies equality check predicate on the "sort_order" field. It's identical to SortOrderEQ.
|
|
func SortOrder(v int) predicate.Games {
|
|
return predicate.Games(sql.FieldEQ(FieldSortOrder, v))
|
|
}
|
|
|
|
// IsActive applies equality check predicate on the "is_active" field. It's identical to IsActiveEQ.
|
|
func IsActive(v bool) predicate.Games {
|
|
return predicate.Games(sql.FieldEQ(FieldIsActive, v))
|
|
}
|
|
|
|
// CreatedAt applies equality check predicate on the "created_at" field. It's identical to CreatedAtEQ.
|
|
func CreatedAt(v time.Time) predicate.Games {
|
|
return predicate.Games(sql.FieldEQ(FieldCreatedAt, v))
|
|
}
|
|
|
|
// UpdatedAt applies equality check predicate on the "updated_at" field. It's identical to UpdatedAtEQ.
|
|
func UpdatedAt(v time.Time) predicate.Games {
|
|
return predicate.Games(sql.FieldEQ(FieldUpdatedAt, v))
|
|
}
|
|
|
|
// NameEQ applies the EQ predicate on the "name" field.
|
|
func NameEQ(v string) predicate.Games {
|
|
return predicate.Games(sql.FieldEQ(FieldName, v))
|
|
}
|
|
|
|
// NameNEQ applies the NEQ predicate on the "name" field.
|
|
func NameNEQ(v string) predicate.Games {
|
|
return predicate.Games(sql.FieldNEQ(FieldName, v))
|
|
}
|
|
|
|
// NameIn applies the In predicate on the "name" field.
|
|
func NameIn(vs ...string) predicate.Games {
|
|
return predicate.Games(sql.FieldIn(FieldName, vs...))
|
|
}
|
|
|
|
// NameNotIn applies the NotIn predicate on the "name" field.
|
|
func NameNotIn(vs ...string) predicate.Games {
|
|
return predicate.Games(sql.FieldNotIn(FieldName, vs...))
|
|
}
|
|
|
|
// NameGT applies the GT predicate on the "name" field.
|
|
func NameGT(v string) predicate.Games {
|
|
return predicate.Games(sql.FieldGT(FieldName, v))
|
|
}
|
|
|
|
// NameGTE applies the GTE predicate on the "name" field.
|
|
func NameGTE(v string) predicate.Games {
|
|
return predicate.Games(sql.FieldGTE(FieldName, v))
|
|
}
|
|
|
|
// NameLT applies the LT predicate on the "name" field.
|
|
func NameLT(v string) predicate.Games {
|
|
return predicate.Games(sql.FieldLT(FieldName, v))
|
|
}
|
|
|
|
// NameLTE applies the LTE predicate on the "name" field.
|
|
func NameLTE(v string) predicate.Games {
|
|
return predicate.Games(sql.FieldLTE(FieldName, v))
|
|
}
|
|
|
|
// NameContains applies the Contains predicate on the "name" field.
|
|
func NameContains(v string) predicate.Games {
|
|
return predicate.Games(sql.FieldContains(FieldName, v))
|
|
}
|
|
|
|
// NameHasPrefix applies the HasPrefix predicate on the "name" field.
|
|
func NameHasPrefix(v string) predicate.Games {
|
|
return predicate.Games(sql.FieldHasPrefix(FieldName, v))
|
|
}
|
|
|
|
// NameHasSuffix applies the HasSuffix predicate on the "name" field.
|
|
func NameHasSuffix(v string) predicate.Games {
|
|
return predicate.Games(sql.FieldHasSuffix(FieldName, v))
|
|
}
|
|
|
|
// NameEqualFold applies the EqualFold predicate on the "name" field.
|
|
func NameEqualFold(v string) predicate.Games {
|
|
return predicate.Games(sql.FieldEqualFold(FieldName, v))
|
|
}
|
|
|
|
// NameContainsFold applies the ContainsFold predicate on the "name" field.
|
|
func NameContainsFold(v string) predicate.Games {
|
|
return predicate.Games(sql.FieldContainsFold(FieldName, v))
|
|
}
|
|
|
|
// IconEQ applies the EQ predicate on the "icon" field.
|
|
func IconEQ(v string) predicate.Games {
|
|
return predicate.Games(sql.FieldEQ(FieldIcon, v))
|
|
}
|
|
|
|
// IconNEQ applies the NEQ predicate on the "icon" field.
|
|
func IconNEQ(v string) predicate.Games {
|
|
return predicate.Games(sql.FieldNEQ(FieldIcon, v))
|
|
}
|
|
|
|
// IconIn applies the In predicate on the "icon" field.
|
|
func IconIn(vs ...string) predicate.Games {
|
|
return predicate.Games(sql.FieldIn(FieldIcon, vs...))
|
|
}
|
|
|
|
// IconNotIn applies the NotIn predicate on the "icon" field.
|
|
func IconNotIn(vs ...string) predicate.Games {
|
|
return predicate.Games(sql.FieldNotIn(FieldIcon, vs...))
|
|
}
|
|
|
|
// IconGT applies the GT predicate on the "icon" field.
|
|
func IconGT(v string) predicate.Games {
|
|
return predicate.Games(sql.FieldGT(FieldIcon, v))
|
|
}
|
|
|
|
// IconGTE applies the GTE predicate on the "icon" field.
|
|
func IconGTE(v string) predicate.Games {
|
|
return predicate.Games(sql.FieldGTE(FieldIcon, v))
|
|
}
|
|
|
|
// IconLT applies the LT predicate on the "icon" field.
|
|
func IconLT(v string) predicate.Games {
|
|
return predicate.Games(sql.FieldLT(FieldIcon, v))
|
|
}
|
|
|
|
// IconLTE applies the LTE predicate on the "icon" field.
|
|
func IconLTE(v string) predicate.Games {
|
|
return predicate.Games(sql.FieldLTE(FieldIcon, v))
|
|
}
|
|
|
|
// IconContains applies the Contains predicate on the "icon" field.
|
|
func IconContains(v string) predicate.Games {
|
|
return predicate.Games(sql.FieldContains(FieldIcon, v))
|
|
}
|
|
|
|
// IconHasPrefix applies the HasPrefix predicate on the "icon" field.
|
|
func IconHasPrefix(v string) predicate.Games {
|
|
return predicate.Games(sql.FieldHasPrefix(FieldIcon, v))
|
|
}
|
|
|
|
// IconHasSuffix applies the HasSuffix predicate on the "icon" field.
|
|
func IconHasSuffix(v string) predicate.Games {
|
|
return predicate.Games(sql.FieldHasSuffix(FieldIcon, v))
|
|
}
|
|
|
|
// IconEqualFold applies the EqualFold predicate on the "icon" field.
|
|
func IconEqualFold(v string) predicate.Games {
|
|
return predicate.Games(sql.FieldEqualFold(FieldIcon, v))
|
|
}
|
|
|
|
// IconContainsFold applies the ContainsFold predicate on the "icon" field.
|
|
func IconContainsFold(v string) predicate.Games {
|
|
return predicate.Games(sql.FieldContainsFold(FieldIcon, v))
|
|
}
|
|
|
|
// CategoryEQ applies the EQ predicate on the "category" field.
|
|
func CategoryEQ(v string) predicate.Games {
|
|
return predicate.Games(sql.FieldEQ(FieldCategory, v))
|
|
}
|
|
|
|
// CategoryNEQ applies the NEQ predicate on the "category" field.
|
|
func CategoryNEQ(v string) predicate.Games {
|
|
return predicate.Games(sql.FieldNEQ(FieldCategory, v))
|
|
}
|
|
|
|
// CategoryIn applies the In predicate on the "category" field.
|
|
func CategoryIn(vs ...string) predicate.Games {
|
|
return predicate.Games(sql.FieldIn(FieldCategory, vs...))
|
|
}
|
|
|
|
// CategoryNotIn applies the NotIn predicate on the "category" field.
|
|
func CategoryNotIn(vs ...string) predicate.Games {
|
|
return predicate.Games(sql.FieldNotIn(FieldCategory, vs...))
|
|
}
|
|
|
|
// CategoryGT applies the GT predicate on the "category" field.
|
|
func CategoryGT(v string) predicate.Games {
|
|
return predicate.Games(sql.FieldGT(FieldCategory, v))
|
|
}
|
|
|
|
// CategoryGTE applies the GTE predicate on the "category" field.
|
|
func CategoryGTE(v string) predicate.Games {
|
|
return predicate.Games(sql.FieldGTE(FieldCategory, v))
|
|
}
|
|
|
|
// CategoryLT applies the LT predicate on the "category" field.
|
|
func CategoryLT(v string) predicate.Games {
|
|
return predicate.Games(sql.FieldLT(FieldCategory, v))
|
|
}
|
|
|
|
// CategoryLTE applies the LTE predicate on the "category" field.
|
|
func CategoryLTE(v string) predicate.Games {
|
|
return predicate.Games(sql.FieldLTE(FieldCategory, v))
|
|
}
|
|
|
|
// CategoryContains applies the Contains predicate on the "category" field.
|
|
func CategoryContains(v string) predicate.Games {
|
|
return predicate.Games(sql.FieldContains(FieldCategory, v))
|
|
}
|
|
|
|
// CategoryHasPrefix applies the HasPrefix predicate on the "category" field.
|
|
func CategoryHasPrefix(v string) predicate.Games {
|
|
return predicate.Games(sql.FieldHasPrefix(FieldCategory, v))
|
|
}
|
|
|
|
// CategoryHasSuffix applies the HasSuffix predicate on the "category" field.
|
|
func CategoryHasSuffix(v string) predicate.Games {
|
|
return predicate.Games(sql.FieldHasSuffix(FieldCategory, v))
|
|
}
|
|
|
|
// CategoryEqualFold applies the EqualFold predicate on the "category" field.
|
|
func CategoryEqualFold(v string) predicate.Games {
|
|
return predicate.Games(sql.FieldEqualFold(FieldCategory, v))
|
|
}
|
|
|
|
// CategoryContainsFold applies the ContainsFold predicate on the "category" field.
|
|
func CategoryContainsFold(v string) predicate.Games {
|
|
return predicate.Games(sql.FieldContainsFold(FieldCategory, v))
|
|
}
|
|
|
|
// SortOrderEQ applies the EQ predicate on the "sort_order" field.
|
|
func SortOrderEQ(v int) predicate.Games {
|
|
return predicate.Games(sql.FieldEQ(FieldSortOrder, v))
|
|
}
|
|
|
|
// SortOrderNEQ applies the NEQ predicate on the "sort_order" field.
|
|
func SortOrderNEQ(v int) predicate.Games {
|
|
return predicate.Games(sql.FieldNEQ(FieldSortOrder, v))
|
|
}
|
|
|
|
// SortOrderIn applies the In predicate on the "sort_order" field.
|
|
func SortOrderIn(vs ...int) predicate.Games {
|
|
return predicate.Games(sql.FieldIn(FieldSortOrder, vs...))
|
|
}
|
|
|
|
// SortOrderNotIn applies the NotIn predicate on the "sort_order" field.
|
|
func SortOrderNotIn(vs ...int) predicate.Games {
|
|
return predicate.Games(sql.FieldNotIn(FieldSortOrder, vs...))
|
|
}
|
|
|
|
// SortOrderGT applies the GT predicate on the "sort_order" field.
|
|
func SortOrderGT(v int) predicate.Games {
|
|
return predicate.Games(sql.FieldGT(FieldSortOrder, v))
|
|
}
|
|
|
|
// SortOrderGTE applies the GTE predicate on the "sort_order" field.
|
|
func SortOrderGTE(v int) predicate.Games {
|
|
return predicate.Games(sql.FieldGTE(FieldSortOrder, v))
|
|
}
|
|
|
|
// SortOrderLT applies the LT predicate on the "sort_order" field.
|
|
func SortOrderLT(v int) predicate.Games {
|
|
return predicate.Games(sql.FieldLT(FieldSortOrder, v))
|
|
}
|
|
|
|
// SortOrderLTE applies the LTE predicate on the "sort_order" field.
|
|
func SortOrderLTE(v int) predicate.Games {
|
|
return predicate.Games(sql.FieldLTE(FieldSortOrder, v))
|
|
}
|
|
|
|
// IsActiveEQ applies the EQ predicate on the "is_active" field.
|
|
func IsActiveEQ(v bool) predicate.Games {
|
|
return predicate.Games(sql.FieldEQ(FieldIsActive, v))
|
|
}
|
|
|
|
// IsActiveNEQ applies the NEQ predicate on the "is_active" field.
|
|
func IsActiveNEQ(v bool) predicate.Games {
|
|
return predicate.Games(sql.FieldNEQ(FieldIsActive, v))
|
|
}
|
|
|
|
// IsActiveIsNil applies the IsNil predicate on the "is_active" field.
|
|
func IsActiveIsNil() predicate.Games {
|
|
return predicate.Games(sql.FieldIsNull(FieldIsActive))
|
|
}
|
|
|
|
// IsActiveNotNil applies the NotNil predicate on the "is_active" field.
|
|
func IsActiveNotNil() predicate.Games {
|
|
return predicate.Games(sql.FieldNotNull(FieldIsActive))
|
|
}
|
|
|
|
// CreatedAtEQ applies the EQ predicate on the "created_at" field.
|
|
func CreatedAtEQ(v time.Time) predicate.Games {
|
|
return predicate.Games(sql.FieldEQ(FieldCreatedAt, v))
|
|
}
|
|
|
|
// CreatedAtNEQ applies the NEQ predicate on the "created_at" field.
|
|
func CreatedAtNEQ(v time.Time) predicate.Games {
|
|
return predicate.Games(sql.FieldNEQ(FieldCreatedAt, v))
|
|
}
|
|
|
|
// CreatedAtIn applies the In predicate on the "created_at" field.
|
|
func CreatedAtIn(vs ...time.Time) predicate.Games {
|
|
return predicate.Games(sql.FieldIn(FieldCreatedAt, vs...))
|
|
}
|
|
|
|
// CreatedAtNotIn applies the NotIn predicate on the "created_at" field.
|
|
func CreatedAtNotIn(vs ...time.Time) predicate.Games {
|
|
return predicate.Games(sql.FieldNotIn(FieldCreatedAt, vs...))
|
|
}
|
|
|
|
// CreatedAtGT applies the GT predicate on the "created_at" field.
|
|
func CreatedAtGT(v time.Time) predicate.Games {
|
|
return predicate.Games(sql.FieldGT(FieldCreatedAt, v))
|
|
}
|
|
|
|
// CreatedAtGTE applies the GTE predicate on the "created_at" field.
|
|
func CreatedAtGTE(v time.Time) predicate.Games {
|
|
return predicate.Games(sql.FieldGTE(FieldCreatedAt, v))
|
|
}
|
|
|
|
// CreatedAtLT applies the LT predicate on the "created_at" field.
|
|
func CreatedAtLT(v time.Time) predicate.Games {
|
|
return predicate.Games(sql.FieldLT(FieldCreatedAt, v))
|
|
}
|
|
|
|
// CreatedAtLTE applies the LTE predicate on the "created_at" field.
|
|
func CreatedAtLTE(v time.Time) predicate.Games {
|
|
return predicate.Games(sql.FieldLTE(FieldCreatedAt, v))
|
|
}
|
|
|
|
// UpdatedAtEQ applies the EQ predicate on the "updated_at" field.
|
|
func UpdatedAtEQ(v time.Time) predicate.Games {
|
|
return predicate.Games(sql.FieldEQ(FieldUpdatedAt, v))
|
|
}
|
|
|
|
// UpdatedAtNEQ applies the NEQ predicate on the "updated_at" field.
|
|
func UpdatedAtNEQ(v time.Time) predicate.Games {
|
|
return predicate.Games(sql.FieldNEQ(FieldUpdatedAt, v))
|
|
}
|
|
|
|
// UpdatedAtIn applies the In predicate on the "updated_at" field.
|
|
func UpdatedAtIn(vs ...time.Time) predicate.Games {
|
|
return predicate.Games(sql.FieldIn(FieldUpdatedAt, vs...))
|
|
}
|
|
|
|
// UpdatedAtNotIn applies the NotIn predicate on the "updated_at" field.
|
|
func UpdatedAtNotIn(vs ...time.Time) predicate.Games {
|
|
return predicate.Games(sql.FieldNotIn(FieldUpdatedAt, vs...))
|
|
}
|
|
|
|
// UpdatedAtGT applies the GT predicate on the "updated_at" field.
|
|
func UpdatedAtGT(v time.Time) predicate.Games {
|
|
return predicate.Games(sql.FieldGT(FieldUpdatedAt, v))
|
|
}
|
|
|
|
// UpdatedAtGTE applies the GTE predicate on the "updated_at" field.
|
|
func UpdatedAtGTE(v time.Time) predicate.Games {
|
|
return predicate.Games(sql.FieldGTE(FieldUpdatedAt, v))
|
|
}
|
|
|
|
// UpdatedAtLT applies the LT predicate on the "updated_at" field.
|
|
func UpdatedAtLT(v time.Time) predicate.Games {
|
|
return predicate.Games(sql.FieldLT(FieldUpdatedAt, v))
|
|
}
|
|
|
|
// UpdatedAtLTE applies the LTE predicate on the "updated_at" field.
|
|
func UpdatedAtLTE(v time.Time) predicate.Games {
|
|
return predicate.Games(sql.FieldLTE(FieldUpdatedAt, v))
|
|
}
|
|
|
|
// And groups predicates with the AND operator between them.
|
|
func And(predicates ...predicate.Games) predicate.Games {
|
|
return predicate.Games(sql.AndPredicates(predicates...))
|
|
}
|
|
|
|
// Or groups predicates with the OR operator between them.
|
|
func Or(predicates ...predicate.Games) predicate.Games {
|
|
return predicate.Games(sql.OrPredicates(predicates...))
|
|
}
|
|
|
|
// Not applies the not operator on the given predicate.
|
|
func Not(p predicate.Games) predicate.Games {
|
|
return predicate.Games(sql.NotPredicates(p))
|
|
}
|