commit 67a1665cc244c689900f1212629a0cd2c4703aaa Author: bryanqiu Date: Thu Mar 2 10:23:28 2023 +0800 init diff --git a/eno.go b/eno.go new file mode 100644 index 0000000..b17328c --- /dev/null +++ b/eno.go @@ -0,0 +1,24 @@ +package eno + +// Common error code +const ( + errcode_class____system_error = -10000 ///////////////////////// + SYSTEM_ERROR = -10000 // unreachable code, maybe a bug. + UNREACHABLE_CODE = -10000 // unreachable code, maybe a bug. + UNKNOWN_ERROR = -10000 // unreachable code, maybe a bug. + DATABASE_ERROR = -10001 // database error. + REDIS_ERROR = -10002 // redis error. + + errcode_class___request_error = -20000 ///////////////////////// + PARAMETER_INVALID = -20000 // request parameter error + APPID_INVALID = -20001 // request appid invalid + API_NOT_FOUND = -20404 // api not found + + errcode_class__haverisk_error = 20000 ////////////////////////// + NEED_CAPTCHA = 20001 // need captcha + LOGIN_FREEZEN = 20002 // login freezen by too many errors + + errcode_class___frontend_jump = 10000 ////////////////////////// + NOT_LOGIN = 10400 // user not login + NEED_PAY_PASSWORD = 10401 // need input pay password +) diff --git a/go.mod b/go.mod new file mode 100644 index 0000000..fffbf46 --- /dev/null +++ b/go.mod @@ -0,0 +1,3 @@ +module qoobing.com/gomod/eno + +go 1.16