controller

package
v0.0.0-...-5e664b8 Latest Latest
Warning

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

Go to latest
Published: Feb 3, 2024 License: AGPL-3.0 Imports: 23 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type ProgramController

ProgramController Interface for program business logic controller.

func NewController

func NewController(
	appCfg *config.Conf,
	loggerp *slog.Logger,
	uuidp uuid.Provider,
	s3 s3_storage.S3Storager,
	passwordp password.Provider,
	kmux kmutex.Provider,
	temailer templatedemailer.TemplatedEmailer,
	client *mongo.Client,
	t_storer tenant_s.TenantStorer,
	usr_storer user_s.UserStorer,
	uploaddirectory_s uploaddirectory_s.UploadDirectoryStorer,
	uploadfile_storer uploadfile_ds.UploadFileStorer,
	program_s program_s.ProgramStorer,
	executable_s executable_s.ExecutableStorer,
) ProgramController

type ProgramControllerImpl

type ProgramControllerImpl struct {
	Config                *config.Conf
	Logger                *slog.Logger
	UUID                  uuid.Provider
	S3                    s3_storage.S3Storager
	Password              password.Provider
	Kmutex                kmutex.Provider
	DbClient              *mongo.Client
	TenantStorer          tenant_s.TenantStorer
	UserStorer            user_s.UserStorer
	UploadDirectoryStorer uploaddirectory_s.UploadDirectoryStorer
	UploadFileStorer      uploadfile_ds.UploadFileStorer
	ProgramStorer         program_s.ProgramStorer
	ExecutableStorer      executable_s.ExecutableStorer
	TemplatedEmailer      templatedemailer.TemplatedEmailer
}

func (*ProgramControllerImpl) ArchiveByID

func (*ProgramControllerImpl) Create

func (*ProgramControllerImpl) DeleteByID

func (impl *ProgramControllerImpl) DeleteByID(ctx context.Context, id primitive.ObjectID) error

func (*ProgramControllerImpl) GetByID

func (*ProgramControllerImpl) ListAsSelectOptionByFilter

func (*ProgramControllerImpl) ListByFilter

func (*ProgramControllerImpl) PublicListAsSelectOptionByFilter

func (*ProgramControllerImpl) UpdateByID

func (impl *ProgramControllerImpl) UpdateByID(ctx context.Context, requestData *ProgramUpdateRequestIDO) (*program_s.Program, error)

type ProgramCreateRequestIDO

type ProgramCreateRequestIDO struct {
	Name               string               `bson:"name" json:"name"`
	Description        string               `bson:"description" json:"description"`
	Instructions       string               `bson:"instructions" json:"instructions"`
	Model              string               `bson:"model" json:"model"`
	BusinessFunction   int8                 `bson:"business_function" json:"business_function"`
	UploadDirectoryIDs []primitive.ObjectID `bson:"upload_directory_ids" json:"upload_directory_ids"`
}

type ProgramUpdateRequestIDO

type ProgramUpdateRequestIDO struct {
	ID               primitive.ObjectID `bson:"id" json:"id"`
	Name             string             `bson:"name" json:"name"`
	Instructions     string             `bson:"instructions" json:"instructions"`
	Model            string             `bson:"model" json:"model"`
	Description      string             `bson:"description" json:"description"`
	BusinessFunction int8               `bson:"business_function" json:"business_function"`
}

Jump to

Keyboard shortcuts

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