mirror of
https://gitee.com/XM-GO/PandaX.git
synced 2026-05-06 20:11:27 +08:00
【更新】更新pg代码生成
This commit is contained in:
15
pkg/config/jwt.go
Normal file
15
pkg/config/jwt.go
Normal file
@@ -0,0 +1,15 @@
|
||||
package config
|
||||
|
||||
import (
|
||||
"github.com/XM-GO/PandaKit/biz"
|
||||
)
|
||||
|
||||
type Jwt struct {
|
||||
Key string `yaml:"key"`
|
||||
ExpireTime int64 `yaml:"expire-time"` // 过期时间,单位分钟
|
||||
}
|
||||
|
||||
func (j *Jwt) Valid() {
|
||||
biz.IsTrue(j.Key != "", "config.yml之 [jwt.key] 不能为空")
|
||||
biz.IsTrue(j.ExpireTime != 0, "config.yml之 [jwt.expire-time] 不能为空")
|
||||
}
|
||||
Reference in New Issue
Block a user