utils

package
v0.0.0-...-7ab49e5 Latest Latest
Warning

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

Go to latest
Published: Jan 25, 2022 License: MIT Imports: 10 Imported by: 0

Documentation

Index

Constants

View Source
const (
	JWT_SECRET = "my_secret_key"
)

TODO: get token from env variable

Variables

This section is empty.

Functions

func DBConnection

func DBConnection() *gorm.DB

func GetJSONFromCtx

func GetJSONFromCtx(ctx *gin.Context) (bodyData map[string]interface{}, err error)

func GetMapInterfaceFromJson

func GetMapInterfaceFromJson(data []byte) (bodyData map[string]interface{}, err error)

func HashAndSalt

func HashAndSalt(pwd []byte) string

func TransformParameterType

func TransformParameterType(parameter interface{}, parameterType string) (interface{}, error)

Types

This section is empty.

Jump to

Keyboard shortcuts

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