repository

package
v0.3.1 Latest Latest
Warning

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

Go to latest
Published: Sep 22, 2024 License: Apache-2.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 OrderRepository

type OrderRepository interface {
	CreateOrder(ctx context.Context, order domain.Order) (domain.Order, error)
	UpdateUnpaidOrderPaymentInfo(ctx context.Context, uid, oid, pid int64, psn string) error
	FindUserVisibleOrderByUIDAndSN(ctx context.Context, uid int64, sn string) (domain.Order, error)
	TotalUserVisibleOrders(ctx context.Context, uid int64) (int64, error)
	FindUserVisibleOrdersByUID(ctx context.Context, uid int64, offset, limit int) ([]domain.Order, error)
	CancelOrder(ctx context.Context, uid, oid int64) error
	SucceedOrder(ctx context.Context, uid int64, orderSN string) error
	FailOrder(ctx context.Context, uid int64, orderSN string) error
	FindTimeoutOrders(ctx context.Context, offset, limit int, ctime int64) ([]domain.Order, error)
	TotalTimeoutOrders(ctx context.Context, ctime int64) (int64, error)
	CloseTimeoutOrders(ctx context.Context, orderIDs []int64, ctime int64) error
}

func NewRepository

func NewRepository(d dao.OrderDAO) OrderRepository

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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