Versions in this module Expand all Collapse all v1 v1.0.1 May 15, 2020 Changes in this version type Params + NotifyUrl string v1.0.0 May 6, 2020 Changes in this version + type AppPayConfig struct + AppID string + NonceStr string + Package string + PartnerID string + PrePayID string + Sign string + Timestamp string + type MchTransfersParams struct + AppID string + InputCharset string + MchID string + Memo string + NonceStr string + OpUserID string + OpUserPasswd string + OpenID string + OutTradeNo string + Sign string + SpbillCreateIp string + TotalFee int + type NotifyResult struct + Appid string + Attach string + BankType string + CashFee string + CouponFee string + DeviceInfo string + ErrCode string + ErrCodeDes string + FeeType string + MchID string + NonceStr string + Openid string + OutTradeNo string + ResultCode string + ReturnCode string + ReturnMsg string + Sign string + TimeEnd string + TotalFee string + TradeType string + TransactionId string + type NotifyReturn struct + ReturnCode string + ReturnMsg string + type Params struct + ActName string + Attach string + BannerID int + Body string + ContractCode string + CreateIP string + IconID int + MiniAppParam string + OpenID string + OutTradeNo string + PromotionTag string + SendName string + TotalFee int + TradeType string + Wishing string + type Pay struct + func NewPay(ctx *context.Context) *Pay + func (pcf *Pay) AppPayParams(prePayID string) AppPayConfig + func (pcf *Pay) JSPayParams(prePayID string) PayConfig + func (pcf *Pay) MchPay(p *Params) error + func (pcf *Pay) PrePayId(p *Params) (prePayID string, err error) + func (pcf *Pay) PrePayIdByApp(p *Params) (prePayID string, err error) + func (pcf *Pay) PrePayIdByJs(p *Params) (prePayID string, err error) + func (pcf *Pay) PrePayOrder(p *Params) (payOrder PreOrder, err error) + func (pcf *Pay) PrePayOrderByApp(p *Params) (payOrder PreOrder, err error) + func (pcf *Pay) PrePayOrderByJs(p *Params) (payOrder PreOrder, err error) + func (pcf *Pay) PrePayOrderByMiniApp(p *Params) (payOrder PreOrder, err error) + func (pcf *Pay) Refund(p *RefundParams) error + func (pcf *Pay) SendRed(p *Params) (string, error) + func (pcf *Pay) Sign(variable interface{}, key string) (sign string, err error) + func (pcf *Pay) SignByJson(variable interface{}, key string) (sign string, err error) + type PayConfig struct + AppID string + NonceStr string + Package string + PaySign string + SignType string + TimeStamp string + type PreOrder struct + AppID string + CodeURL string + ErrCode string + ErrCodeDes string + MchID string + NonceStr string + PrePayID string + ResultCode string + ReturnCode string + ReturnMsg string + Sign string + TradeType string + type RedParams struct + ActName string + BannerID int + Charset int + IconID int + MaxValue int + MchBillno string + MchID string + MchName string + MinValue int + NonceStr string + NotSendMsg int + NotifyUrl string + QqAppID string + ReOpenID string + Sign string + TotalAmount int + TotalNum int + Wishing string + type RedResult struct + Listid string + Retcode string + Retmsg string + type RefundParams struct + CreateIP string + OutRefundNo string + OutTradeNo *string + RefundFee int + TotalFee int + TransactionID *string + type RefundResult struct + AppID string + CashFee int + CashFeeType string + CashRefundFee int + ErrCode string + ErrCodeDes string + FeeType string + MchID string + NonceStr string + OutRefundNo string + OutTradeNo string + RefundFee int + RefundID string + ResultCode string + ReturnCode string + ReturnMsg string + SettlementRefundFee int + SettlementTotalFee int + Sign string + TotalFee int + TransactionID string + type SignStruct struct + Elements map[string]string + Keys []string + Tag string + ToLower bool + func (this SignStruct) Sign(variable interface{}, fn func() hash.Hash, apiKey string) (sign string, err error) + type WxRefundParams struct + AppID string + MchID string + NonceStr string + NotifyUrl *string + OutRefundNo string + OutTradeNo *string + RefundAccount *string + RefundDesc *string + RefundFee int + RefundFeeType *string + Sign string + SignType *string + TotalFee int + TransactionID *string