Files
EdgeAPI/internal/db/models/http_web_model.go

81 lines
4.3 KiB
Go
Raw Normal View History

2020-09-15 14:44:11 +08:00
package models
import "github.com/iwind/TeaGo/dbs"
2021-05-10 21:13:32 +08:00
// HTTPWeb HTTP Web
2020-09-15 14:44:11 +08:00
type HTTPWeb struct {
Id uint32 `field:"id"` // ID
IsOn uint8 `field:"isOn"` // 是否启用
TemplateId uint32 `field:"templateId"` // 模版ID
AdminId uint32 `field:"adminId"` // 管理员ID
UserId uint32 `field:"userId"` // 用户ID
State uint8 `field:"state"` // 状态
CreatedAt uint64 `field:"createdAt"` // 创建时间
Root dbs.JSON `field:"root"` // 根目录
Charset dbs.JSON `field:"charset"` // 字符集
Shutdown dbs.JSON `field:"shutdown"` // 临时关闭页面配置
Pages dbs.JSON `field:"pages"` // 特殊页面
RedirectToHttps dbs.JSON `field:"redirectToHttps"` // 跳转到HTTPS设置
Indexes dbs.JSON `field:"indexes"` // 首页文件列表
MaxRequestBodySize dbs.JSON `field:"maxRequestBodySize"` // 最大允许的请求内容尺寸
RequestHeader dbs.JSON `field:"requestHeader"` // 请求Header配置
ResponseHeader dbs.JSON `field:"responseHeader"` // 响应Header配置
AccessLog dbs.JSON `field:"accessLog"` // 访问日志配置
Stat dbs.JSON `field:"stat"` // 统计配置
Gzip dbs.JSON `field:"gzip"` // Gzip配置v0.3.2弃用)
Compression dbs.JSON `field:"compression"` // 压缩配置
Cache dbs.JSON `field:"cache"` // 缓存配置
Firewall dbs.JSON `field:"firewall"` // 防火墙设置
Locations dbs.JSON `field:"locations"` // 路由规则配置
Websocket dbs.JSON `field:"websocket"` // Websocket设置
RewriteRules dbs.JSON `field:"rewriteRules"` // 重写规则配置
HostRedirects dbs.JSON `field:"hostRedirects"` // 域名跳转
Fastcgi dbs.JSON `field:"fastcgi"` // Fastcgi配置
Auth dbs.JSON `field:"auth"` // 认证策略配置
Webp dbs.JSON `field:"webp"` // WebP配置
RemoteAddr dbs.JSON `field:"remoteAddr"` // 客户端IP配置
MergeSlashes uint8 `field:"mergeSlashes"` // 是否合并路径中的斜杠
RequestLimit dbs.JSON `field:"requestLimit"` // 请求限制
RequestScripts dbs.JSON `field:"requestScripts"` // 请求脚本
2020-09-15 14:44:11 +08:00
}
type HTTPWebOperator struct {
2020-09-23 18:43:42 +08:00
Id interface{} // ID
IsOn interface{} // 是否启用
TemplateId interface{} // 模版ID
AdminId interface{} // 管理员ID
UserId interface{} // 用户ID
State interface{} // 状态
CreatedAt interface{} // 创建时间
2020-09-26 19:54:15 +08:00
Root interface{} // 根目录
2020-09-23 18:43:42 +08:00
Charset interface{} // 字符集
Shutdown interface{} // 临时关闭页面配置
Pages interface{} // 特殊页面
RedirectToHttps interface{} // 跳转到HTTPS设置
Indexes interface{} // 首页文件列表
MaxRequestBodySize interface{} // 最大允许的请求内容尺寸
2020-09-28 16:25:39 +08:00
RequestHeader interface{} // 请求Header配置
ResponseHeader interface{} // 响应Header配置
2020-09-23 18:43:42 +08:00
AccessLog interface{} // 访问日志配置
Stat interface{} // 统计配置
2021-09-29 19:32:25 +08:00
Gzip interface{} // Gzip配置v0.3.2弃用)
Compression interface{} // 压缩配置
2020-09-23 18:43:42 +08:00
Cache interface{} // 缓存配置
Firewall interface{} // 防火墙设置
2021-07-13 14:30:30 +08:00
Locations interface{} // 路由规则配置
2020-09-26 19:54:15 +08:00
Websocket interface{} // Websocket设置
2020-09-28 16:25:39 +08:00
RewriteRules interface{} // 重写规则配置
2021-01-10 17:34:35 +08:00
HostRedirects interface{} // 域名跳转
2021-05-10 21:13:32 +08:00
Fastcgi interface{} // Fastcgi配置
2021-06-17 21:17:53 +08:00
Auth interface{} // 认证策略配置
Webp interface{} // WebP配置
RemoteAddr interface{} // 客户端IP配置
2021-11-24 12:00:38 +08:00
MergeSlashes interface{} // 是否合并路径中的斜杠
2021-12-12 11:46:23 +08:00
RequestLimit interface{} // 请求限制
2021-12-31 15:21:27 +08:00
RequestScripts interface{} // 请求脚本
2020-09-15 14:44:11 +08:00
}
func NewHTTPWebOperator() *HTTPWebOperator {
return &HTTPWebOperator{}
}