Help us shape the future of Go! Take the 2026 Go Developer Survey

userorder

package
v1.21.2 Latest Latest
Warning

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

Go to latest
Published: Oct 27, 2026 License: GPL-3.0 Imports: 10 Imported by: 0

Documentation

Overview

Package userorder implements the user-facing order query subdomain of the billing module. Only the module facade may reach it.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Orders added in v1.21.0

type Orders interface {
	FindOneDetailsByOrderNo(ctx context.Context, orderNo string) (*order.Details, error)
	QueryOrderListByPage(ctx context.Context, page, size int, status uint8, user, subscribe int64, search string) (int64, []*order.Details, error)
}

Orders reads the current user's orders.

type PlanReader

type PlanReader interface {
	FindOne(ctx context.Context, id int64) (*subscribeEntity.Subscribe, error)
}

PlanReader is the subdomain's read-only port onto the subscription domain's plan catalogue: the order rows only carry the plan ID, and the plan fields shown on an order detail are attached here instead of through a cross-domain SQL association (ADR-001 step 5).

type Service

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

func NewService

func NewService(orders Orders, plans PlanReader) *Service

func (*Service) QueryDetail

func (s *Service) QueryDetail(ctx context.Context, req *dto.QueryOrderDetailRequest) (*dto.OrderDetail, error)

QueryDetail returns one of the current user's orders; ownership is enforced here and the referrer commission never leaves the module.

func (*Service) QueryList

Jump to

Keyboard shortcuts

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