feat(connector): [Redsys] Use merchant payment_id for ds_merchant_order with length check (#8485)

Co-authored-by: hyperswitch-bot[bot] <148525504+hyperswitch-bot[bot]@users.noreply.github.com>
This commit is contained in:
Saptak Dutta
2025-07-03 21:55:45 +05:30
committed by GitHub
parent 37a95e3733
commit 6678ee3517
49 changed files with 346 additions and 45 deletions

View File

@ -519,6 +519,27 @@ impl ConnectorSpecifications for ConnectorEnum {
}
}
#[cfg(feature = "v1")]
fn generate_connector_request_reference_id(
&self,
payment_intent: &hyperswitch_domain_models::payments::PaymentIntent,
payment_attempt: &hyperswitch_domain_models::payments::payment_attempt::PaymentAttempt,
is_config_enabled_to_send_payment_id_as_connector_request_id: bool,
) -> String {
match self {
Self::Old(connector) => connector.generate_connector_request_reference_id(
payment_intent,
payment_attempt,
is_config_enabled_to_send_payment_id_as_connector_request_id,
),
Self::New(connector) => connector.generate_connector_request_reference_id(
payment_intent,
payment_attempt,
is_config_enabled_to_send_payment_id_as_connector_request_id,
),
}
}
#[cfg(feature = "v2")]
/// Generate connector request reference ID
fn generate_connector_request_reference_id(