controller

package
v0.8.6 Latest Latest
Warning

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

Go to latest
Published: Nov 22, 2019 License: MIT Imports: 10 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type AppCntrl added in v0.8.1

type AppCntrl struct {
	dig.In
	MYSQL *sql.DB
}

AppCntrl handle API related with application itself

func (*AppCntrl) Health added in v0.8.1

func (c *AppCntrl) Health(ctx echo.Context) error

Health end point for health check

func (*AppCntrl) Route added in v0.8.1

func (c *AppCntrl) Route(e *echo.Echo)

Route to define API Route

type BookCntrl added in v0.8.1

type BookCntrl struct {
	dig.In
	service.BookService
}

BookCntrl is controller to book entity

func (*BookCntrl) Create added in v0.8.1

func (c *BookCntrl) Create(ctx echo.Context) (err error)

Create book

func (*BookCntrl) Delete added in v0.8.1

func (c *BookCntrl) Delete(ctx echo.Context) error

Delete book

func (*BookCntrl) Get added in v0.8.1

func (c *BookCntrl) Get(ctx echo.Context) error

Get book

func (*BookCntrl) List added in v0.8.1

func (c *BookCntrl) List(ctx echo.Context) error

List of book

func (*BookCntrl) Route added in v0.8.1

func (c *BookCntrl) Route(e *echo.Echo)

Route to define API Route

func (*BookCntrl) Update added in v0.8.1

func (c *BookCntrl) Update(ctx echo.Context) (err error)

Update book

type GeneralResponse added in v0.8.1

type GeneralResponse struct {
	Message string `json:"message"`
}

GeneralResponse is general response

Jump to

Keyboard shortcuts

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