factor

package
v0.0.0-...-36f034f Latest Latest
Warning

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

Go to latest
Published: Jan 12, 2023 License: Apache-2.0 Imports: 27 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func GetAsMap

func GetAsMap(v interface{}) (map[string]interface{}, error)

GetAsMap GetAsMap

func GetMapToArrStr

func GetMapToArrStr(schema logic.M, key string) ([]string, error)

GetMapToArrStr get map

func GetMapToBool

func GetMapToBool(schema logic.M, key string) (bool, error)

GetMapToBool GetMapToBool

func GetMapToInt

func GetMapToInt(schema logic.M, key string) (int, error)

GetMapToInt GetMapToInt

func GetMapToString

func GetMapToString(schema logic.M, key string) (string, error)

GetMapToString GetMapToString

func IsLayoutComponent

func IsLayoutComponent(value interface{}) bool

IsLayoutComponent IsLayoutComponent

func SetMold

func SetMold(name logic.Command, m Mold)

SetMold SetMold

func TraverseSchema

func TraverseSchema(schema logic.M, init *initDown) error

TraverseSchema TraverseSchema

Types

type AppData

type AppData interface {
	ExportAppData(ctx context.Context, task *models.Task, handleData chan *basal.CallBackData)
	ImportAppData(ctx context.Context, task *models.Task, handleData chan *basal.CallBackData)
	UseTemplate(ctx context.Context, task *models.Task, handleData chan *basal.CallBackData)
	CreateTemplate(ctx context.Context, task *models.Task, handleData chan *basal.CallBackData)
}

AppData deal with app information

func NewAppData

func NewAppData(conf *config.Config) AppData

NewAppData NewAppData

type AppExport

type AppExport struct {
	// contains filtered or unexported fields
}

AppExport AppExport

func NewAppExport

func NewAppExport() *AppExport

NewAppExport NewAppExport

func (*AppExport) BatchHandle

func (a *AppExport) BatchHandle(ctx context.Context, task *models.Task, handleData chan *basal.CallBackData)

BatchHandle BatchHandle

func (*AppExport) SetTaskTitle

func (a *AppExport) SetTaskTitle(ctx context.Context, task *models.Task) error

SetTaskTitle SetTaskTitle

func (*AppExport) SetValue

func (a *AppExport) SetValue(ctx context.Context, conf *config.Config) error

SetValue SetValue

type AppImport

type AppImport struct {
	// contains filtered or unexported fields
}

AppImport AppImport

func NewAppImport

func NewAppImport() *AppImport

NewAppImport NewAppImport

func (*AppImport) BatchHandle

func (a *AppImport) BatchHandle(ctx context.Context, task *models.Task, handleData chan *basal.CallBackData)

BatchHandle BatchHandle

func (*AppImport) SetTaskTitle

func (a *AppImport) SetTaskTitle(ctx context.Context, task *models.Task) error

SetTaskTitle SetTaskTitle

func (*AppImport) SetValue

func (a *AppImport) SetValue(ctx context.Context, conf *config.Config) error

SetValue SetValue

type ColumnError

type ColumnError struct {
	Index      int
	FieldsName string
	ErrorType  code.ErrorType
}

ColumnError ColumnError

type FormExport

type FormExport struct {
	// contains filtered or unexported fields
}

FormExport FormExport

func NewFormExport

func NewFormExport() *FormExport

NewFormExport NewFormExport

func (*FormExport) BatchHandle

func (d *FormExport) BatchHandle(ctx context.Context, task *models.Task, handleData chan *basal.CallBackData)

BatchHandle BatchHandle

func (*FormExport) SetTaskTitle

func (d *FormExport) SetTaskTitle(ctx context.Context, task *models.Task) error

SetTaskTitle SetTaskTitle

func (*FormExport) SetValue

func (d *FormExport) SetValue(ctx context.Context, conf *config.Config) error

SetValue SetValue

type FormImport

type FormImport struct {
	// contains filtered or unexported fields
}

FormImport FormImport

func NewFormImport

func NewFormImport() *FormImport

NewFormImport NewFormImport

func (*FormImport) BatchHandle

func (d *FormImport) BatchHandle(ctx context.Context, task *models.Task, callBack chan *basal.CallBackData)

BatchHandle BatchHandle

func (*FormImport) SetTaskTitle

func (d *FormImport) SetTaskTitle(ctx context.Context, task *models.Task) error

SetTaskTitle SetTaskTitle

func (*FormImport) SetValue

func (d *FormImport) SetValue(ctx context.Context, conf *config.Config) error

SetValue SetValue

type FormTemplate

type FormTemplate struct {
	// contains filtered or unexported fields
}

FormTemplate FormTemplate

func NewFormTemplate

func NewFormTemplate() *FormTemplate

NewFormTemplate NewFormTemplate

func (*FormTemplate) BatchHandle

func (f *FormTemplate) BatchHandle(ctx context.Context, task *models.Task, data chan *basal.CallBackData)

BatchHandle BatchHandle export form template

func (*FormTemplate) SetTaskTitle

func (f *FormTemplate) SetTaskTitle(ctx context.Context, task *models.Task) error

SetTaskTitle SetTaskTitle

func (*FormTemplate) SetValue

func (f *FormTemplate) SetValue(ctx context.Context, conf *config.Config) error

SetValue SetValue

type ImportError

type ImportError struct {
	Raw    int
	Column []*ColumnError
}

ImportError ImportError

type Mold

type Mold interface {
	BatchHandle(context.Context, *models.Task, chan *basal.CallBackData)
	SetValue(ctx context.Context, conf *config.Config) error
	SetTaskTitle(context.Context, *models.Task) error
}

Mold Mold

type Molders

type Molders struct {
	sync.RWMutex
	Molder map[logic.Command]Mold
}

Molders Molders

func GetMolds

func GetMolds() *Molders

GetMolds GetMolds

func (*Molders) GetMolders

func (m *Molders) GetMolders(ctx context.Context, _c logic.Command, conf *config.Config) (Mold, bool)

GetMolders GetMolders

type TemplateCreate

type TemplateCreate struct {
	// contains filtered or unexported fields
}

TemplateCreate TemplateCreate

func NewTemplateCreate

func NewTemplateCreate() *TemplateCreate

NewTemplateCreate NewTemplateCreate

func (*TemplateCreate) BatchHandle

func (t *TemplateCreate) BatchHandle(ctx context.Context, task *models.Task, handleData chan *basal.CallBackData)

BatchHandle BatchHandle

func (*TemplateCreate) SetTaskTitle

func (t *TemplateCreate) SetTaskTitle(ctx context.Context, task *models.Task) error

SetTaskTitle SetTaskTitle

func (*TemplateCreate) SetValue

func (t *TemplateCreate) SetValue(ctx context.Context, conf *config.Config) error

SetValue SetValue

type UseTemplate

type UseTemplate struct {
	// contains filtered or unexported fields
}

UseTemplate UseTemplate

func NewUseTemplate

func NewUseTemplate() *UseTemplate

NewUseTemplate NewUseTemplate

func (*UseTemplate) BatchHandle

func (t *UseTemplate) BatchHandle(ctx context.Context, task *models.Task, handleData chan *basal.CallBackData)

BatchHandle BatchHandle

func (*UseTemplate) SetTaskTitle

func (t *UseTemplate) SetTaskTitle(ctx context.Context, task *models.Task) error

SetTaskTitle SetTaskTitle

func (*UseTemplate) SetValue

func (t *UseTemplate) SetValue(ctx context.Context, conf *config.Config) error

SetValue SetValue

Jump to

Keyboard shortcuts

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