Skip to content

Commit

Permalink
add upitype
Browse files Browse the repository at this point in the history
  • Loading branch information
AkshayaFoiger committed May 22, 2024
1 parent dda26ab commit e317b34
Show file tree
Hide file tree
Showing 3 changed files with 5 additions and 3 deletions.
1 change: 1 addition & 0 deletions crates/api_models/src/payments.rs
Original file line number Diff line number Diff line change
Expand Up @@ -2950,6 +2950,7 @@ pub enum NextActionData {
#[schema(value_type = String)]
/// The url for Qr code given by the connector
qr_code_url: Option<Url>,
/// The url to fetch qr code data
qr_code_data_url: Option<Url>,
},
/// Contains the download url and the reference number for transaction
Expand Down
3 changes: 2 additions & 1 deletion crates/kgraph_utils/src/mca.rs
Original file line number Diff line number Diff line change
Expand Up @@ -77,7 +77,6 @@ fn get_dir_value_payment_method(

api_enums::PaymentMethodType::ClassicReward => Ok(dirval!(RewardType = ClassicReward)),
api_enums::PaymentMethodType::Evoucher => Ok(dirval!(RewardType = Evoucher)),
api_enums::PaymentMethodType::UpiCollect => Ok(dirval!(UpiType = UpiCollect)),
api_enums::PaymentMethodType::SamsungPay => Ok(dirval!(WalletType = SamsungPay)),
api_enums::PaymentMethodType::GoPay => Ok(dirval!(WalletType = GoPay)),
api_enums::PaymentMethodType::KakaoPay => Ok(dirval!(WalletType = KakaoPay)),
Expand Down Expand Up @@ -133,6 +132,8 @@ fn get_dir_value_payment_method(
api_enums::PaymentMethodType::Oxxo => Ok(dirval!(VoucherType = Oxxo)),
api_enums::PaymentMethodType::CardRedirect => Ok(dirval!(CardRedirectType = CardRedirect)),
api_enums::PaymentMethodType::Venmo => Ok(dirval!(WalletType = Venmo)),
api_enums::PaymentMethodType::UpiIntent => Ok(dirval!(UpiType = UpiIntent)),
api_enums::PaymentMethodType::UpiCollect => Ok(dirval!(UpiType = UpiCollect)),
}
}

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -74,7 +74,7 @@ pub enum StripeWallet {

#[derive(Default, Serialize, PartialEq, Eq, Deserialize, Clone, Debug)]
pub struct StripeUpi {
pub vpa_id: Option<masking::Secret<String, UpiVpaMaskingStrategy>>,
pub vpa_id: masking::Secret<String, UpiVpaMaskingStrategy>,
}

#[derive(Debug, Default, Serialize, PartialEq, Eq, Deserialize, Clone)]
Expand Down Expand Up @@ -143,7 +143,7 @@ impl From<StripeWallet> for payments::WalletData {
impl From<StripeUpi> for payments::UpiData {
fn from(upi_data: StripeUpi) -> Self {
Self::Upi(payments::Upi {
vpa_id: upi_data.vpa_id,
vpa_id: Some(upi_data.vpa_id),
})
}
}
Expand Down

0 comments on commit e317b34

Please sign in to comment.