customer

package
v0.0.0-...-840ed6c Latest Latest
Warning

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

Go to latest
Published: Sep 29, 2024 License: MIT Imports: 12 Imported by: 0

Documentation

Index

Constants

View Source
const (
	ContextEndpointKey contextKey = "customer-endpoint"
	ContextRequestKey  contextKey = "customer-request"
)

Variables

View Source
var Endpoints = endpoints{
	Save: internalHttp.NewEndpoint(
		internalHttp.WithMethod(internalHttp.POST),
		internalHttp.WithURI("service/resources/customers")),
}

Functions

This section is empty.

Types

type Service

type Service interface {
	Save(ctx context.Context, customer *model.Customer) error
	Update(ctx context.Context, customer *model.Customer) error
	Find(ctx context.Context, id uint32) (model.Customer, error)
	FindAll(ctx context.Context, filters map[string]interface{}) ([]model.Customer, error)
	Delete(ctx context.Context, id uint32) error
	Config() config.Config
	Request() *http.Request
	Response() *http.Response
}

func NewService

func NewService(config config.Config) Service

type ServiceMiddleware

type ServiceMiddleware func(Service) Service

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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