ejiaofei

package
v1.0.195 Latest Latest
Warning

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

Go to latest
Published: Oct 8, 2023 License: MIT Imports: 7 Imported by: 0

Documentation

Index

Constants

View Source
const (
	LogTable = "ejiaofei"
)

Variables

This section is empty.

Functions

func ErrorInfo added in v1.0.134

func ErrorInfo[ET int | int8 | int16 | int32 | int64 | uint | uint8 | uint16 | uint32 | uint64 | string](error ET) string

ErrorInfo 错误描述

func OperatorInfo added in v1.0.134

func OperatorInfo(operator string) string

OperatorInfo 运营商描述

func StateInfo added in v1.0.134

func StateInfo[ST int | int8 | int16 | int32 | int64 | uint | uint8 | uint16 | uint32 | uint64 | string](state ST) string

StateInfo 状态描述

Types

type ChOngZhiJkOrdersResponse added in v1.0.44

type ChOngZhiJkOrdersResponse struct {
	XMLName   xml.Name `xml:"response"`
	UserID    string   `xml:"userid"`    // 会员账号
	PorderID  string   `xml:"Porderid"`  // 鼎信平台订单号
	OrderID   string   `xml:"orderid"`   // 用户订单号
	Account   string   `xml:"account"`   // 需要充值的手机号码
	Face      string   `xml:"face"`      // 充值面值
	Amount    string   `xml:"amount"`    // 购买数量
	StartTime string   `xml:"starttime"` // 开始时间
	State     string   `xml:"state"`     // 订单状态
	EndTime   string   `xml:"endtime"`   // 结束时间
	Error     string   `xml:"error"`     // 错误提示
}

type ChOngZhiJkOrdersResult

type ChOngZhiJkOrdersResult struct {
	Result ChOngZhiJkOrdersResponse // 结果
	Body   []byte                   // 内容
	Http   gorequest.Response       // 请求
}

type CheckCostResponse added in v1.0.44

type CheckCostResponse struct {
	XMLName xml.Name `xml:"response"`
	UserID  string   `xml:"userid"`  // 用户账号
	OrderID string   `xml:"orderid"` // 用户提交订单号
	Face    float64  `xml:"face"`    // 官方价格
	Price   float64  `xml:"price"`   // 用户成本价
	Error   int64    `xml:"error"`   // 错误提示
}

type CheckCostResult

type CheckCostResult struct {
	Result CheckCostResponse  // 结果
	Body   []byte             // 内容
	Http   gorequest.Response // 请求
}

type Client added in v1.0.47

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

Client 实例

func NewClient added in v1.0.47

func NewClient(config *ClientConfig) (*Client, error)

NewClient 创建实例化

func (*Client) ChOngZhiJkOrders added in v1.0.47

func (c *Client) ChOngZhiJkOrders(ctx context.Context, notMustParams ...gorequest.Params) (*ChOngZhiJkOrdersResult, error)

ChOngZhiJkOrders 话费充值接口 orderID 用户提交的订单号 用户提交的订单号,最长32位(用户保证其唯一性) face 充值面值 以元为单位,包含10、20、30、50、100、200、300、500 移动联通电信 account 手机号码 需要充值的手机号码

func (*Client) CheckCost added in v1.0.47

func (c *Client) CheckCost(ctx context.Context, notMustParams ...gorequest.Params) (*CheckCostResult, error)

CheckCost 会员订单成本价查询接口 orderID 用户提交的订单号 用户提交的订单号,最长32位(用户保证其唯一性)

func (*Client) ConfigSLogClientFun added in v1.0.162

func (c *Client) ConfigSLogClientFun(apiSLogFun golog.ApiSLogFun)

ConfigSLogClientFun 日志配置

func (*Client) DefaultHttp added in v1.0.177

func (c *Client) DefaultHttp()

DefaultHttp 默认请求

func (*Client) Get added in v1.0.109

