优化结构
This commit is contained in:
@@ -158,51 +158,51 @@ type PaymentConfirmation struct {
|
||||
}
|
||||
|
||||
type PaymentResult struct {
|
||||
Provider string `json:"provider"`
|
||||
Status string `json:"status"`
|
||||
TradeNo string `json:"tradeNo"`
|
||||
ProviderTradeNo string `json:"providerTradeNo"`
|
||||
Amount int64 `json:"amount"`
|
||||
PayerPaidAmount int64 `json:"payerPaidAmount,omitempty"`
|
||||
CashPaidAmount int64 `json:"cashPaidAmount,omitempty"`
|
||||
PointPaidAmount int64 `json:"pointPaidAmount,omitempty"`
|
||||
DiscountAmount int64 `json:"discountAmount,omitempty"`
|
||||
ProviderDiscountAmount int64 `json:"providerDiscountAmount,omitempty"`
|
||||
MerchantDiscountAmount int64 `json:"merchantDiscountAmount,omitempty"`
|
||||
SettlementAmount int64 `json:"settlementAmount,omitempty"`
|
||||
Currency string `json:"currency"`
|
||||
PayerCurrency string `json:"payerCurrency,omitempty"`
|
||||
AmountBreakdownKnown bool `json:"amountBreakdownKnown"`
|
||||
Duplicate bool `json:"duplicate"`
|
||||
Payload json.RawMessage `json:"payload"`
|
||||
OrderStatus string `json:"orderStatus,omitempty"`
|
||||
FulfillmentStatus string `json:"fulfillmentStatus,omitempty"`
|
||||
RefundStatus string `json:"refundStatus,omitempty"`
|
||||
EventID string `json:"-"`
|
||||
QueryID string `json:"-"`
|
||||
SuccessAck PaymentCallbackAck `json:"-"`
|
||||
FailureAck PaymentCallbackAck `json:"-"`
|
||||
Provider string
|
||||
Status string
|
||||
TradeNo string
|
||||
ProviderTradeNo string
|
||||
Amount int64
|
||||
PayerPaidAmount int64
|
||||
CashPaidAmount int64
|
||||
PointPaidAmount int64
|
||||
DiscountAmount int64
|
||||
ProviderDiscountAmount int64
|
||||
MerchantDiscountAmount int64
|
||||
SettlementAmount int64
|
||||
Currency string
|
||||
PayerCurrency string
|
||||
AmountBreakdownKnown bool
|
||||
Duplicate bool
|
||||
Payload json.RawMessage
|
||||
OrderStatus string
|
||||
FulfillmentStatus string
|
||||
RefundStatus string
|
||||
EventID string
|
||||
QueryID string
|
||||
SuccessAck PaymentCallbackAck
|
||||
FailureAck PaymentCallbackAck
|
||||
}
|
||||
|
||||
// PaymentTestStage is one step of a provider connectivity test. A skipped
|
||||
// query/refund is reported explicitly because a prepay flow cannot be marked
|
||||
// paid without a sandbox payer interaction.
|
||||
type PaymentTestStage struct {
|
||||
Name string `json:"name"`
|
||||
Status string `json:"status"`
|
||||
Message string `json:"message,omitempty"`
|
||||
TradeNo string `json:"tradeNo,omitempty"`
|
||||
Duration int64 `json:"durationMs,omitempty"`
|
||||
Name string
|
||||
Status string
|
||||
Message string
|
||||
TradeNo string
|
||||
Duration int64
|
||||
}
|
||||
|
||||
type PaymentTestResult struct {
|
||||
Provider string `json:"provider"`
|
||||
TradeNo string `json:"tradeNo"`
|
||||
Passed bool `json:"passed"`
|
||||
FullFlow bool `json:"fullFlow"`
|
||||
Mode string `json:"mode,omitempty"`
|
||||
Stages []PaymentTestStage `json:"stages"`
|
||||
Result *PaymentResult `json:"result,omitempty"`
|
||||
Provider string
|
||||
TradeNo string
|
||||
Passed bool
|
||||
FullFlow bool
|
||||
Mode string
|
||||
Stages []PaymentTestStage
|
||||
Result *PaymentResult
|
||||
}
|
||||
|
||||
type PaymentCallbackAck struct {
|
||||
|
||||
Reference in New Issue
Block a user