feat(core): add surcharge_details field to ResponsePaymentMethodTypes struct (#2435)

This commit is contained in:
Hrithikesh
2023-10-05 23:52:47 +05:30
committed by GitHub
parent 51d9f8d26c
commit 3f0d927cb8
10 changed files with 417 additions and 12 deletions

View File

@ -23,3 +23,6 @@ pub static FRM_CONFIGS_EG: &str = r#"
pub const PAYMENTS_LIST_MAX_LIMIT_V1: u32 = 100;
/// Maximum limit for payments list post api with filters
pub const PAYMENTS_LIST_MAX_LIMIT_V2: u32 = 20;
/// surcharge percentage maximum precision length
pub const SURCHARGE_PERCENTAGE_PRECISION_LENGTH: u8 = 2;

View File

@ -76,6 +76,14 @@ pub enum QrCodeError {
FailedToCreateQrCode,
}
/// Api Models construction error
#[derive(Debug, Clone, thiserror::Error, PartialEq, Eq)]
pub enum ApiModelsError {
/// Percentage Value provided was invalid
#[error("Invalid Percentage value")]
InvalidPercentageValue,
}
/// Allows [error_stack::Report] to change between error contexts
/// using the dependent [ErrorSwitch] trait to define relations & mappings between traits
pub trait ReportSwitchExt<T, U> {