func (c *Client) Get(ctx context.Context, _method string, notMustParams ...gorequest.Params) ([]byte, error)

func (*Client) GetKey added in v1.0.52

func (c *Client) GetKey() string

func (*Client) GetPwd added in v1.0.52

func (c *Client) GetPwd() string

func (*Client) GetUserId added in v1.0.52

func (c *Client) GetUserId() string

func (*Client) GprsChOngZhiAdvance added in v1.0.47

func (c *Client) GprsChOngZhiAdvance(ctx context.Context, notMustParams ...gorequest.Params) (*GprsChOngZhiAdvanceResult, error)

GprsChOngZhiAdvance 流量充值接口

func (*Client) MoneyJkUser added in v1.0.47

func (c *Client) MoneyJkUser(ctx context.Context) (*MoneyJkUserResult, error)

MoneyJkUser 用户余额查询

func (*Client) Post added in v1.0.109

func (c *Client) Post(ctx context.Context, _method string, notMustParams ...gorequest.Params) ([]byte, error)

func (*Client) QueryJkOrders added in v1.0.47

func (c *Client) QueryJkOrders(ctx context.Context, notMustParams ...gorequest.Params) (*QueryJkOrdersResult, error)

QueryJkOrders 通用查询接口 orderId 用户提交的订单号 用户提交的订单号,最长32位(用户保证其唯一性)

func (*Client) QueryTxProduct added in v1.0.47

func (c *Client) QueryTxProduct(ctx context.Context) (*QueryTxProductResult, error)

QueryTxProduct 可充值腾讯产品查询

func (*Client) SetHttp added in v1.0.177

func (c *Client) SetHttp(app *gorequest.App)

SetHttp 配置请求

func (*Client) TxChOngZhi added in v1.0.47

func (c *Client) TxChOngZhi(ctx context.Context, notMustParams ...gorequest.Params) (*TxChOngZhiResult, error)

TxChOngZhi 流量充值接口

type ClientConfig added in v1.0.52

type ClientConfig struct {
	UserId string
	Pwd    string
	Key    string
}

ClientConfig 实例配置

type GprsChOngZhiAdvanceParams

type GprsChOngZhiAdvanceParams struct {
	OrderID    string `json:"orderid"`    // 用户提交的订单号 用户提交的订单号,最长32位(用户保证其唯一性)
	Account    string `json:"account"`    // 充值手机号 需要充值的手机号
	Gprs       int64  `json:"gprs"`       // 充值流量值 单位:MB(具体流量值请咨询商务)
	Area       int64  `json:"area"`       // 充值流量范围 0 全国流量,1 省内流量
	EffectTime int64  `json:"effecttime"` // 生效日期 0 即时生效,1次日生效,2 次月生效
	Validity   int64  `json:"validity"`   // 流量有效期 传入月数,0为当月有效
	Times      string `json:"times"`      // 时间戳 格式:yyyyMMddhhmmss
}

type GprsChOngZhiAdvanceResponse added in v1.0.44

type GprsChOngZhiAdvanceResponse struct {
	XMLName    xml.Name `xml:"response"`
	UserID     string   `xml:"userid"`     // 会员账号
	OrderID    string   `xml:"orderid"`    // 会员提交订单号
	PorderID   string   `xml:"Porderid"`   // 平台订单号
	Account    string   `xml:"account"`    // 充值手机号
	State      int64    `xml:"state"`      // 订单状态
	StartTime  string   `xml:"starttime"`  // 开始时间
	EndTime    string   `xml:"endtime"`    // 结束时间
	Error      string   `xml:"error"`      // 错误提示
	UserPrice  float64  `xml:"userprice"`  // 会员购买价格
	Gprs       string   `xml:"gprs"`       // 充值流量值(单位MB)
	Area       string   `xml:"area"`       // 流量范围(0 全国流量,1省内流量)
	EffectTime string   `xml:"effecttime"` // 生效日期(0即时,1次日,2次月)
	Validity   string   `xml:"validity"`   // 流量有效期(显示月数,0为当月)
}

