fix:支付
This commit is contained in:
@@ -11,9 +11,9 @@ type Config struct {
|
||||
func NewPayDriver(PayMethod int64, config *Config) Pay {
|
||||
switch PayMethod {
|
||||
case int64(constants.PAYMETHOD_STRIPE):
|
||||
return &Stripe{Key: config.Stripe.Key}
|
||||
return &Stripe{Key: config.Stripe.Key, PayType: config.Stripe.PayType}
|
||||
default:
|
||||
return &Stripe{Key: config.Stripe.Key}
|
||||
return &Stripe{Key: config.Stripe.Key, PayType: config.Stripe.PayType}
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
@@ -81,9 +81,6 @@ func (stripePay *Stripe) GeneratePrepayment(req *GeneratePrepaymentReq) (res *Ge
|
||||
params := &stripe.PaymentIntentParams{
|
||||
Amount: stripe.Int64(req.Amount),
|
||||
Currency: stripe.String(string(req.Currency)),
|
||||
AutomaticPaymentMethods: &stripe.PaymentIntentAutomaticPaymentMethodsParams{
|
||||
Enabled: stripe.Bool(true),
|
||||
},
|
||||
PaymentMethodTypes: stripe.StringSlice([]string{
|
||||
"card",
|
||||
// "ideal",
|
||||
|
||||
Reference in New Issue
Block a user