store

package
v0.45.13 Latest Latest
Warning

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

Go to latest
Published: Nov 13, 2025 License: Apache-2.0 Imports: 19 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var (
	// ErrMissingParent is returned when the parent id or type is missing for file uploads
	ErrMissingParent = errors.New("parent id or type is missing")
	// ErrMissingOrganizationID is returned when organization ID cannot be determined for file upload
	ErrMissingOrganizationID = errors.New("organization ID is required for file upload")
)

Functions

func AddFilePermissions

func AddFilePermissions(ctx context.Context) (context.Context, error)

AddFilePermissions writes authorization tuples for uploaded files and removes them from the request context.

func CreateFileRecord

func CreateFileRecord(ctx context.Context, f pkgobjects.File) (*ent.File, error)

CreateFileRecord creates a file record in the database and returns the resulting ent.File entity.

func UpdateFileWithStorageMetadata

func UpdateFileWithStorageMetadata(ctx context.Context, entFile *ent.File, fileData pkgobjects.File) error

UpdateFileWithStorageMetadata updates a file entity with metadata returned from the storage provider.

Types

This section is empty.

Jump to

Keyboard shortcuts

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