Documentation ¶
Index ¶
- Constants
- func CORSMiddleware() gin.HandlerFunc
- func Exception(c *gin.Context, errNo int, errMessage ...string)
- func GetConfig(confFile, section string) (map[string]string, error)
- func GetErrorMessage(errorNo int) string
- func Latlng2Tile(lat, lng, z float64) (x, y int)
- func Output(c *gin.Context, resultData ...interface{})
Constants ¶
View Source
const CONTENT_TYPE_HTML = 0
正文数据类型
View Source
const CONTENT_TYPE_MARKDOWN = 1
View Source
const ERROR_DB_CONNECT = 206
DB
View Source
const ERROR_DB_DELETE = 209
View Source
const ERROR_DB_INSERT = 207
View Source
const ERROR_DB_SELECT = 210
View Source
const ERROR_DB_UPDATE = 208
View Source
const ERROR_FUNC_NON_EXISTS = 110
View Source
const ERROR_GEN_UUID = 107
View Source
const ERROR_INPUT_NULL = 104
View Source
const ERROR_IP_UNAUTHORIZED = 111
View Source
const ERROR_JSON_DECODE = 106
View Source
const ERROR_JSON_FORMAT_ERROR = 103
View Source
const ERROR_NETWORK_ERROR = 101
View Source
const ERROR_NO_ERROR = 301
View Source
const ERROR_PARAM_ERROR = 100
View Source
const ERROR_RAL = 105
View Source
const ERROR_REDIS = 109
View Source
const ERROR_USER_NOT_LOGIN = 102
View Source
const ERROR_USER_UNAUTHORIZED = 112
View Source
const ERROR_UUID_MAX = 108
View Source
const OK = 0
直接从PHP LIB里面复制过来的 意外好用 通用错误码,占用100开头
View Source
const STATUS_INVALID = 0
状态标记
View Source
const STATUS_VALID = 1
View Source
const TYPE_ESSAY = 1
数据类型标记
View Source
const TYPE_SUBSCRIBE = 3
View Source
const TYPE_UNSUBSCRIBE = 4
View Source
const TYPE_WISH = 2
Variables ¶
This section is empty.
Functions ¶
func CORSMiddleware ¶
func CORSMiddleware() gin.HandlerFunc
func GetErrorMessage ¶
func Latlng2Tile ¶
Types ¶
This section is empty.
Click to show internal directories.
Click to hide internal directories.