type GprsChOngZhiAdvanceResult

type GprsChOngZhiAdvanceResult struct {
	Result GprsChOngZhiAdvanceResponse // 结果
	Body   []byte                      // 内容
	Http   gorequest.Response          // 请求
}

type MoneyJkUserResponse added in v1.0.44

type MoneyJkUserResponse struct {
	XMLName   xml.Name `xml:"response"`
	LastMoney float64  `xml:"lastMoney"` // 用户余额
	Tag       int64    `xml:"tag"`       // 用户状态(0正常 1暂停)
	Error     int64    `xml:"error"`     // 错误提示
}

type MoneyJkUserResult

type MoneyJkUserResult struct {
	Result MoneyJkUserResponse // 结果
	Body   []byte              // 内容
	Http   gorequest.Response  // 请求
}

type QueryJkOrdersResponse added in v1.0.44

type QueryJkOrdersResponse struct {
	XMLName   xml.Name `xml:"response"`
	UserID    string   `xml:"userid"`    // 会员账号
	POrderID  string   `xml:"Porderid"`  // 鼎信平台订单号
	OrderID   string   `xml:"orderid"`   // 用户订单号
	Account   string   `xml:"account"`   // 需要充值的手机号码
	Face      string   `xml:"face"`      // 充值面值
	Amount    string   `xml:"amount"`    // 购买数量
	StartTime string   `xml:"starttime"` // 开始时间
	State     string   `xml:"state"`     // 订单状态
	EndTime   string   `xml:"endtime"`   // 结束时间
	Error     string   `xml:"error"`     // 错误提示
}

type QueryJkOrdersResult

type QueryJkOrdersResult struct {
	Result QueryJkOrdersResponse // 结果
	Body   []byte                // 内容
	Http   gorequest.Response    // 请求
}

type QueryTxProductResponse added in v1.0.44

type QueryTxProductResponse struct {
	XMLName xml.Name `xml:"response"`
	Error   string   `xml:"error"` // 错误提示
}

type QueryTxProductResult

type QueryTxProductResult struct {
	Result QueryTxProductResponse // 结果
	Body   []byte                 // 内容
	Http   gorequest.Response     // 请求
}

type TxChOngZhiParams

type TxChOngZhiParams struct {
	OrderID   string `json:"orderid"`   // 用户提交的订单号 用户提交的订单号,最长32位(用户保证其唯一性)
	Account   string `json:"account"`   // QQ号	需要充值的QQ号
	ProductID int64  `json:"productid"` // 产品id
	Amount    int64  `json:"amount"`    // 购买数量
	Ip        string `json:"ip"`        // 充值QQ号ip
	Times     string `json:"times"`     // 时间戳 格式:yyyyMMddhhmmss
}

type TxChOngZhiResponse added in v1.0.44

type TxChOngZhiResponse struct {
	XMLName   xml.Name `xml:"response"`
	UserID    string   `xml:"userid"`    // 用户编号
	PorderID  string   `xml:"Porderid"`  // 鼎信平台订单号
	OrderID   string   `xml:"orderid"`   // 用户订单号
	Account   string   `xml:"account"`   // 需要充值的QQ号
	ProductID int64    `xml:"productid"` // 充值产品id
	Amount    int64    `xml:"amount"`    // 购买数量
	State     int64    `xml:"state"`     // 订单状态
	StartTime string   `xml:"starttime"` // 开始时间
	EndTime   string   `xml:"endtime"`   // 结束时间
	Error     string   `xml:"error"`     // 错误提示
}

type TxChOngZhiResult

type TxChOngZhiResult struct {
	Result TxChOngZhiResponse // 结果
	Body   []byte             // 内容
	Http   gorequest.Response // 请求
}

Jump to

Keyboard shortcuts

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