middleware

package
v1.0.65 Latest Latest
Warning

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

Go to latest
Published: Nov 25, 2024 License: AGPL-3.0 Imports: 15 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func DatabaseProvider

func DatabaseProvider(db *gorm.DB) gin.HandlerFunc

func PaginatedDatabaseProvider

func PaginatedDatabaseProvider(db *gorm.DB, config PaginationConfig) gin.HandlerFunc

func RedisProvider

func RedisProvider(redis *redis.Client) gin.HandlerFunc

func RequireAdmin

func RequireAdmin() gin.HandlerFunc

func RequireAdminOrTGOwner

func RequireAdminOrTGOwner() gin.HandlerFunc

func RequireLogin

func RequireLogin() gin.HandlerFunc

func RequirePeerOwnerOrAdmin added in v1.0.35

func RequirePeerOwnerOrAdmin() gin.HandlerFunc

func RequireRepeaterOwnerOrAdmin

func RequireRepeaterOwnerOrAdmin() gin.HandlerFunc

func RequireSelfOrAdmin

func RequireSelfOrAdmin() gin.HandlerFunc

func RequireSuperAdmin

func RequireSuperAdmin() gin.HandlerFunc

func RequireTalkgroupOwnerOrAdmin

func RequireTalkgroupOwnerOrAdmin() gin.HandlerFunc

func SuspendedUserLockout added in v1.0.14

func SuspendedUserLockout() gin.HandlerFunc

func TracingProvider

func TracingProvider() gin.HandlerFunc

func VersionProvider added in v1.0.57

func VersionProvider(version, commit string) gin.HandlerFunc

Types

type PaginationConfig

type PaginationConfig struct {
	DefaultLimit int
	MaxLimit     int
}

Jump to

Keyboard shortcuts

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