Ejemplo n.º 1
0
        public static bool In(this NLFeeTypes ft, params NLFeeTypes[] args)
        {
            foreach (NLFeeTypes a in args)
            {
                if (a == ft)
                {
                    return(true);
                }
            }

            return(false);
        } // In
Ejemplo n.º 2
0
 public void DecorateNL_Offers(NL_Model nlModel, NLFeeTypes feeType, bool isBrokerSetUpFee = false)
 {
     nlModel.Offer = new NL_Offers()
     {
         OfferFees = new List <NL_OfferFees>()
         {
             new NL_OfferFees()
             {
                 Percent       = (decimal?)0.02,
                 LoanFeeTypeID = (int)feeType
             }
         }
     };
     if (isBrokerSetUpFee)
     {
         nlModel.Offer.BrokerSetupFeePercent = (decimal?)0.5;
     }
 }
Ejemplo n.º 3
0
		public static VariableValue NLFeeTypeToConfVar(NLFeeTypes fType) {
			VariableValue result = null;

			switch (fType) {
			case NLFeeTypes.AdminFee:
				result = CurrentValues.Instance.AdministrationCharge;
				break;

			case NLFeeTypes.ServicingFee:
			case NLFeeTypes.ArrangementFee:
				result = CurrentValues.Instance.SpreadSetupFeeCharge;
				break;

			case NLFeeTypes.LatePaymentFee:
				result = CurrentValues.Instance.LatePaymentCharge;
				break;

			case NLFeeTypes.PartialPaymentFee:
				result = CurrentValues.Instance.PartialPaymentCharge;
				break;

			case NLFeeTypes.SetupFee:
				//result = CurrentValues.Instance.set
				break;

			case NLFeeTypes.RolloverFee:
				result = CurrentValues.Instance.RolloverCharge;
				break;

			case NLFeeTypes.OtherCharge:
				result = CurrentValues.Instance.OtherCharge;
				break;
			}

			return result;
		}
Ejemplo n.º 4
0
		// ### generated by Calculator

		public static void CalculateFee(int daysBetween, decimal interest, out int feeAmount, out NLFeeTypes feeType) {
			feeAmount = 0;
			feeType = NLFeeTypes.None;
			if (daysBetween >= CurrentValues.Instance.CollectionPeriod1 && daysBetween < CurrentValues.Instance.CollectionPeriod2) {
				feeAmount = CurrentValues.Instance.LatePaymentCharge;
				feeType = NLFeeTypes.LatePaymentFee;
			} else if (daysBetween >= CurrentValues.Instance.CollectionPeriod2 && daysBetween < CurrentValues.Instance.CollectionPeriod3 && interest > 0) {
				feeAmount = CurrentValues.Instance.AdministrationCharge;
				feeType = NLFeeTypes.AdminFee;
			} else if (daysBetween >= CurrentValues.Instance.CollectionPeriod2 && daysBetween < CurrentValues.Instance.CollectionPeriod3 && interest <= 0) {
				feeAmount = CurrentValues.Instance.PartialPaymentCharge;
				feeType = NLFeeTypes.PartialPaymentFee;
			} //if
		} //CalculateFee