Versions in this module Expand all Collapse all v1 v1.0.0 May 31, 2023 Changes in this version + const ImportDataModels + type CreateParam struct + Headers []string + Name string + Rows [][]string + Type string + WorkspaceID string + type DataModel struct + CreatedAt time.Time + Headers []string + ID string + Name string + RowIDs []string + Rows [][]string + Type string + UpdatedAt time.Time + WorkspaceID string + type Factory struct + func NewDataModelFactory() *Factory + func (f *Factory) New(param *CreateParam) *DataModel + type Grid struct + Type string + Value []byte + type ImportDataModelsEvent struct + ImportFileBaseDir string + Schemas []schema.DataModelTypedSchema + WorkspaceID string + func NewImportDataModelsEvent(workspaceID, baseDir string, schemas []schema.DataModelTypedSchema) *ImportDataModelsEvent + func NewImportDataModelsEventFromPayload(data []byte) (*ImportDataModelsEvent, error) + func (e *ImportDataModelsEvent) Delay() time.Duration + func (e *ImportDataModelsEvent) EventType() string + func (e *ImportDataModelsEvent) Payload() []byte + type ImportDataModelsHandler struct + func NewImportDataModelsHandler(repo Repository, bus eventbus.EventBus, factory *Factory) *ImportDataModelsHandler + func (h *ImportDataModelsHandler) Handle(ctx context.Context, event *ImportDataModelsEvent) error + type Repository interface + Delete func(ctx context.Context, dm *DataModel) error + Get func(ctx context.Context, id string) (*DataModel, error) + Save func(ctx context.Context, dm *DataModel) error + type Row struct + Grids []*Grid + type Service interface + Create func(context.Context, *DataModel) error + Delete func(context.Context, *DataModel) error + Get func(context.Context, string) (*DataModel, error) + Update func(context.Context, *DataModel) error + Upsert func(context.Context, *DataModel) error + func NewService(repo Repository, eventbus eventbus.EventBus, factory *Factory) Service