handlers

package
v0.0.0-...-5731057 Latest Latest
Warning

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

Go to latest
Published: Apr 28, 2024 License: MIT Imports: 17 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func E

func E(c *xin.Context) xin.H

func H

func H(c *xin.Context) xin.H

func HealthCheck

func HealthCheck(c *xin.Context)

func Index

func Index(c *xin.Context)

func Panic

func Panic(c *xin.Context)

Types

type ArgIDs

type ArgIDs struct {
	IDs []int64 `form:"id[]"`
}

type JobController

type JobController struct {
	Name     string
	File     string
	Param    string
	Template string
}

JobController job controller base struct

func NewJobController

func NewJobController(name, tpl string) *JobController

func (*JobController) Abort

func (jc *JobController) Abort(c *xin.Context)

func (*JobController) Index

func (jc *JobController) Index(c *xin.Context)

func (*JobController) List

func (jc *JobController) List(c *xin.Context)

func (*JobController) Logs

func (jc *JobController) Logs(c *xin.Context)

func (*JobController) SetFile

func (jc *JobController) SetFile(tt tenant.Tenant, mfh *multipart.FileHeader) error

func (*JobController) SetParam

func (jc *JobController) SetParam(v any)

func (*JobController) Start

func (jc *JobController) Start(c *xin.Context)

func (*JobController) Status

func (jc *JobController) Status(c *xin.Context)

type JobCtrl

type JobCtrl interface {
	Index(*xin.Context)
	Start(*xin.Context)
	Abort(*xin.Context)
	Status(*xin.Context)
	List(*xin.Context)
	Logs(*xin.Context)
}

type JobHandler

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

JobHandler job handler

func NewJobHandler

func NewJobHandler(create func() JobCtrl) *JobHandler

func (*JobHandler) Abort

func (jh *JobHandler) Abort(c *xin.Context)

func (*JobHandler) Index

func (jh *JobHandler) Index(c *xin.Context)

func (*JobHandler) List

func (jh *JobHandler) List(c *xin.Context)

func (*JobHandler) Logs

func (jh *JobHandler) Logs(c *xin.Context)

func (*JobHandler) Start

func (jh *JobHandler) Start(c *xin.Context)

func (*JobHandler) Status

func (jh *JobHandler) Status(c *xin.Context)

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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