controller

package
v0.0.0-...-4290112 Latest Latest
Warning

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

Go to latest
Published: Feb 27, 2023 License: MIT Imports: 6 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Health

func Health(next http.Handler) http.Handler

Types

type DBInterface

type DBInterface interface {
	Pingdb(context.Context) error
	Insertone(ctx context.Context, dataBase string, col string, doc interface{}) *service.InsertOneResult
	FindAll(ctx context.Context, dataBase string, col string, filter interface{}) *string
}

type UserController

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

func NewUserController

func NewUserController(savetodb string, dburi string, dbinterface DBInterface) *UserController

func (*UserController) PerformCalculateProfit

func (u *UserController) PerformCalculateProfit(w http.ResponseWriter, r *http.Request)

func (*UserController) ShowAllRevenue

func (u *UserController) ShowAllRevenue(w http.ResponseWriter, r *http.Request)

func (*UserController) WireRoutes

func (u *UserController) WireRoutes(r chi.Router)

Jump to

Keyboard shortcuts

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