admin

package
v1.0.1 Latest Latest
Warning

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

Go to latest
Published: Oct 24, 2025 License: MIT Imports: 29 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func NewAdminRouter

func NewAdminRouter(
	cfg *config.Config,
	db *gorm.DB,
	scheduler *judger.Scheduler,
	appState *judger.AppState) *gin.Engine

NewAdminRouter creates and configures the admin Gin engine.

Types

type AssetInfo added in v0.5.0

type AssetInfo struct {
	Name    string    `json:"name"`
	Path    string    `json:"path"` // Relative to index.assets
	IsDir   bool      `json:"is_dir"`
	Size    int64     `json:"size"`
	ModTime time.Time `json:"mod_time"`
}

type Handler

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

Handler holds all dependencies for the admin API handlers.

func NewHandler

func NewHandler(
	cfg *config.Config,
	db *gorm.DB,
	scheduler *judger.Scheduler,
	appState *judger.AppState,
) *Handler

NewHandler creates a new admin handler with its dependencies.

Jump to

Keyboard shortcuts

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