feat(payment): 增加支付配置测试支付与全链路报文

This commit is contained in:
2026-11-20 14:51:17 +08:00
parent b539e3a42f
commit 8fec2fa5a2
19 changed files with 2353 additions and 5 deletions
@@ -100,6 +100,7 @@ type QueryPaymentResponse struct {
PayWay string
PayTime string
Raw map[string]string
RawRequest map[string]string
}
type CreateRefundRequest struct {
@@ -250,6 +251,7 @@ func (c *Client) QueryPayment(ctx context.Context, thirdOrderID, providerOrderID
PayWay: firstNonEmpty(raw["pay_mode"], raw["account_type"]),
PayTime: firstNonEmpty(raw["pay_time"], raw["trade_time"], raw["finish_time"]),
Raw: raw,
RawRequest: stringifyMap(reqData),
}, nil
}
@@ -80,6 +80,7 @@ type QueryPaymentResponse struct {
PayWay string
PayTime string
Raw map[string]string
RawRequest map[string]string
}
type CreateRefundRequest struct {
@@ -236,6 +237,7 @@ func (c *Client) QueryPayment(ctx context.Context, thirdOrderID, providerOrderID
PayWay: raw["pay_way"],
PayTime: raw["pay_time"],
Raw: raw,
RawRequest: params,
}, nil
}
@@ -91,6 +91,7 @@ type QueryPaymentResponse struct {
Amount string
PayTime string
Raw map[string]string
RawRequest map[string]string
}
type CreateRefundRequest struct {
@@ -237,6 +238,7 @@ func (c *Client) QueryPayment(ctx context.Context, req QueryPaymentRequest) (*Qu
Amount: raw["total_fee"],
PayTime: firstNonEmpty(raw["end_time"], raw["terminal_time"]),
Raw: raw,
RawRequest: copyMap(params),
}, nil
}
@@ -99,6 +99,7 @@ type QueryPaymentResponse struct {
PayWay string
PayTime string
Raw map[string]string
RawRequest map[string]string
}
type CreateRefundRequest struct {
@@ -266,6 +267,7 @@ func (c *Client) QueryPayment(ctx context.Context, thirdOrderID, providerOrderID
PayWay: raw["pay_way"],
PayTime: firstNonEmpty(raw["pay_time"], raw["channel_datetime"]),
Raw: raw,
RawRequest: copyStringMap(params),
}, nil
}