controllers

package
v0.0.0-...-9d7ceaa Latest Latest
Warning

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

Go to latest
Published: Feb 26, 2020 License: GPL-3.0 Imports: 9 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type CustomerController

type CustomerController struct {
	// contains filtered or unexported fields
}

func NewCustomerController

func NewCustomerController(s *mgo.Session) *CustomerController

func (CustomerController) AddFavorites

func (uc CustomerController) AddFavorites(c *gin.Context)

func (CustomerController) CreateCustomer

func (uc CustomerController) CreateCustomer(c *gin.Context)

func (CustomerController) CustomerList

func (uc CustomerController) CustomerList(c *gin.Context)

func (CustomerController) GetCustomer

func (uc CustomerController) GetCustomer(c *gin.Context)

func (CustomerController) RemoveCustomer

func (uc CustomerController) RemoveCustomer(c *gin.Context)

func (CustomerController) UpdateCustomer

func (uc CustomerController) UpdateCustomer(c *gin.Context)

type JsonResponse

type JsonResponse struct {
	Success bool        `json:"success"`
	Data    interface{} `json:"data"`
	Total   int         `json:"total"`
	Error   interface{} `json:"error"`
}

func Response

func Response(data interface{}, success bool, count int, errors interface{}) JsonResponse

type JwtController

type JwtController struct {
	// contains filtered or unexported fields
}

func NewAuthController

func NewAuthController(cacheClient *cache.Cache, session *mgo.Session) *JwtController

func (JwtController) GenarateNewToken

func (ac JwtController) GenarateNewToken(resource string) string

func (JwtController) RefreshToken

func (ac JwtController) RefreshToken(c *gin.Context)

type ProductController

type ProductController struct {
	// contains filtered or unexported fields
}

func NewProductController

func NewProductController(s *mgo.Session) *ProductController

func (ProductController) CreateProduct

func (uc ProductController) CreateProduct(c *gin.Context)

func (ProductController) GetProduct

func (uc ProductController) GetProduct(c *gin.Context)

func (ProductController) ProductList

func (uc ProductController) ProductList(c *gin.Context)

func (ProductController) RemoveProduct

func (uc ProductController) RemoveProduct(c *gin.Context)

func (ProductController) UpdateProduct

func (uc ProductController) UpdateProduct(c *gin.Context)

Jump to

Keyboard shortcuts

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