config

package
v0.0.0-...-5d74809 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Aug 29, 2022 License: MIT Imports: 10 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func MailSendCode

func MailSendCode(fmail, tmail, subject, code, username, password, host, port string) error

邮箱验证码发送

func Md5

func Md5(s string) string

func RandCode

func RandCode() string

func Response

func Response(w http.ResponseWriter, resp interface{}, err error)

Types

type Body

type Body struct {
	Code int         `json:"code"`
	Msg  string      `json:"msg"`
	Data interface{} `json:"data,omitempty"`
}

type Config

type Config struct {
	rest.RestConf
	Auth struct {
		AccessSecret string
		AccessExpire int64
	}
	Redis struct {
		Host string
		Pass string
	}
	Mysql struct {
		Datasource string
	}
}

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL