positiongrp

package
v0.0.0-...-c46be8d Latest Latest
Warning

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

Go to latest
Published: Nov 15, 2021 License: Apache-2.0 Imports: 9 Imported by: 0

Documentation

Overview

Package positiongrp maintains the group of handlers for position access.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Handlers

type Handlers struct {
	Position position.Core
	Auth     *auth.Auth
}

Handlers manages the set of position endpoints.

func (Handlers) Close

Close closes a position setting its balance to 0. Positions persist in database.

func (Handlers) Create

Create adds a new position to the system.

func (Handlers) Query

Query returns a list of positions with paging. If an administrator is issuing the request, then a list with all positions is returned, otherwise only the positions from the logged user is returned

func (Handlers) QueryByID

func (h Handlers) QueryByID(ctx context.Context, w http.ResponseWriter, r *http.Request) error

QueryByID returns a positions by its ID.

Jump to

Keyboard shortcuts

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