middleware

package
v1.0.51 Latest Latest
Warning

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

Go to latest
Published: Dec 20, 2023 License: MIT Imports: 12 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var (
	ErrInternalMethod = apperr.New("all",
		apperr.WithTitleTranslate(translate.Translate{translate.RU: "Ошибка"}),
		apperr.WithContext("all"),
	)

	ErrCommitDatabaseID = "commit_database_error"
	ErrPanicID          = "panic_error"
)

Functions

func GinRequestBodyLogMiddleware

func GinRequestBodyLogMiddleware(module string, stdout bool) gin.HandlerFunc

func GinResponseBodyLogMiddleware

func GinResponseBodyLogMiddleware(module string, stdout bool) gin.HandlerFunc

Types

type ITransaction

type ITransaction interface {
	DBTransactionMiddleware() gin.HandlerFunc
}

type Transaction

type Transaction struct {
	DB *gorm.DB
}

func NewTr

func NewTr(db *gorm.DB) *Transaction

func (*Transaction) DBTransactionMiddleware

func (tr *Transaction) DBTransactionMiddleware() gin.HandlerFunc

Jump to

Keyboard shortcuts

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