mirror of
https://github.com/juspay/hyperswitch.git
synced 2025-11-01 19:42:27 +08:00
feat(euclid): add a new variant in payment type i.e ppt_mandate (#5681)
Co-authored-by: hyperswitch-bot[bot] <148525504+hyperswitch-bot[bot]@users.noreply.github.com>
This commit is contained in:
@ -208,10 +208,21 @@ where
|
||||
}
|
||||
})
|
||||
}),
|
||||
payment_type: Some(payment_data.setup_mandate.clone().map_or_else(
|
||||
|| euclid_enums::PaymentType::NonMandate,
|
||||
|_| euclid_enums::PaymentType::SetupMandate,
|
||||
)),
|
||||
payment_type: Some(
|
||||
if payment_data.recurring_details.as_ref().is_some_and(|data| {
|
||||
matches!(
|
||||
data,
|
||||
api_models::mandates::RecurringDetails::ProcessorPaymentToken(_)
|
||||
)
|
||||
}) {
|
||||
euclid_enums::PaymentType::PptMandate
|
||||
} else {
|
||||
payment_data.setup_mandate.clone().map_or_else(
|
||||
|| euclid_enums::PaymentType::NonMandate,
|
||||
|_| euclid_enums::PaymentType::SetupMandate,
|
||||
)
|
||||
},
|
||||
),
|
||||
};
|
||||
let payment_method_input = dsl_inputs::PaymentMethodInput {
|
||||
payment_method: payment_data.payment_attempt.payment_method,
|
||||
|
||||
Reference in New Issue
Block a user