mirror of
https://github.com/acepanel/panel.git
synced 2026-02-05 12:03:01 +08:00
feat: 添加面板HTTPS接口
This commit is contained in:
36
app/http/requests/setting/https.go
Normal file
36
app/http/requests/setting/https.go
Normal file
@@ -0,0 +1,36 @@
|
||||
package requests
|
||||
|
||||
import (
|
||||
"github.com/goravel/framework/contracts/http"
|
||||
"github.com/goravel/framework/contracts/validation"
|
||||
)
|
||||
|
||||
type Https struct {
|
||||
Https bool `form:"https" json:"https"`
|
||||
Cert string `form:"cert" json:"cert"`
|
||||
Key string `form:"key" json:"key"`
|
||||
}
|
||||
|
||||
func (r *Https) Authorize(ctx http.Context) error {
|
||||
return nil
|
||||
}
|
||||
|
||||
func (r *Https) Rules(ctx http.Context) map[string]string {
|
||||
return map[string]string{
|
||||
"https": "bool",
|
||||
"cert": "string",
|
||||
"key": "string",
|
||||
}
|
||||
}
|
||||
|
||||
func (r *Https) Messages(ctx http.Context) map[string]string {
|
||||
return map[string]string{}
|
||||
}
|
||||
|
||||
func (r *Https) Attributes(ctx http.Context) map[string]string {
|
||||
return map[string]string{}
|
||||
}
|
||||
|
||||
func (r *Https) PrepareForValidation(ctx http.Context, data validation.Data) error {
|
||||
return nil
|
||||
}
|
||||
Reference in New Issue
Block a user