mirror of
https://github.com/go-gitea/gitea.git
synced 2025-08-25 01:54:05 +09:00
add runners management ui
This commit is contained in:
@ -71,3 +71,27 @@ func (f *AdminDashboardForm) Validate(req *http.Request, errs binding.Errors) bi
|
||||
ctx := context.GetContext(req)
|
||||
return middleware.Validate(errs, ctx.Data, f, ctx.Locale)
|
||||
}
|
||||
|
||||
// AdminCreateRunnerForm form for admin to create runner
|
||||
type AdminCreateRunnerForm struct {
|
||||
Name string `binding:"Required"`
|
||||
Type string
|
||||
}
|
||||
|
||||
// Validate validates form fields
|
||||
func (f *AdminCreateRunnerForm) Validate(req *http.Request, errs binding.Errors) binding.Errors {
|
||||
ctx := context.GetContext(req)
|
||||
return middleware.Validate(errs, ctx.Data, f, ctx.Locale)
|
||||
}
|
||||
|
||||
// AdminEditRunnerForm form for admin to create runner
|
||||
type AdminEditRunnerForm struct {
|
||||
Name string `binding:"Required"`
|
||||
Type string
|
||||
}
|
||||
|
||||
// Validate validates form fields
|
||||
func (f *AdminEditRunnerForm) Validate(req *http.Request, errs binding.Errors) binding.Errors {
|
||||
ctx := context.GetContext(req)
|
||||
return middleware.Validate(errs, ctx.Data, f, ctx.Locale)
|
||||
}
|
||||
|
Reference in New Issue
Block a user