controllers

package
v0.0.0-...-39a8fbd Latest Latest
Warning

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

Go to latest
Published: Apr 20, 2024 License: MIT Imports: 33 Imported by: 0

Documentation

Index

Constants

View Source
const (
	UnapprovedReasonOther         = "other"
	UnapprovedReasonOutOfAria     = "out_of_aria"
	UnapprovedReasonSizesGenders  = "sizes_genders"
	UnapprovedReasonLoopNotActive = "loop_not_active"
)
View Source
const ErrAllowTOHFalse = "The Terms of the Hosts must be approved"

Variables

This section is empty.

Functions

func BagGetAll

func BagGetAll(c *gin.Context)

func BagPut

func BagPut(c *gin.Context)

func BagRemove

func BagRemove(c *gin.Context)

func BulkyGetAll

func BulkyGetAll(c *gin.Context)

func BulkyPut

func BulkyPut(c *gin.Context)

func BulkyRemove

func BulkyRemove(c *gin.Context)

func ChainAddUser

func ChainAddUser(c *gin.Context)

func ChainApproveUser

func ChainApproveUser(c *gin.Context)

func ChainCreate

func ChainCreate(c *gin.Context)

func ChainDelete

func ChainDelete(c *gin.Context)

func ChainDeleteUnapproved

func ChainDeleteUnapproved(c *gin.Context)

func ChainGet

func ChainGet(c *gin.Context)

func ChainGetAll

func ChainGetAll(c *gin.Context)

func ChainGetNear

func ChainGetNear(c *gin.Context)

func ChainRemoveUser

func ChainRemoveUser(c *gin.Context)

func ChainUpdate

func ChainUpdate(c *gin.Context)

func ContactMail

func ContactMail(c *gin.Context)

func ContactNewsletter

func ContactNewsletter(c *gin.Context)

func CronDaily

func CronDaily(db *gorm.DB)

func CronHourly

func CronHourly(db *gorm.DB)

func CronMonthly

func CronMonthly(db *gorm.DB)

func EventCreate

func EventCreate(c *gin.Context)

func EventDelete

func EventDelete(c *gin.Context)

func EventGet

func EventGet(c *gin.Context)

func EventGetAll

func EventGetAll(c *gin.Context)

func EventGetPrevious

func EventGetPrevious(c *gin.Context)

func EventICal

func EventICal(c *gin.Context)

func EventUpdate

func EventUpdate(c *gin.Context)

func GetRouteCoordinates

func GetRouteCoordinates(c *gin.Context)

func ImageDelete

func ImageDelete(c *gin.Context)

func ImageUpload

func ImageUpload(c *gin.Context)

func InfoGet

func InfoGet(c *gin.Context)

func LoginEmail

func LoginEmail(c *gin.Context)
func LoginSuperAsGenerateLink(c *gin.Context)

func LoginSuperAsRedirect

func LoginSuperAsRedirect(c *gin.Context)

func LoginValidate

func LoginValidate(c *gin.Context)

func Logout

func Logout(c *gin.Context)

func MiddlewareSetDB

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

func Poke

func Poke(c *gin.Context)

func RefreshToken

func RefreshToken(c *gin.Context)

func RegisterBasicUser

func RegisterBasicUser(c *gin.Context)

func RegisterChainAdmin

func RegisterChainAdmin(c *gin.Context)

Sizes and Address is set to the user and the chain

func RouteOptimize

func RouteOptimize(c *gin.Context)

func RouteOrderGet

func RouteOrderGet(c *gin.Context)

func RouteOrderSet

func RouteOrderSet(c *gin.Context)

func UserCheckIfEmailExists

func UserCheckIfEmailExists(c *gin.Context)

func UserGet

func UserGet(c *gin.Context)

func UserGetAllOfChain

func UserGetAllOfChain(c *gin.Context)

func UserHasNewsletter

func UserHasNewsletter(c *gin.Context)

func UserPurge

func UserPurge(c *gin.Context)

func UserTransferChain

func UserTransferChain(c *gin.Context)

func UserUpdate

func UserUpdate(c *gin.Context)

Types

type ChainCreateRequestBody

type ChainCreateRequestBody struct {
	Name             string   `json:"name" binding:"required"`
	Description      string   `json:"description"`
	Address          string   `json:"address" binding:"required"`
	CountryCode      string   `json:"country_code" binding:"required"`
	Latitude         float64  `json:"latitude" binding:"required"`
	Longitude        float64  `json:"longitude" binding:"required"`
	Radius           float32  `json:"radius" binding:"required,gte=1.0,lte=100.0"`
	OpenToNewMembers bool     `json:"open_to_new_members" binding:"required"`
	Sizes            []string `json:"sizes" binding:"required"`
	Genders          []string `json:"genders" binding:"required"`
	AllowTOH         bool     `json:"allow_toh" binding:"required"`
}

type UserCreateRequestBody

type UserCreateRequestBody struct {
	Email       string   `json:"email" binding:"required,email"`
	Name        string   `json:"name" binding:"required,min=3"`
	Address     string   `json:"address" binding:"required,min=3"`
	PhoneNumber string   `json:"phone_number" binding:"required,min=3"`
	Newsletter  bool     `json:"newsletter"`
	Sizes       []string `json:"sizes"`
	Latitude    float64  `json:"latitude"`
	Longitude   float64  `json:"longitude"`
}

Jump to

Keyboard shortcuts

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