Refactor: Remove deprecated gRPC service files and implement new API structure
- 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`.
This commit is contained in:
@@ -0,0 +1,30 @@
|
||||
// Code generated by ent, DO NOT EDIT.
|
||||
|
||||
package models
|
||||
|
||||
import (
|
||||
"juwan-backend/app/wallet/rpc/internal/models/schema"
|
||||
"juwan-backend/app/wallet/rpc/internal/models/wallet"
|
||||
|
||||
"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() {
|
||||
walletFields := schema.Wallet{}.Fields()
|
||||
_ = walletFields
|
||||
// walletDescBalance is the schema descriptor for balance field.
|
||||
walletDescBalance := walletFields[1].Descriptor()
|
||||
// wallet.DefaultBalance holds the default value on creation for the balance field.
|
||||
wallet.DefaultBalance = walletDescBalance.Default.(decimal.Decimal)
|
||||
// walletDescFrozenBalance is the schema descriptor for frozen_balance field.
|
||||
walletDescFrozenBalance := walletFields[2].Descriptor()
|
||||
// wallet.DefaultFrozenBalance holds the default value on creation for the frozen_balance field.
|
||||
wallet.DefaultFrozenBalance = walletDescFrozenBalance.Default.(decimal.Decimal)
|
||||
// walletDescVersion is the schema descriptor for version field.
|
||||
walletDescVersion := walletFields[3].Descriptor()
|
||||
// wallet.DefaultVersion holds the default value on creation for the version field.
|
||||
wallet.DefaultVersion = walletDescVersion.Default.(int)
|
||||
}
|
||||
Reference in New Issue
Block a user