// Code generated by ent, DO NOT EDIT.

package models

import (
	"juwan-backend/app/player/rpc/internal/models/players"
	"juwan-backend/app/player/rpc/internal/models/playerservices"
	"juwan-backend/app/player/rpc/internal/models/schema"
	"time"

	"github.com/lib/pq"
	"github.com/shopspring/decimal"
)

// The init function reads all schema descriptors with runtime code
// (default values, validators, hooks and policies) and stitches it
// to their package variables.
func init() {
	playerservicesFields := schema.PlayerServices{}.Fields()
	_ = playerservicesFields
	// playerservicesDescTitle is the schema descriptor for title field.
	playerservicesDescTitle := playerservicesFields[3].Descriptor()
	// playerservices.TitleValidator is a validator for the "title" field. It is called by the builders before save.
	playerservices.TitleValidator = playerservicesDescTitle.Validators[0].(func(string) error)
	// playerservicesDescUnit is the schema descriptor for unit field.
	playerservicesDescUnit := playerservicesFields[6].Descriptor()
	// playerservices.UnitValidator is a validator for the "unit" field. It is called by the builders before save.
	playerservices.UnitValidator = playerservicesDescUnit.Validators[0].(func(string) error)
	// playerservicesDescRankRange is the schema descriptor for rank_range field.
	playerservicesDescRankRange := playerservicesFields[7].Descriptor()
	// playerservices.RankRangeValidator is a validator for the "rank_range" field. It is called by the builders before save.
	playerservices.RankRangeValidator = playerservicesDescRankRange.Validators[0].(func(string) error)
	// playerservicesDescAvailability is the schema descriptor for availability field.
	playerservicesDescAvailability := playerservicesFields[8].Descriptor()
	// playerservices.DefaultAvailability holds the default value on creation for the availability field.
	playerservices.DefaultAvailability = playerservicesDescAvailability.Default.([]string)
	// playerservicesDescRating is the schema descriptor for rating field.
	playerservicesDescRating := playerservicesFields[9].Descriptor()
	// playerservices.DefaultRating holds the default value on creation for the rating field.
	playerservices.DefaultRating = playerservicesDescRating.Default.(decimal.Decimal)
	// playerservicesDescIsActive is the schema descriptor for is_active field.
	playerservicesDescIsActive := playerservicesFields[10].Descriptor()
	// playerservices.DefaultIsActive holds the default value on creation for the is_active field.
	playerservices.DefaultIsActive = playerservicesDescIsActive.Default.(bool)
	// playerservicesDescCreatedAt is the schema descriptor for created_at field.
	playerservicesDescCreatedAt := playerservicesFields[11].Descriptor()
	// playerservices.DefaultCreatedAt holds the default value on creation for the created_at field.
	playerservices.DefaultCreatedAt = playerservicesDescCreatedAt.Default.(func() time.Time)
	// playerservicesDescUpdatedAt is the schema descriptor for updated_at field.
	playerservicesDescUpdatedAt := playerservicesFields[12].Descriptor()
	// playerservices.DefaultUpdatedAt holds the default value on creation for the updated_at field.
	playerservices.DefaultUpdatedAt = playerservicesDescUpdatedAt.Default.(func() time.Time)
	// playerservices.UpdateDefaultUpdatedAt holds the default value on update for the updated_at field.
	playerservices.UpdateDefaultUpdatedAt = playerservicesDescUpdatedAt.UpdateDefault.(func() time.Time)
	playersFields := schema.Players{}.Fields()
	_ = playersFields
	// playersDescStatus is the schema descriptor for status field.
	playersDescStatus := playersFields[2].Descriptor()
	// players.DefaultStatus holds the default value on creation for the status field.
	players.DefaultStatus = playersDescStatus.Default.(string)
	// players.StatusValidator is a validator for the "status" field. It is called by the builders before save.
	players.StatusValidator = playersDescStatus.Validators[0].(func(string) error)
	// playersDescGender is the schema descriptor for gender field.
	playersDescGender := playersFields[3].Descriptor()
	// players.DefaultGender holds the default value on creation for the gender field.
	players.DefaultGender = playersDescGender.Default.(bool)
	// playersDescRating is the schema descriptor for rating field.
	playersDescRating := playersFields[4].Descriptor()
	// players.DefaultRating holds the default value on creation for the rating field.
	players.DefaultRating = playersDescRating.Default.(decimal.Decimal)
	// playersDescTotalOrders is the schema descriptor for total_orders field.
	playersDescTotalOrders := playersFields[5].Descriptor()
	// players.DefaultTotalOrders holds the default value on creation for the total_orders field.
	players.DefaultTotalOrders = playersDescTotalOrders.Default.(int)
	// playersDescCompletedOrders is the schema descriptor for completed_orders field.
	playersDescCompletedOrders := playersFields[6].Descriptor()
	// players.DefaultCompletedOrders holds the default value on creation for the completed_orders field.
	players.DefaultCompletedOrders = playersDescCompletedOrders.Default.(int)
	// playersDescTags is the schema descriptor for tags field.
	playersDescTags := playersFields[8].Descriptor()
	// players.DefaultTags holds the default value on creation for the tags field.
	players.DefaultTags = playersDescTags.Default.([]string)
	// playersDescGames is the schema descriptor for games field.
	playersDescGames := playersFields[9].Descriptor()
	// players.DefaultGames holds the default value on creation for the games field.
	players.DefaultGames = playersDescGames.Default.(pq.Int64Array)
	// playersDescCreatedAt is the schema descriptor for created_at field.
	playersDescCreatedAt := playersFields[10].Descriptor()
	// players.DefaultCreatedAt holds the default value on creation for the created_at field.
	players.DefaultCreatedAt = playersDescCreatedAt.Default.(func() time.Time)
	// playersDescUpdatedAt is the schema descriptor for updated_at field.
	playersDescUpdatedAt := playersFields[11].Descriptor()
	// players.DefaultUpdatedAt holds the default value on creation for the updated_at field.
	players.DefaultUpdatedAt = playersDescUpdatedAt.Default.(func() time.Time)
	// players.UpdateDefaultUpdatedAt holds the default value on update for the updated_at field.
	players.UpdateDefaultUpdatedAt = playersDescUpdatedAt.UpdateDefault.(func() time.Time)
}
