Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func NewPostgres ¶
func NewPostgres(cfg PostgresConfig) (*gorm.DB, error)
NewPostgres creates new connection to postgres and return the connection
Types ¶
type CasbinConfig ¶
type Config ¶
type Config struct {
Mode string
Port string
Debug string
Postgres PostgresConfig
Redis RedisConfig
Casbin CasbinConfig
}
Config is a general configuration.
var Cfg Config
Cfg is a configuration variable for the app.
type CustomValidator ¶
type CustomValidator struct {
// contains filtered or unexported fields
}
func NewCustomValidator ¶
func NewCustomValidator() *CustomValidator
func (*CustomValidator) Validate ¶
func (cv *CustomValidator) Validate(i interface{}) error
Click to show internal directories.
Click to hide internal directories.