Documentation
¶
Index ¶
- Variables
- func GetCellIndex(row, col int64) string
- func GetClientIPFromCtx(ctx context.Context) string
- func GetClientIPFromMetadata(ctx context.Context) string
- func GetUidFromCtx(ctx context.Context) int64
- func GetUidStringFromCtx(ctx context.Context) string
- func GetUserIdAndEntityIdFromCtx(ctx context.Context) (int64, string)
- func Int64SliceToInterface(ids []int64) []interface{}
- func ListInInt64(list []int64, i int64) bool
- func Md5ByBytes(b []byte) string
- func Md5ByString(str string) string
- func Placeholders(n int) string
- func Response(w http.ResponseWriter, resp interface{}, err error)
- type Body
- type CtxKey
- type HashId
Constants ¶
This section is empty.
Variables ¶
View Source
var ClientIP = CtxKey("client_ip")
View Source
var CtxKeyJwtEntityId = "entityId"
View Source
var CtxKeyJwtUserId = "jwtUserId"
View Source
var DateFormat = "2006-01-02 15:04:05"
View Source
var DateFormatShort = "2006-01-02"
Functions ¶
func GetCellIndex ¶ added in v0.1.4
func GetClientIPFromCtx ¶ added in v0.1.12
func GetClientIPFromMetadata ¶ added in v0.1.14
func GetUidFromCtx ¶
func GetUidStringFromCtx ¶ added in v0.1.10
func GetUserIdAndEntityIdFromCtx ¶ added in v0.1.6
func Int64SliceToInterface ¶
func Int64SliceToInterface(ids []int64) []interface{}
func ListInInt64 ¶ added in v0.1.3
ListInInt64 list in action
func Md5ByBytes ¶
func Md5ByString ¶
func Placeholders ¶
func Response ¶
func Response(w http.ResponseWriter, resp interface{}, err error)
Types ¶
type HashId ¶
type HashId struct {
// contains filtered or unexported fields
}
func (*HashId) IdToString ¶
func (*HashId) StringToid ¶
Source Files
¶
Click to show internal directories.
Click to hide internal directories.