ent

package
v1.5.14-beta Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Jul 21, 2023 License: Apache-2.0 Imports: 21 Imported by: 1

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func GenEntLogic

func GenEntLogic(g *GenEntLogicContext) error

GenEntLogic generates the ent CRUD logic files of the rpc service.

func GenProtoData

func GenProtoData(schema *load.Schema, g *GenEntLogicContext) (string, string, error)

Types

type GenEntLogicContext

type GenEntLogicContext struct {
	Schema          string
	Output          string
	ServiceName     string
	ProjectName     string
	Style           string
	ProtoFieldStyle string
	ModelName       string
	Multiple        bool
	SearchKeyNum    int
	ModuleName      string
	GroupName       string
	UseUUID         bool
	UseI18n         bool
	ProtoOut        string
	ImportPrefix    string
	Overwrite       bool
}

func (GenEntLogicContext) Validate

func (g GenEntLogicContext) Validate() error

type RpcLogicData

type RpcLogicData struct {
	LogicName string
	LogicCode string
}

func GenCRUDData

func GenCRUDData(g *GenEntLogicContext, projectCtx *ctx.ProjectContext, schema *load.Schema) []*RpcLogicData

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL