service

package
v0.0.0-...-2d053d8 Latest Latest
Warning

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

Go to latest
Published: Feb 25, 2025 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 OrderService

type OrderService struct {
	// contains filtered or unexported fields
}

func NewOrderService

func NewOrderService(db repository.OrderDB, sf *utils.Snowflake) *OrderService

func (*OrderService) GetOrderStatusMsg

func (svc *OrderService) GetOrderStatusMsg(code int8) string

func (*OrderService) IsOrderExist

func (svc *OrderService) IsOrderExist(ctx context.Context, orderID int64) (bool, error)

IsOrderExist 检查订单是否存在

func (*OrderService) OrderExist

func (svc *OrderService) OrderExist(ctx context.Context, orderID int64) error

OrderExist 检查订单是否存在

func (*OrderService) Verify

func (svc *OrderService) Verify(ops ...OrderVerifyOps) error

Verify 验证多个条件

func (*OrderService) VerifyOrderStatus

func (svc *OrderService) VerifyOrderStatus(status int32) func() error

VerifyOrderStatus 验证订单状态

func (*OrderService) ViewOrderList

func (svc *OrderService) ViewOrderList(ctx context.Context, userID int64, page, size int32) ([]*model.Order, []*model.OrderGoods, int32, error)

ViewOrderList 获取订单列表

type OrderVerifyOps

type OrderVerifyOps func() error

Jump to

Keyboard shortcuts

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