first commit
This commit is contained in:
@@ -0,0 +1,36 @@
|
||||
using Landmark.OLA.Models.Loan.Enums;
|
||||
|
||||
namespace Landmark.OLA.Models.Loan
|
||||
{
|
||||
public class LoanLimits
|
||||
{
|
||||
private static Limit EqLimit => new() { min = 10000, max = 250000 };
|
||||
private static Limit EqHighLimit => new() { min = 10000, max = 500000 };
|
||||
private static Limit VLimit => new() { min = 250, max = 250000 };
|
||||
private static Limit MfgHome => new() { min = 250, max = 250000 };
|
||||
private static Limit SLimit => new() { min = 250, max = 25000 };
|
||||
private static Limit SpecLimit => new() { min = 250, max = 10000 };
|
||||
|
||||
public static Dictionary<LoanType, Limit> Limits => new()
|
||||
{
|
||||
{ LoanType.EQ_HELOC_Flex, EqHighLimit },
|
||||
{ LoanType.EQ_Mtg_Refi_Express, EqLimit },
|
||||
{ LoanType.EQ_Home_Equity_Fixed, EqHighLimit },
|
||||
{ LoanType.EQ_Mfg_Home_With_or_Without_Land, MfgHome },
|
||||
{ LoanType.V_Vehicle, VLimit },
|
||||
{ LoanType.V_VehiclePreapproval, VLimit },
|
||||
{ LoanType.M_Boat, VLimit },
|
||||
{ LoanType.P_Powersport, VLimit },
|
||||
{ LoanType.T_TrailerMotorhome, MfgHome }, //same limits as mfHome
|
||||
{ LoanType.S_Signature, SLimit },
|
||||
{ LoanType.S_Special, SpecLimit },
|
||||
};
|
||||
|
||||
public static bool IsValidAmountForType(LoanType loanType, decimal requestedAmount)
|
||||
{
|
||||
var limit = Limits[loanType];
|
||||
|
||||
return requestedAmount >= limit.min && requestedAmount <= limit.max;
|
||||
}
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user