game_discount

package
v0.0.0-...-c52fe67 Latest Latest
Warning

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

Go to latest
Published: Oct 5, 2020 License: GPL-3.0 Imports: 6 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Handler

type Handler struct {
	DiscountService     service.DiscountService
	GameDiscountService service.GameDiscountService
}

func NewHandler

func NewHandler(params Params) Handler

func (Handler) Create

func (h Handler) Create(c echo.Context) error

swagger:route POST /games/{game_id}/discounts game_discounts reqCreateGameDiscount

Create game discount

This endpoint returns game discount structure

Responses:
  200: GameDiscount
  500: HTTPError

func (Handler) Delete

func (h Handler) Delete(c echo.Context) error

swagger:route DELETE /games/{game_id}/discounts/{discount_id} game_discounts reqDeleteGameDiscount

Delete game discount.

This endpoint removes discount from game and returns no content.

Responses:
  204:
  500: HTTPError

type Params

type Params struct {
	fx.In

	DiscountService     service.DiscountService
	GameDiscountService service.GameDiscountService
}

Jump to

Keyboard shortcuts

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