mirror of
https://github.com/juspay/hyperswitch.git
synced 2025-11-01 11:06:50 +08:00
refactor(v2_migrations): re-organize v2 migrations (#5760)
This commit is contained in:
@ -1911,7 +1911,7 @@ impl<'a> MerchantDefaultConfigUpdate<'a> {
|
||||
))]
|
||||
struct DefaultFallbackRoutingConfigUpdate<'a> {
|
||||
routable_connector: &'a Option<api_enums::RoutableConnectors>,
|
||||
merchant_connector_id: &'a common_utils::id_type::MerchantConnectorAccountId,
|
||||
merchant_connector_id: &'a id_type::MerchantConnectorAccountId,
|
||||
store: &'a dyn StorageInterface,
|
||||
business_profile: domain::BusinessProfile,
|
||||
key_store: hyperswitch_domain_models::merchant_key_store::MerchantKeyStore,
|
||||
@ -4077,7 +4077,7 @@ impl BusinessProfileWrapper {
|
||||
db: &dyn StorageInterface,
|
||||
key_manager_state: &KeyManagerState,
|
||||
merchant_key_store: &domain::MerchantKeyStore,
|
||||
algorithm_id: common_utils::id_type::RoutingId,
|
||||
algorithm_id: id_type::RoutingId,
|
||||
transaction_type: &storage::enums::TransactionType,
|
||||
) -> RouterResult<()> {
|
||||
let routing_cache_key = self.clone().get_routing_config_cache_key();
|
||||
|
||||
@ -626,7 +626,7 @@ pub(crate) async fn get_payment_method_create_request(
|
||||
.flatten(),
|
||||
};
|
||||
let payment_method_request = payment_methods::PaymentMethodCreate {
|
||||
payment_method: payment_method,
|
||||
payment_method,
|
||||
payment_method_type: payment_method_type
|
||||
.get_required_value("Payment_method_type")
|
||||
.change_context(errors::ApiErrorResponse::MissingRequiredField {
|
||||
|
||||
@ -3975,7 +3975,7 @@ pub async fn filter_payment_methods(
|
||||
_mca_id: String,
|
||||
_payment_methods: &[Secret<serde_json::Value>],
|
||||
_req: &mut api::PaymentMethodListRequest,
|
||||
_resp: &mut Vec<ResponsePaymentMethodIntermediate>,
|
||||
_resp: &mut [ResponsePaymentMethodIntermediate],
|
||||
_payment_intent: Option<&storage::PaymentIntent>,
|
||||
_payment_attempt: Option<&storage::PaymentAttempt>,
|
||||
_address: Option<&domain::Address>,
|
||||
|
||||
@ -445,7 +445,7 @@ pub async fn get_token_pm_type_mandate_details(
|
||||
|
||||
#[cfg(all(feature = "v2", feature = "merchant_connector_account_v2"))]
|
||||
let connector_name = db
|
||||
.find_merchant_connector_account_by_id(key_manager_state, &mca_id, &merchant_key_store)
|
||||
.find_merchant_connector_account_by_id(key_manager_state, mca_id, merchant_key_store)
|
||||
.await
|
||||
.to_not_found_response(errors::ApiErrorResponse::MerchantConnectorAccountNotFound {
|
||||
id: mca_id.clone().get_string_repr().to_string(),
|
||||
|
||||
@ -657,7 +657,7 @@ where
|
||||
pub async fn save_payment_method<FData>(
|
||||
_state: &SessionState,
|
||||
_connector_name: String,
|
||||
_merchant_connector_id: Option<common_utils::id_type::MerchantConnectorAccountId>,
|
||||
_merchant_connector_id: Option<id_type::MerchantConnectorAccountId>,
|
||||
_save_payment_method_data: SavePaymentMethodData<FData>,
|
||||
_customer_id: Option<id_type::CustomerId>,
|
||||
_merchant_account: &domain::MerchantAccount,
|
||||
|
||||
@ -300,7 +300,7 @@ pub async fn payouts_create_core(
|
||||
merchant_account: domain::MerchantAccount,
|
||||
key_store: domain::MerchantKeyStore,
|
||||
req: payouts::PayoutCreateRequest,
|
||||
locale: &String,
|
||||
locale: &str,
|
||||
) -> RouterResponse<payouts::PayoutCreateResponse> {
|
||||
// Validate create request
|
||||
let (payout_id, payout_method_data, profile_id, customer) =
|
||||
@ -2220,10 +2220,10 @@ pub async fn payout_create_db_entries(
|
||||
_merchant_account: &domain::MerchantAccount,
|
||||
_key_store: &domain::MerchantKeyStore,
|
||||
_req: &payouts::PayoutCreateRequest,
|
||||
_payout_id: &String,
|
||||
_profile_id: &String,
|
||||
_payout_id: &str,
|
||||
_profile_id: &str,
|
||||
_stored_payout_method_data: Option<&payouts::PayoutMethodData>,
|
||||
_locale: &String,
|
||||
_locale: &str,
|
||||
_customer: Option<&domain::Customer>,
|
||||
) -> RouterResult<PayoutData> {
|
||||
todo!()
|
||||
@ -2240,7 +2240,7 @@ pub async fn payout_create_db_entries(
|
||||
payout_id: &String,
|
||||
profile_id: &common_utils::id_type::ProfileId,
|
||||
stored_payout_method_data: Option<&payouts::PayoutMethodData>,
|
||||
locale: &String,
|
||||
locale: &str,
|
||||
customer: Option<&domain::Customer>,
|
||||
) -> RouterResult<PayoutData> {
|
||||
let db = &*state.store;
|
||||
@ -2652,8 +2652,8 @@ pub async fn create_payout_link(
|
||||
customer_id: &CustomerId,
|
||||
merchant_id: &common_utils::id_type::MerchantId,
|
||||
req: &payouts::PayoutCreateRequest,
|
||||
payout_id: &String,
|
||||
locale: &String,
|
||||
payout_id: &str,
|
||||
locale: &str,
|
||||
) -> RouterResult<PayoutLink> {
|
||||
let payout_link_config_req = req.payout_link_config.to_owned();
|
||||
|
||||
|
||||
Reference in New Issue
Block a user