add initial application structure with configuration, logging, and health check endpoints
This commit is contained in:
214
internal/ent/epicheroinfo/epicheroinfo.go
Normal file
214
internal/ent/epicheroinfo/epicheroinfo.go
Normal file
@@ -0,0 +1,214 @@
|
||||
// Code generated by ent, DO NOT EDIT.
|
||||
|
||||
package epicheroinfo
|
||||
|
||||
import (
|
||||
"entgo.io/ent/dialect/sql"
|
||||
)
|
||||
|
||||
const (
|
||||
// Label holds the string label denoting the epicheroinfo type in the database.
|
||||
Label = "epic_hero_info"
|
||||
// FieldID holds the string denoting the id field in the database.
|
||||
FieldID = "id"
|
||||
// FieldHeroName holds the string denoting the hero_name field in the database.
|
||||
FieldHeroName = "hero_name"
|
||||
// FieldHeroCode holds the string denoting the hero_code field in the database.
|
||||
FieldHeroCode = "hero_code"
|
||||
// FieldHeroAttrLv60 holds the string denoting the hero_attr_lv60 field in the database.
|
||||
FieldHeroAttrLv60 = "hero_attr_lv60"
|
||||
// FieldCreator holds the string denoting the creator field in the database.
|
||||
FieldCreator = "creator"
|
||||
// FieldCreateTime holds the string denoting the create_time field in the database.
|
||||
FieldCreateTime = "create_time"
|
||||
// FieldUpdater holds the string denoting the updater field in the database.
|
||||
FieldUpdater = "updater"
|
||||
// FieldUpdateTime holds the string denoting the update_time field in the database.
|
||||
FieldUpdateTime = "update_time"
|
||||
// FieldDeleted holds the string denoting the deleted field in the database.
|
||||
FieldDeleted = "deleted"
|
||||
// FieldNickName holds the string denoting the nick_name field in the database.
|
||||
FieldNickName = "nick_name"
|
||||
// FieldRarity holds the string denoting the rarity field in the database.
|
||||
FieldRarity = "rarity"
|
||||
// FieldRole holds the string denoting the role field in the database.
|
||||
FieldRole = "role"
|
||||
// FieldZodiac holds the string denoting the zodiac field in the database.
|
||||
FieldZodiac = "zodiac"
|
||||
// FieldHeadImgURL holds the string denoting the head_img_url field in the database.
|
||||
FieldHeadImgURL = "head_img_url"
|
||||
// FieldAttribute holds the string denoting the attribute field in the database.
|
||||
FieldAttribute = "attribute"
|
||||
// FieldRemark holds the string denoting the remark field in the database.
|
||||
FieldRemark = "remark"
|
||||
// FieldRawJSON holds the string denoting the raw_json field in the database.
|
||||
FieldRawJSON = "raw_json"
|
||||
// FieldSetContentJSON holds the string denoting the set_content_json field in the database.
|
||||
FieldSetContentJSON = "set_content_json"
|
||||
// FieldSetUpdateTime holds the string denoting the set_update_time field in the database.
|
||||
FieldSetUpdateTime = "set_update_time"
|
||||
// Table holds the table name of the epicheroinfo in the database.
|
||||
Table = "epic_hero_infos"
|
||||
)
|
||||
|
||||
// Columns holds all SQL columns for epicheroinfo fields.
|
||||
var Columns = []string{
|
||||
FieldID,
|
||||
FieldHeroName,
|
||||
FieldHeroCode,
|
||||
FieldHeroAttrLv60,
|
||||
FieldCreator,
|
||||
FieldCreateTime,
|
||||
FieldUpdater,
|
||||
FieldUpdateTime,
|
||||
FieldDeleted,
|
||||
FieldNickName,
|
||||
FieldRarity,
|
||||
FieldRole,
|
||||
FieldZodiac,
|
||||
FieldHeadImgURL,
|
||||
FieldAttribute,
|
||||
FieldRemark,
|
||||
FieldRawJSON,
|
||||
FieldSetContentJSON,
|
||||
FieldSetUpdateTime,
|
||||
}
|
||||
|
||||
// ValidColumn reports if the column name is valid (part of the table columns).
|
||||
func ValidColumn(column string) bool {
|
||||
for i := range Columns {
|
||||
if column == Columns[i] {
|
||||
return true
|
||||
}
|
||||
}
|
||||
return false
|
||||
}
|
||||
|
||||
var (
|
||||
// HeroNameValidator is a validator for the "hero_name" field. It is called by the builders before save.
|
||||
HeroNameValidator func(string) error
|
||||
// HeroCodeValidator is a validator for the "hero_code" field. It is called by the builders before save.
|
||||
HeroCodeValidator func(string) error
|
||||
// HeroAttrLv60Validator is a validator for the "hero_attr_lv60" field. It is called by the builders before save.
|
||||
HeroAttrLv60Validator func(string) error
|
||||
// CreatorValidator is a validator for the "creator" field. It is called by the builders before save.
|
||||
CreatorValidator func(string) error
|
||||
// UpdaterValidator is a validator for the "updater" field. It is called by the builders before save.
|
||||
UpdaterValidator func(string) error
|
||||
// NickNameValidator is a validator for the "nick_name" field. It is called by the builders before save.
|
||||
NickNameValidator func(string) error
|
||||
// RarityValidator is a validator for the "rarity" field. It is called by the builders before save.
|
||||
RarityValidator func(string) error
|
||||
// RoleValidator is a validator for the "role" field. It is called by the builders before save.
|
||||
RoleValidator func(string) error
|
||||
// ZodiacValidator is a validator for the "zodiac" field. It is called by the builders before save.
|
||||
ZodiacValidator func(string) error
|
||||
// HeadImgURLValidator is a validator for the "head_img_url" field. It is called by the builders before save.
|
||||
HeadImgURLValidator func(string) error
|
||||
// AttributeValidator is a validator for the "attribute" field. It is called by the builders before save.
|
||||
AttributeValidator func(string) error
|
||||
// RemarkValidator is a validator for the "remark" field. It is called by the builders before save.
|
||||
RemarkValidator func(string) error
|
||||
// RawJSONValidator is a validator for the "raw_json" field. It is called by the builders before save.
|
||||
RawJSONValidator func(string) error
|
||||
// SetContentJSONValidator is a validator for the "set_content_json" field. It is called by the builders before save.
|
||||
SetContentJSONValidator func(string) error
|
||||
)
|
||||
|
||||
// OrderOption defines the ordering options for the EpicHeroInfo queries.
|
||||
type OrderOption func(*sql.Selector)
|
||||
|
||||
// ByID orders the results by the id field.
|
||||
func ByID(opts ...sql.OrderTermOption) OrderOption {
|
||||
return sql.OrderByField(FieldID, opts...).ToFunc()
|
||||
}
|
||||
|
||||
// ByHeroName orders the results by the hero_name field.
|
||||
func ByHeroName(opts ...sql.OrderTermOption) OrderOption {
|
||||
return sql.OrderByField(FieldHeroName, opts...).ToFunc()
|
||||
}
|
||||
|
||||
// ByHeroCode orders the results by the hero_code field.
|
||||
func ByHeroCode(opts ...sql.OrderTermOption) OrderOption {
|
||||
return sql.OrderByField(FieldHeroCode, opts...).ToFunc()
|
||||
}
|
||||
|
||||
// ByHeroAttrLv60 orders the results by the hero_attr_lv60 field.
|
||||
func ByHeroAttrLv60(opts ...sql.OrderTermOption) OrderOption {
|
||||
return sql.OrderByField(FieldHeroAttrLv60, opts...).ToFunc()
|
||||
}
|
||||
|
||||
// ByCreator orders the results by the creator field.
|
||||
func ByCreator(opts ...sql.OrderTermOption) OrderOption {
|
||||
return sql.OrderByField(FieldCreator, opts...).ToFunc()
|
||||
}
|
||||
|
||||
// ByCreateTime orders the results by the create_time field.
|
||||
func ByCreateTime(opts ...sql.OrderTermOption) OrderOption {
|
||||
return sql.OrderByField(FieldCreateTime, opts...).ToFunc()
|
||||
}
|
||||
|
||||
// ByUpdater orders the results by the updater field.
|
||||
func ByUpdater(opts ...sql.OrderTermOption) OrderOption {
|
||||
return sql.OrderByField(FieldUpdater, opts...).ToFunc()
|
||||
}
|
||||
|
||||
// ByUpdateTime orders the results by the update_time field.
|
||||
func ByUpdateTime(opts ...sql.OrderTermOption) OrderOption {
|
||||
return sql.OrderByField(FieldUpdateTime, opts...).ToFunc()
|
||||
}
|
||||
|
||||
// ByDeleted orders the results by the deleted field.
|
||||
func ByDeleted(opts ...sql.OrderTermOption) OrderOption {
|
||||
return sql.OrderByField(FieldDeleted, opts...).ToFunc()
|
||||
}
|
||||
|
||||
// ByNickName orders the results by the nick_name field.
|
||||
func ByNickName(opts ...sql.OrderTermOption) OrderOption {
|
||||
return sql.OrderByField(FieldNickName, opts...).ToFunc()
|
||||
}
|
||||
|
||||
// ByRarity orders the results by the rarity field.
|
||||
func ByRarity(opts ...sql.OrderTermOption) OrderOption {
|
||||
return sql.OrderByField(FieldRarity, opts...).ToFunc()
|
||||
}
|
||||
|
||||
// ByRole orders the results by the role field.
|
||||
func ByRole(opts ...sql.OrderTermOption) OrderOption {
|
||||
return sql.OrderByField(FieldRole, opts...).ToFunc()
|
||||
}
|
||||
|
||||
// ByZodiac orders the results by the zodiac field.
|
||||
func ByZodiac(opts ...sql.OrderTermOption) OrderOption {
|
||||
return sql.OrderByField(FieldZodiac, opts...).ToFunc()
|
||||
}
|
||||
|
||||
// ByHeadImgURL orders the results by the head_img_url field.
|
||||
func ByHeadImgURL(opts ...sql.OrderTermOption) OrderOption {
|
||||
return sql.OrderByField(FieldHeadImgURL, opts...).ToFunc()
|
||||
}
|
||||
|
||||
// ByAttribute orders the results by the attribute field.
|
||||
func ByAttribute(opts ...sql.OrderTermOption) OrderOption {
|
||||
return sql.OrderByField(FieldAttribute, opts...).ToFunc()
|
||||
}
|
||||
|
||||
// ByRemark orders the results by the remark field.
|
||||
func ByRemark(opts ...sql.OrderTermOption) OrderOption {
|
||||
return sql.OrderByField(FieldRemark, opts...).ToFunc()
|
||||
}
|
||||
|
||||
// ByRawJSON orders the results by the raw_json field.
|
||||
func ByRawJSON(opts ...sql.OrderTermOption) OrderOption {
|
||||
return sql.OrderByField(FieldRawJSON, opts...).ToFunc()
|
||||
}
|
||||
|
||||
// BySetContentJSON orders the results by the set_content_json field.
|
||||
func BySetContentJSON(opts ...sql.OrderTermOption) OrderOption {
|
||||
return sql.OrderByField(FieldSetContentJSON, opts...).ToFunc()
|
||||
}
|
||||
|
||||
// BySetUpdateTime orders the results by the set_update_time field.
|
||||
func BySetUpdateTime(opts ...sql.OrderTermOption) OrderOption {
|
||||
return sql.OrderByField(FieldSetUpdateTime, opts...).ToFunc()
|
||||
}
|
||||
Reference in New Issue
Block a user