create_order_request

package
v1.4.63 Latest Latest
Warning

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

Go to latest
Published: Nov 14, 2026 License: MIT Imports: 10 Imported by: ? modules, 0 packages

The first number is the count of modules that contain a package that imports this one. The module count is a better indicator of popularity than the package count. A module with 100 importing packages is counted only once instead of 100 times, reflecting the fact that the choice to use the package was likely made only once, not 100 times.
A '?' means that the value hasn't been computed yet.

Documentation

Overview

Package create_order_request 创建订单请求包

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type CreateOrderParam

type CreateOrderParam struct {
	CouponID   int    `json:"coupon_id,omitempty" validate:"required,gt=0"`
	OutOrderSn string `json:"out_order_sn" validate:"required"`
	OutUserSn  string `json:"out_user_sn" validate:"required"`
	Num        int    `json:"num" validate:"required,gte=1"`
	OutMobile  string `json:"out_mobile" validate:"omitempty,len=11"`
	ExpireTime int    `json:"expire_time" validate:"omitempty,gte=1,lte=7200"`
}

CreateOrderParam 创建订单参数结构

func (*CreateOrderParam) Validate

func (c *CreateOrderParam) Validate() error

Validate 验证参数

type CreateOrderRequest

type CreateOrderRequest struct {
	core.BaseTkAPIRequest
	Param *CreateOrderParam
}

CreateOrderRequest 创建订单请求结构

func New

func New() *CreateOrderRequest

New 创建新的创建订单请求

func (*CreateOrderRequest) ExecuteWithContext

func (c *CreateOrderRequest) ExecuteWithContext(ctx context.Context, accessToken string) (*createorderresponse.CreateOrderResponse, error)

ExecuteWithContext 带上下文执行创建订单请求

func (*CreateOrderRequest) GetParamObject

func (c *CreateOrderRequest) GetParamObject() interface{}

GetParamObject 获取参数对象

func (*CreateOrderRequest) GetParams

func (c *CreateOrderRequest) GetParams() *CreateOrderParam

GetParams 获取参数

func (*CreateOrderRequest) GetURLPath added in v1.4.27

func (c *CreateOrderRequest) GetURLPath() string

GetURLPath 获取URL路径

Jump to

Keyboard shortcuts

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